WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: SOLVED: Standby/resume on Eee 900  (Read 14728 times)

Offline OldAdamUser2

  • Full Member
  • ***
  • Posts: 199
SOLVED: Standby/resume on Eee 900
« on: November 28, 2009, 10:58:15 AM »
SEE Feb 1 POST BELOW FOR IMPROVED SCRIPT:
I've discovered that this script works well for standby/resume on the Asus Eee 900. It may not provide the same amount of power savings as suspend, but it works and it's better than nothing.

Suggestions for improvement are welcome. I'd like, if possible to add an icon on the taskbar to initiate standby instead of having to open a root terminal and enter the command for the script. How would it do that?
__________________________________________________________________________________________
#!/bin/sh

# This standby script was adapted for Tiny Core 2.3 on an Asus 900 by OldAdamUser2.
# Run the script from a root shell.

# write all unwritten data (just in case)
sync

# suspend
echo standby > /sys/power/state

# Reconnect to wifi.
iwconfig wlan0 essid any

# Push power button to restore.
« Last Edit: February 01, 2010, 05:18:04 PM by OldAdamUser2 »

Offline fratermus

  • Newbie
  • *
  • Posts: 9
Re: Standby/resume on Eee 900
« Reply #1 on: November 28, 2009, 12:35:03 PM »
I've discovered that this script works well for standby/resume on the Asus Eee 900. It may not provide the same amount of power savings as suspend, but it works and it's better than nothing.

Just tried it on my 900 and seems to work fine.  No corruption, confusion, etc.  I wonder how much drain (over the normal unacceptable amounts of 900 powered-off drain) occurs. 

I'd like, if possible to add an icon on the taskbar to initiate standby instead of having to open a root terminal and enter the command for the script. How would it do that?

Adding stuff on the wbar appears to be non-trivial in my brief reading.  I think one has to basically make your own extension. 

But one can easily make an entry on the menu.  Check out the entries in ~/.wmx .  I made a file called MyLauncher that calls other scripts that do stuff on my Eee:

Code: [Select]
#!/bin/sh
exec aterm -e sudo {path/to/my/multipurpose-script}

It appears in the menu and works as intended. 

Backing up the ~/.wmx dir itself has unwanted consequences leading to duplicate menu entries so home/tc/.wmx is in .xfiletool.list.  I tried to adding home/tc/.wmx/MyLauncher  in /opt/.filetool.list to counteract the blanket exclusion of the dir .wmx but it wasn't backed up.

As a quick/dirty solution I put the MyLauncher file in /opt, added that file to .filetool.list, and use rc.bootlocal to copy it into my ~/.wmx dir at boot time.    That works but there has to be a more elegant solution that I am too newb to see.


# suspend
echo standby > /sys/power/state

# Reconnect to wifi.
iwconfig wlan0 essid any

This part confused me until I realized the script stops running immediately after the standby line and resumes there after button press and continues with the wifi line.

Offline jur

  • Hero Member
  • *****
  • Posts: 863
    • cycling photo essays
Re: Standby/resume on Eee 900
« Reply #2 on: November 28, 2009, 08:30:01 PM »
I tried it but it didn't recover gracefully - the mouse basically didn't work - well it did but extremely sluggish. The screen settled to a flashing cursor.

I am using the suspend extension with complete success. But it's not a tcz, so I had to manually guess it's address for downloading, also get all the deps, and then made a package from the whole lot.

Offline OldAdamUser2

  • Full Member
  • ***
  • Posts: 199
Re: Standby/resume on Eee 900
« Reply #3 on: November 28, 2009, 09:35:44 PM »
I seem to remember trying suspend2ram as a tce extension, but could not get it to work on my 900. What's the secret?

Offline jur

  • Hero Member
  • *****
  • Posts: 863
    • cycling photo essays
Re: Standby/resume on Eee 900
« Reply #4 on: November 28, 2009, 11:18:25 PM »
Once I packaged all the deps along with suspend.tce into a tczl, it worked as is, according to the instructions in the info file. Unfortunately it is over 800k big. 3 of the 4 library deps were not used with other stuff so these bloated the extension.  :(

Offline OldAdamUser2

  • Full Member
  • ***
  • Posts: 199
Re: Standby/resume on Eee 900
« Reply #5 on: November 29, 2009, 07:55:34 AM »
I have reinstalled suspend.tczl, but s2ram still doesn't work for me. What command do you invoke? Are you using an Eee 900?

When I try "s2ram -f -a 3", my machine goes into suspend, but it won't wake up with video and requires a hard reset.


Offline jur

  • Hero Member
  • *****
  • Posts: 863
    • cycling photo essays
Re: Standby/resume on Eee 900
« Reply #6 on: November 29, 2009, 03:39:01 PM »
I have a eeepc 1000he; and I use "sudo s2ram -f". The video card is intel 945GM. I don't see an -a option listed in the help text. Have you experimanted with the various --vbe options? I think they are meant for graphics.

s2disk looked promising but I didn't know how to make it boot from the hibernate file. It changed the swap partition. But rebooting tcl is fast so hibernate is of limited use here anyway...

Offline jur

  • Hero Member
  • *****
  • Posts: 863
    • cycling photo essays
Re: Standby/resume on Eee 900
« Reply #7 on: December 04, 2009, 12:05:11 AM »
Some more info: s2ram -f works for me but resumes video only if using Xorg. With Xvesa, I basically get the same as you. So it looks like you have to poke the video card or something.

Offline OldAdamUser2

  • Full Member
  • ***
  • Posts: 199
Re: Standby/resume on Eee 900
« Reply #8 on: December 04, 2009, 09:59:55 AM »
While my standby script works on the Eee 900, it doesn't completely switch off the screen. It leaves one in a black terminal screen with a cursor blinking in the upper left-hand corner. In a dark room one can see that the back-light is still on. But dmesg shows that it does put a lot of processes on hold and it seems to shut off the wifi radio.

An equally effective (or ineffective) standby-fix for the Eee 900  is to just open a terminal and enter "xset s 6". That completely blanks the screen in 6 seconds but leaves all processes running and the wifi radio on. To restore the default xset setting, one goes to the same terminal, pushes the up-arrow once, and adds two zeros--getting "xset s 600" for normal delay beffore screen blanking.

My experiments with suspend.tce and suspend.tcz have not been successful. Both in xvesa and xorg the computer won't wake up. I've tried a variety of initiation commands, but not all of them. I suspect that with xorg and the vbe tool something could work since the suspend/resume feature works well in both Xandros and Pupeee, but I'm still trying to stick with a light-weight system and suspend isn't a big deal to me.

One interesting thing: "xset q" indicates "Server does not have the DPMS Extension." I believe that's the case in xorg as well as xvesa, so maybe that is the root of the problem.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Standby/resume on Eee 900
« Reply #9 on: December 04, 2009, 02:07:17 PM »
Xorg does support DPMS.
The only barriers that can stop you are the ones you create yourself.

Offline OldAdamUser2

  • Full Member
  • ***
  • Posts: 199
Re: SOLVED: Standby/resume on Eee 900
« Reply #10 on: February 01, 2010, 04:25:08 PM »
First, make sure you download and mount vbetool.tcz. Then, here is the improved standby/resume script for the Eee 900:

Quote
#!/bin/sh

# This standby script was adapted for Tiny Core 2.3 on an Asus 900 by OldAdamUser2.
# Run the script from a root shell.

# write all unwritten data (just in case)
sync
chvt 1
# suspend
vbetool dpms off; echo standby > /sys/power/state
chvt 2
# Reconnect to wifi.
iwconfig wlan0 essid any

# Push power button to restore.
This script seems to do the job! Wifi switches off (and on again), screen goes to black and backlight goes off, cpu goes into sleep mode. Then when I push the power button, everything comes back up almost immediately, just as it was before going into standby. It's not a true hibernate, but it is significantly useful in saving battery power.
« Last Edit: February 01, 2010, 05:22:44 PM by OldAdamUser2 »

Offline giac_fab

  • Newbie
  • *
  • Posts: 24
Re: SOLVED: Standby/resume on Eee 900
« Reply #11 on: July 15, 2012, 10:13:43 AM »
Hi

I saw the last post is very old but I used it today....

I suggest an improvement :

with "sudo su -c COMMAND"  you can execute it as user without log in as root