How to enable Suspend in Fossapup64 on USB?

New to Puppy and have questions? Start here

Moderator: Forum moderators

Post Reply
Shloz
Posts: 19
Joined: Thu Jul 23, 2020 12:40 am
Been thanked: 1 time

How to enable Suspend in Fossapup64 on USB?

Post by Shloz »

I'm running Fossapup64 9.0.4, installed on a USB stick, Acer Aspire One D257 netbook with 2gb RAM

I would love the option to suspend. On the other thread I started 666phlib pointed me to the script in /etc/acpi/actions/suspend.sh. Looking at that and the other scripts there it seems that suspend is disabled if a USB is mounted... not sure if I'm reading that right?
I there a way I can have suspend?
User avatar
bigpup
Moderator
Posts: 6995
Joined: Tue Jul 14, 2020 11:19 pm
Location: Earth, South Eastern U.S.
Has thanked: 913 times
Been thanked: 1528 times

Re: Suspend

Post by bigpup »

suspend is disabled if a USB is mounted.
That is to make sure the save process, will always be able to do a write, to the save file/folder.
Especially, if writing to the save, is set to happen, at a specific time period. (every so many minutes)

Usually the save is on the USB and writing to it is more controlled.

For suspend setting changes to not affect saving to the save.
menu->System->Puppy Event Manager->Save Session
Set save interval to zero (0)
This stops auto save feature.

With this setting.
Writes to the save are two ways, now.
Click on the desktop save icon.
Do a complete shutdown or reboot.

The things you do not tell us, are usually the clue to fixing the problem.
When I was a kid, I wanted to be older.
This is not what I expected :o

User avatar
festus
Posts: 11
Joined: Mon Jul 13, 2020 12:04 pm
Has thanked: 1 time
Been thanked: 4 times

Re: How to enable Suspend in Fossapup64 on USB?

Post by festus »

@Shloz

I got this info off the Murga forum from sheldonisaac, if I recorded correctly.

I am running Fossapup64 9.0.4, installed on a USB stick, as you are, and here is how the suspend is done on my dell laptop:

Copy this to geany and save as "suspend"

Code: Select all

#!/bin/sh
echo -n mem > /sys/power/state
Open a terminal where "suspend" is at and run this command to make it executable:
chmod +x suspend

Make a folder "suspend" in /mnt/home
Take the script "suspend" and copy it to the folder /mnt/home/suspend

Open this folder in Rox and drag the "suspend" file onto your desktop

If you want an icon for this, go to /usr/share/pixmaps/puppy/screen_suspend.svg, and Right-click the "suspend" on the desktop and > File 'suspend' > Set Icon and drag the "screen_suspend.svg" file over to it.

Now when you want to "suspend" your box, just click on the "suspend" icon on the desktop.

To resume, on a laptop open the lid, on a desktop computer you may need to press the power button lightly just once.

I hope this helps you and others.

bliss, festus
Shloz
Posts: 19
Joined: Thu Jul 23, 2020 12:40 am
Been thanked: 1 time

Re: How to enable Suspend in Fossapup64 on USB?

Post by Shloz »

[mention]festus[/mention] Thanks, I tried your script and followed your setup. Problem is it wakes up immediately! It seems to suspend for a second and then wakes up. Any idea of what I can do to fix this? I never had problems with suspend in other distros or in Windows so I know it should work...
User avatar
MochiMoppel
Posts: 1237
Joined: Mon Jun 15, 2020 6:25 am
Location: Japan
Has thanked: 21 times
Been thanked: 439 times

Re: How to enable Suspend in Fossapup64 on USB?

Post by MochiMoppel »

Shloz wrote: Wed Aug 05, 2020 11:38 amProblem is it wakes up immediately! It seems to suspend for a second and then wakes up. Any idea of what I can do to fix this?
[mention]Shloz[/mention] I don't know about Fossapup but this is exactly what I experienced with Bionicpup. The way I solved it is to add 3sec of sleep before the command:

Code: Select all

#!/bin/sh
sleep 3
echo -n mem > /sys/power/state
After starting the script immediately close the lid. When the echo command starts while the lid is closed, my computer (Acer Aspire One 722) tries to restart but gives up after about a second and finally suspends.
Clarity
Posts: 3837
Joined: Fri Jul 24, 2020 10:59 pm
Has thanked: 1632 times
Been thanked: 525 times

Re: How to enable Suspend in Fossapup64 on USB?

Post by Clarity »

[mention]bigpup[/mention] THANKS for that insight. I, now, know how to better control save-session during my PUP's daily operations.

Excellent knowledge :thumbup:
ozsouth
Posts: 1569
Joined: Sun Jul 12, 2020 2:38 am
Location: S.E. Australia
Has thanked: 241 times
Been thanked: 704 times

Re: How to enable Suspend in Fossapup64 on USB?

Post by ozsouth »

Some systems are unable to suspend effectively. I was never able to suspend with bionicpup64 on a variety of systems, so no surprise that fossapup64 has similar issues for some systems. A lesser 'suspend' is usually available - freeze (used instead of mem in script above or in /etc/acpi/actions/suspend.sh). To exit that, would need to tap power button upon opening lid.
User avatar
mikewalsh
Moderator
Posts: 6163
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 795 times
Been thanked: 1982 times

Re: How to enable Suspend in Fossapup64 on USB?

Post by mikewalsh »

[mention]ozsouth[/mention] :-

Oz, just out of curiosity - and OS-specific issues aside! - would you happen to know if it's possible to make the suspend stuff function upon closing the lid of an older laptop? I'm thinking specifically of ye anciente Dell here, since I know there's a magnetically-controlled 'reed-switch' at the front top edge of the screen.

You know it's there, because a paper-clip will 'hang' there.....and if you listen closely, lowering the lid causes a soft 'click', fractions of an inch before the catch engages. I'm guessing this is what used to make suspend work back in its XP days....but how d'you tie the suspend/ACPI stuff in with the kernel functionality and whatever it is that actually communicates with that reed-switch?

Any ideas?


Mike. ;)
ozsouth
Posts: 1569
Joined: Sun Jul 12, 2020 2:38 am
Location: S.E. Australia
Has thanked: 241 times
Been thanked: 704 times

Re: How to enable Suspend in Fossapup64 on USB?

Post by ozsouth »

@mike - running cat /sys/power/state will tell what your system is capable of. Actually running it is somewhat hit n miss.
/etc/acpi/actions/suspend.sh contains the suggestion in earlier posts (echo -n mem > /sys/power/state). Can substitute freeze for mem. Freeze seems to be the only other option without complications (disk sounds risky), but not everything powers down & have to tap power button after reopening lid. Personally, I've tried various kernels & pups & find ScPup64 works with every system I have had in recent years, whereas bionicpup64 works with none of them. I don't know why.
Post Reply

Return to “Beginners Help”