Author Topic: Preventing Suspend  (Read 3081 times)

qx773

  • Full Member
  • ***
  • Posts: 219
    • View Profile
Preventing Suspend
« on: February 17, 2004, 09:38:09 pm »
I was using tkcVox to try and record a training session, but it only recorded the first 7 minutes 11 seconds before the Zaurus SL-C760 went into suspend mode and cut off the recording.  Does anyone know how to prevent an individual program from suspending?

Foxdie

  • Sr. Member
  • ****
  • Posts: 465
    • View Profile
    • http://trackmygps.co.uk
Preventing Suspend
« Reply #1 on: February 18, 2004, 06:26:40 am »
No but you can prevent the pda from going into suspend by editing qpe.conf which I have forgotten where it\'s located, sorry  I know you can disable suspend in there by giving an insanely high value or a value of 0
Jason "Foxdie" Gaunt
HTC Universal G4 with 2GB SD card running Debian Titchy Linux
[img]http://trackmygps.co.uk/signatures/foxdie.gif\" border=\"0\" class=\"linked-sig-image\" /]
Click image to view my GPS tracker
Follow me on Twitter: @jasongaunt

zmike

  • Jr. Member
  • **
  • Posts: 77
    • View Profile
    • http://
Preventing Suspend
« Reply #2 on: February 18, 2004, 08:12:07 am »
It seems that every time you play with the brightness, it gets overwritten though!
The file is in /home/zaurus/Settings.
SLC860, Zubuntu, Symbol Spectrum24 Wireless CF, 4GB SD Card

tumnus

  • Hero Member
  • *****
  • Posts: 1176
    • View Profile
    • http://www.cpinkney.org.uk
Preventing Suspend
« Reply #3 on: February 18, 2004, 09:23:13 am »
To temporarily disable suspending, you can run this command from the terminal as the \'zaurus\' user:

qcop QPE/System \'setScreenSaverMode(int)\' 2

To re-enable suspending you run this command:

qcop QPE/System \'setScreenSaverMode(int)\' 100

That\'s how apps like Opie Reader disable suspending when you are reading an e-book with autoscroll on. tkcVox should do this too and I put a request in theKompany\'s Mantis system for this, but tkcVox seems like a half finished product to me. I can\'t record more than a length of time that produces a filesize larger than about 1MB anyway. It just suddenly stops. I guess it uses /tmp and runs out of memory.
# Search the Zaurus Howtos ## Search the Zaurus FAQs ## Find Z software at ELSI #
--------------------
UK SL5500 with Sharp ROM 3.13, SL5600 with Sharp ROM 1.32 - SuSE 9.0 Pro, Windows XP Home
Qualendar for Calendar and Todo
Socket Bluetooth CF Card (Rev F), Kingmax 512MB MMC Card, Palm Tungsten T Stylus,
Pretec CF->Smartmedia Adapter, Semsons Universal Battery Extender

lardman

  • Hero Member
  • *****
  • Posts: 4512
    • View Profile
    • http://people.bath.ac.uk/enpsgp/Zaurus/
Preventing Suspend
« Reply #4 on: February 18, 2004, 10:01:51 am »
It should be easy enough to do it yourself - stick a script around the binary to do the call before starting and the other after stopping the program, then edit the .desktop file to point to the script rather than the binary. Nice and easy, something like:

---------------------------------------------------------
#! /bin/sh
qcop QPE/System \'setScreenSaverMode(int)\' 2
./opie-reader
qcop QPE/System \'setScreenSaverMode(int)\' 100
---------------------------------------------------------


Si
C750 OZ3.5.4 (GPE, 2.6.x kernel)
SL5500 OZ3.5.4 (Opie)
Nokia 770
Serial GPS, WCF-12, Socket Ethernet & BT, Ratoc USB
WinXP, Mandriva

tumnus

  • Hero Member
  • *****
  • Posts: 1176
    • View Profile
    • http://www.cpinkney.org.uk
Preventing Suspend
« Reply #5 on: February 18, 2004, 10:45:42 am »
Yes. Only problem with scripts like that though is you lose the taskbar icon and you cannot get back to the app instance by relaunching as I think it launches another instance (or tries to).
# Search the Zaurus Howtos ## Search the Zaurus FAQs ## Find Z software at ELSI #
--------------------
UK SL5500 with Sharp ROM 3.13, SL5600 with Sharp ROM 1.32 - SuSE 9.0 Pro, Windows XP Home
Qualendar for Calendar and Todo
Socket Bluetooth CF Card (Rev F), Kingmax 512MB MMC Card, Palm Tungsten T Stylus,
Pretec CF->Smartmedia Adapter, Semsons Universal Battery Extender

Anonymous

  • Guest
Preventing Suspend
« Reply #6 on: February 18, 2004, 11:56:39 am »
Hmmm...Tumnus, in my experience that is not completely true.  I use a script like that for Wellenreiter and it seems to work fine.  I get the teskbar icon and no attempt for a relaunch.  I think it may depend on what application you are running.

qx773

  • Full Member
  • ***
  • Posts: 219
    • View Profile
Preventing Suspend
« Reply #7 on: February 18, 2004, 11:14:13 pm »
Thank you for the information.  I had to reboot after modifying the *.desktop file in order for the change to the Exec line to take effect.  Now, I am able to record without the computer going into suspend.

qx773

  • Full Member
  • ***
  • Posts: 219
    • View Profile
Preventing Suspend
« Reply #8 on: February 19, 2004, 01:35:17 am »
I was able to create a 2MB+ recording file with tkcVox after disabling suspend.  I did notice, however, that if the input gain is set too high, then tkcVox will terminate during playback with a division error.  You will see the error message when you run tkcVox from the terminal command line, but not from the graphical environment.