Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Tue 22 Jul 2014, 23:50
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » System
acpi-tool-0.5.1 racy-5.3
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [10 Posts]  
Author Message
Karl Godt


Joined: 20 Jun 2010
Posts: 3953
Location: Kiel,Germany

PostPosted: Sat 14 Apr 2012, 08:48    Post subject:  acpi-tool-0.5.1 racy-5.3  

acpitool from actual debian sid compiled with its patches

plus patched by me to suppress "deprecated const char" warnings .

The kernel 3.x.y patch by debian looks like this ... Laughing
Code:
--- acpitool-0.5.1/src/acpitool.cpp      2009-08-13 14:37:48.000000000 -0500
+++ acpitool-0.5.1/src/acpitool.cpp       2011-07-28 08:40:37.000000000 -0500
@@ -205,8 +205,7 @@
    Kernel_24 = 1;           
    Kernel_26 = 0;
     }
-       
-    if(strncmp(str,"2.6",3)==0)
+    else
     {
    Kernel_24 = 0;           
    Kernel_26 = 1;
acpitool-0.5.1-i686.pet
Description  installs to /usr/local/* ; binary acpitool and manual page
pet

 Download 
Filename  acpitool-0.5.1-i686.pet 
Filesize  44.68 KB 
Downloaded  1243 Time(s) 
acpi-tool-0.5.1.const-char.diff.tar.bz2
Description  diff against unpatched source ; has small difference in acpitool.cpp
- char *filename, str[50];
+ const char *filename, string str; //str[50];
Where "string str" is changed by a debian patch .
Put that in if applied after the debian patch
bz2

 Download 
Filename  acpi-tool-0.5.1.const-char.diff.tar.bz2 
Filesize  2.03 KB 
Downloaded  714 Time(s) 
Back to top
View user's profile Send private message Visit poster's website 
vtpup


Joined: 15 Oct 2008
Posts: 1077
Location: Republic of Vermont

PostPosted: Sun 03 Jun 2012, 00:07    Post subject:  

Thanks for this. Unfortunately in Racy 53 I get:

Code:
 # acpitool
acpitool: /usr/lib/libstdc++.so.6: version `GLIBCXX_3.4.11' not found (required by acpitool)

_________________
New Acer Aspire 5349-2635 dual proc, 4gb ram, re-partitioned with frugal Racy 5.3, dual boot, running rings around Win 7.
Back to top
View user's profile Send private message 
vtpup


Joined: 15 Oct 2008
Posts: 1077
Location: Republic of Vermont

PostPosted: Sun 03 Jun 2012, 14:10    Post subject:  

Uninstalled, shut down, re-installed. And now it works. Don't know how, don't know why. But.....nevermind.....
_________________
New Acer Aspire 5349-2635 dual proc, 4gb ram, re-partitioned with frugal Racy 5.3, dual boot, running rings around Win 7.
Back to top
View user's profile Send private message 
Karl Godt


Joined: 20 Jun 2010
Posts: 3953
Location: Kiel,Germany

PostPosted: Sat 21 Jul 2012, 21:31    Post subject:  

Sorry for answering late: Such problems are " common " on Puppy but most messages " No version information " seems to not harm anything . I recently upgraded libz/zlib on a Puppy 4 that does not want to show a version information with the outcome that mtpaint does not want to save .png with compression levels other than 0 .
Back to top
View user's profile Send private message Visit poster's website 
Pelo


Joined: 10 Sep 2011
Posts: 2878
Location: Mer méditerrannée (1 kms°)

PostPosted: Tue 11 Sep 2012, 04:24    Post subject: acpi tool : what is it used for ?
Subject description: A quoi sert-il ? Para qué sirbe ?
 

acpi tool : what is it used for ?
A quoi sert-il ? Para qué sirbe ?

Wikipedia : L’Advanced Configuration and Power Interface (ACPI) (« interface avancée de configuration et de gestion de l’énergie » en anglais) est une norme co-développée par Hewlett Packard, Intel, Microsoft, Phoenix Technologies et Toshiba, très largement répandue dans les ordinateurs personnels.

Le but de cette norme est de réduire la consommation d’énergie d’un ordinateur en mettant hors tension certains éléments (tels que les lecteurs CD-ROM, les disques durs, l’écran…).

Merci messieurs les techniciens / please explain the usage : to reduce the consumption.
Back to top
View user's profile Send private message Yahoo Messenger 
Krishnamurti Naskar


Joined: 20 Apr 2012
Posts: 85
Location: Calcutta

PostPosted: Mon 23 Sep 2013, 01:11    Post subject:  Re: acpi-tool-0.5.1 racy-5.3  

Karl Godt wrote:
acpitool from actual debian sid compiled with its patches

plus patched by me to suppress "deprecated const char" warnings .

The kernel 3.x.y patch by debian looks like this ... Laughing
Code:
--- acpitool-0.5.1/src/acpitool.cpp      2009-08-13 14:37:48.000000000 -0500
+++ acpitool-0.5.1/src/acpitool.cpp       2011-07-28 08:40:37.000000000 -0500
@@ -205,8 +205,7 @@
    Kernel_24 = 1;           
    Kernel_26 = 0;
     }
-       
-    if(strncmp(str,"2.6",3)==0)
+    else
     {
    Kernel_24 = 0;           
    Kernel_26 = 1;


Thanx Karl,luv you!.
It worked like charm(The 1st pet only alone did the job.)
But Rolling Eyes can you suggest how do i create a "suspend to ram'' button in Shutdown manager,that will do the work for me in a click and no command-line?

_________________
--------------------
| Crying or Very sad || Embarassed |
--------------------
Kill Bill..(Gates,of course and his Windows)

Code:
So I dual-booted Puppy+PCBSD.

Back to top
View user's profile Send private message 
Karl Godt


Joined: 20 Jun 2010
Posts: 3953
Location: Kiel,Germany

PostPosted: Mon 23 Sep 2013, 09:36    Post subject:  

Jup , thats
/usr/sbin/plogout
script :
Add
Code:
tenthButton = fltk:Fl_Button(20, 305, 180, 40, "acpitool -s");
tenthButton:color(219)

and change
Code:
quitButton1  = fltk:Fl_Button(20, 350, 180, 40, "Cancel");
quitButton1:color(1)

so the second value matches the fourth value of 40+5
Then add
Code:
tenthButton:callback(
    function(slider1)
                   a=io.popen('"/usr/local/bin/psuspend2ram"');
                   os.exit();
     end)

further down .

[EDIT]
a=io.popen('"/usr/local/bin/accpitool -s"'); did not work since it treated it as a filename with space .
So a wrapper is needed, let's call it /usr/local/bin/psuspend2ram :
Code:
#!/bin/sh

/usr/local/bin/acpitool -s

Just tested that all on my Dell desktop PC and it worked nicely Smile
( Had to use unpatched acpitool compilation because running kernel 2.6.30.9 )
[TIDE]

NOTE : Macpup 550 has additionally plogoutE and plogoutJWM besides the plogout - likely they need to be altered the above way too .
plogout_with_acpitool.jpg
 Description   
 Filesize   23.16 KB
 Viewed   978 Time(s)

plogout_with_acpitool.jpg

Back to top
View user's profile Send private message Visit poster's website 
Krishnamurti Naskar


Joined: 20 Apr 2012
Posts: 85
Location: Calcutta

PostPosted: Tue 01 Oct 2013, 23:16    Post subject:  

Sorry, karl!
I did everything u suggested,but in vain!
i did tweak your code a bit to make suitable to my box,
hav a look_
Code:

tenthButton = fltk:Fl_Button(20, 265,180,40, "Supend/Sleep");
tenthButton:color(210)

then_

Code:
tenthButton:callback(
    function(slider1)
                   a=io.popen('"/usr/local/bin/psuspend2ram"');
           os.exit();
  end)   


--created a wrapper ,suspend2ram.
whoosh!all in vain.......

can u please tell me another way?
shot-2013-10-02_13-23-42.jpg
 Description   it's my skreeny!
 Filesize   11.35 KB
 Viewed   927 Time(s)

shot-2013-10-02_13-23-42.jpg

Back to top
View user's profile Send private message 
Karl Godt


Joined: 20 Jun 2010
Posts: 3953
Location: Kiel,Germany

PostPosted: Sat 05 Oct 2013, 06:57    Post subject:  

Krishnamurti , did you made the wrapper executable ?
Code:
chmod +x /usr/local/bin/psuspend2ram


Otherwise to debug , please run the corresponding plogout in terminal to catch error messages .
Back to top
View user's profile Send private message Visit poster's website 
Krishnamurti Naskar


Joined: 20 Apr 2012
Posts: 85
Location: Calcutta

PostPosted: Thu 10 Oct 2013, 20:42    Post subject:  

Karl Godt wrote:
Krishnamurti , did you made the wrapper executable ?
Code:
chmod +x /usr/local/bin/psuspend2ram


Otherwise to debug , please run the corresponding plogout in terminal to catch error messages .


Embarassed yeah karl,did that all to get nuthin'! Crying or Very sad
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [10 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » System
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0748s ][ Queries: 12 (0.0052s) ][ GZIP on ]