All Forums
 Microsoft Windows CE
 General CE
 Device sleeps even though I've disabled it
 Forum Locked
 Send Topic to a Friend
 Printer Friendly
Author Topic  

KnowledgeBase

296 Posts

Posted - 26 Feb 2002 :  16:33:24  Show Profile  Email Poster
Q: I have disabled sleep mode (Activity Timeout = 0) in the registry, and my application decides when to put the board to sleep. However, after I wake up the first time, the board always goes back to sleep after one minute. What am I doing wrong?

The "wakeup timeout" is an undocumented "feature" of Windows CE. The default setting is to go to sleep sixty seconds of inactivity after waking up. You can set the value you want in seconds, or set it to zero for no timeout (infinite timeout). To turn it off, change ADSLOAD.REG as follows:

[HKEY_LOCAL_MACHINE\SYSTEM=CurrentControlSet\Control\Power]
"WakeupPowerOff"=dword:0

ADS builds 2.01 and later of CE 2.12 compensate for this problem by launching a thread when the activity timeout is set to 0 that regularly resets the activity timer (at the time of writing, this was true through the current ADS CE build, 2.04).

Robert Bowen

9 Posts

Posted - 06 Dec 2004 :  17:23:33  Show Profile  Email Poster
Problem: Gmaster goes into Sleep mode and it is disabled.
End Result: I do not want my device to go into Sleep Mode.

I recently upgraded to WinCE 4.2, briefly, on my GMaster. I have now went back to my original WinCE 3.0, with original *.HWT and *.REG files. Now my GMaster enters Sleep Moded after "xx" minutes of inactivity. Originally, my GMaster never went into Sleep mode.

Here is a copy of my *.REG file. Perhaps I am overlooking something.

Thanks in advance,

Robert
;---------------------------------------------------------------------
;
; ADS WinCE Registry File
;
; 5Jul01 700110-9701A ak/ds
; - set up flash disk as 5MB to fit with 10MB CE image
; 14aug01 700110-9701A-1 ak
; - add flash disk settings for 8, 10 and 12MB
; CE images [10MB is default]
; - remove "ADSLoadREG" key (not used)
; 12nov01 700110-9701A-2 ak
; (synchronize with 700110-8700D-1)
; - add power-off-by-J1 keys
; - add more Windows Sound keys
; - change order of recent file list for Run command
; (now more oriented to developers)
; - delete pre-9701A revision notes
; 12nov01 700110-9701A-3 ak
; - add app launch keys
; - lengthen section dividers to 70 chars
; 19nov01 700110-9701A-4 ak
; - HWT file correction
; 5dec01 700110-9701A-5 ak
; - add key for trapping power failure events
; 22feb02 700110-9701A-6 ak
; - Add FATUserInterface key
; - Add audio volume key
; 25mar02 700110-9701A-7 ak
; - add configuration notes (below)
;---------------------------------------------------------------------
; Configuration as released by ADS:
; 32MB RAM
; 16MB flash
; 10MB CE image
; 5MB FlashFX disk
; System clock 206MHz
; Sharp LQ64D343 6.4" VGA display @ 8bpp
;
; Changes made by developer:
;
;
;---------------------------------------------------------------------


;---------------------------------------------------------------------
; Display dimensions
; These are part of your display driver. Do not modify.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\Display]
;Sharp LQ64D343 VGA LCD
"BitsPerPixel"=dword:08 ; [08=8BPP] 10=16bpp (must match .HWT)
"HorizSizeMillimeters"=dword:76
"VertSizeMillimeters"=dword:59
"PixelsPerLine"=dword:280
"PixelsPerColumn"=dword:1E0
"HorizPixelsPerInch"=dword:8A
"VertPixelsPerInch"=dword:8A
"PaletteReverse"=dword:0 ;0 = Normal Mono, 1 = Reverse Mono(Inverted)
"Rotate"=dword:00 ; software rotation of panel--allows portrait mode
; [00=0 degrees] 5A=90 deg, B4=180, 10E=270

;---------------------------------------------------------------------
; Touch panel
; These are part of your touch panel driver. Do not modify.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\TOUCH]
;DTFP 95659 F
"SamplePeriodHighHns"=dword:c350 ; 5ms
"AdcReadHoldoffHns"=dword:6DC ; 175 us
"PenDownHoldoffHns"=dword:1388 ; 500 us
"EnableDebugMsg"=dword:0 ; 1=echo raw touch data to debug port
"NoTouchScreen"=dword:0 ; [0=touch panel installed]
; 1=no touch panel installed (skips calibration)

;---------------------------------------------------------------------
; Keyboard
; If no keyboard is installed, set the status key to 0 to suppress touch
; panel calibration message that requires you press a key to complete
; calibration.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\HARDWARE\DEVICEMAP\KEYBD]
"Status"=dword:0 ; 0=no keyboard [1=keyboard connected]

;---------------------------------------------------------------------
; ADS User Touch Panel driver
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\adstouch]
"SetActiveRegion"="1024,1024 0,0"


;---------------------------------------------------------------------
; Show/Hide Desktop
;
; CE desktop is useful for development, but not usually
; used in final application. If desktop is suppressed,
; you must already have your applicaton loaded in flash as
; ADSLOAD.EXE or in \FlashFX Disk\Startup\ or
; \Storage Card\Startup to be able to use system.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Platform\GMaster]
"LaunchCEShell"=dword:1 ; [1=show desktop], 0=suppress desktop

;---------------------------------------------------------------------
; Launch Apps in Startup Folder
;
; You can launch applications from the Startup\ folder of either
; the "Storage Card" (CF or PCMCIA) or the "FlashFX Disk" (onboard
; flash disk). This allows you to launch your own applications
; on an ADS single-board computer.
;
; The LaunchEXE and LaunchVB keys enable execution of .EXE and .VB
; applications, respectively. You can reduce boot time by setting
; the keys to 0, if not needed.
;
; Applications loaded as ADSLOAD.EXE will always launch, irrespective
; of the settings here.
;
; Any EXE or VB app on the Storage Card causes the launcher
; to ignore files on the FlashFX Disk. This feature allows
; technicians to prevent your application from loading and to
; run their own test or update application.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Platform\LaunchApps]
"LaunchEXE"=dword:1
"LaunchVB"=dword:1

;---------------------------------------------------------------------
; Taskbar
;
; The following keys change the behavior of the taskbar.
; Useful for full-screen demonstrations when you still
; want to have easy access to the desktop.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Software\Microsoft\Shell\OnTop]
"Default"=dword:1 ; [1=keep taskbar on top]
[HKEY_LOCAL_MACHINE\Software\Microsoft\Shell\AutoHide]
"Default"=dword:0 ; 1=minimize taskbar to a line when not in use

;---------------------------------------------------------------------
; Power Management: Activity Timeouts
;
; Duration of inactivity before system suspends (sleeps).
; Activity timer is reset by touch panel, keyboard, mouse and
; other user input. Note that system will not suspend when
; Ethernet driver is active (see Ethernet keys for disable key).
;
; All values in seconds, entered in hex (e.g. dword:3C is 60 seconds)
; 0=disabled
;
; BattPowerOff timeout when on battery power
; ExtPowerOff timeout when on main power
; WakeupPowerOff time after wakeup to go back to sleep (usu. 0, disabled)
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power]
"BattPowerOff"=dword:0
"ExtPowerOff"=dword:0
"WakeupPowerOff"=dword:0

;---------------------------------------------------------------------
; Power Management: Sleep on J1
;
; The following keys enable the "sleep" driver built into GMaster
; builds 3.13 and later. This driver provides the support needed
; for a suspend/wake button using a momentary switch on J1.
;
; PowerOffByGPIO1 enables monitoring of J1
; PowerOffFromApps 0 driver puts system to sleep when contact
; closure is detected
; 1 application must trap "PWROFF" event issued
; when the J1 contacts are closed and
; put system to sleep; this allows app to
; close down critical processes before suspending
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Power]
"PowerOffByGPIO1"=dword:0 ; 1 enable built-in driver
"PowerOffFromApps"=dword:0 ; 1 application, 0 built-in driver

;---------------------------------------------------------------------
; Power Management: Trap power failures
;
; This registry entry allows your application to get notification
; when a power failure has occurred. Normally, the system goes
; immediately to sleep when it detects a power failure. This
; corresponds to setting this key to "0".
;
; If you want your application to have a particular behavior during
; a power failure, you can set this key to "1" and trap the
; VDDPWROFF event yourself. When you've completed application
; cleanup, issue the VK_OFF keyboard event to go to sleep.
;
; Warning! Your power supply must be able to hold up the 5V power
; long enough to handle your functions and put the system to sleep.
; The Graphics Master needs a minimum of 200ms to go to sleep.
; The supercapacitor circuit on the Rev C Graphics Master works for
; immediate shutdowns, but test carefully if you think your appplication
; will take a long time before going to sleep.
;
; Availability: Graphics Master CE builds 3.18 and later
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Power]
"VddPwrOffFromApps"=dword:1 ; 0 sleep on power fail
; 1 issue event "VDDPWROFF"

;---------------------------------------------------------------------
; Windows Explorer settings
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Explorer]
"ViewAll"=dword:1 ; 1=show hidden files
"ShowExt"=dword:1 ; 1=show all file extensions
"UseRecycleBin"=dword:0 ; 1=send files to Recycle Bin

; Recent file list for Run dialog
[HKEY_LOCAL_MACHINE\Explorer\RunHistory]
@=""
"0"="\Windows\repllog.exe"
"1"="\Windows\repllog.exe /remote"
"2"="\Windows\regedit.exe"
"3"="\Windows\restart.exe"
"4"="\Windows\polygons.exe"
"5"="\Windows\reversi.exe"

;---------------------------------------------------------------------
; Windows Sound
;---------------------------------------------------------------------
[HKEY_CURRENT_USER\ControlPanel\Volume]
"Key"=dword:10002 ; key clicks: 02 loud, 01 soft, 00 none
"Screen"=dword:10002 ; tap volume: 02 loud, 01 soft, 00 none
"Volume"=dword:99999999 ; system volume; FFFFFFFF is max
"Mute"=dword:7 ; 1=Notifications, 2=Apps, 4=Events,
; 7=Enable all sounds

;---------------------------------------------------------------------
; COM1 RS-485 functionality
; 0=disable, 1=enable
; Set jumpers appropriately
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial]
"RS485"=dword:0


;---------------------------------------------------------------------
; IrDA
; Set IR keys to 1 if JP7 jumpers are configured for IrDA
;
; TxDelayDisable and TxOnly keys are available in
; ADS CE builds 2.21 and later. These keys are useful
; for IrDA transmit-only applications.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\IrDA]
"IRSerialPort"=dword:0 ; 1=Serial2 is IrDA (logic polarity
; and pulse width is different)
"TxDelayDisable"=dword:0 ; 0=delay 10ms between end of transmit and
; turning on receiver (IrDA is half duplex)
"TxOnly"=dword:0 ; 1=disable IrDA receiver


;---------------------------------------------------------------------
; Keypad driver
; (ADS build 3.06)
; This key enables a driver for a 4x4 keypad that maps
; key presses to CE keys as follows (x=no key):
; Col
; 1 2 3 4
; 1 up dn rt lf
; Row 2 RET ESC Start x
; 3 br+ br- vol+ vol-
; 4 TAB menu x x
;
; ADS cable+keypad 610110-40141 matches this driver.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Keypad]
"KeyPadThreadEnable"=dword:0 ; 1=run Keypadthread, 0=disable
"VolumeControlOffset"=dword:100 ; volume change with each keypress
"BLightControlOffset"=dword:A ; backlight intensity change per keypress
"KeyPadOption"=dword:1 ; ADSmartIO
"KeyPadSizeX"=dword:4 ; columns
"KeyPadSizeY"=dword:4 ; rows
"KeyPadTimeOut"=dword:1388 ; 0x1388 = 5Sec
"ShowBuildDate"=dword:0 ; 1=display build date

;---------------------------------------------------------------------
; System Identification
; Use the Ident key for both ActiveSync and for network
; connections to other PCs (eg. in Explorer, you can
; enter a network path such as \\myPC\SharedDrive)
;
; Names may be up to 15 characters long and may not
; include blanks or the characters \/:.*?"<>|
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Ident]
"Name"="ADS_GMaster"
"OrigName"="GMaster"
"Desc"="ADS Graphics Master StrongARM Single Board Computer"

;---------------------------------------------------------------------
; Set Storage memory and Program memory
; Page size is 4096 bytes. Default Value is 256 pages for Object Store.
; If you set 256 pages(dword:100), the storage memory(object store) is
; 256 * 4096 = 1MB. The rest of available memory becomes program memory.
;
; dword:40 leaves 256k for storage
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\MemoryConfig]
"ObjectStorePages"=dword:200

;---------------------------------------------------------------------
; Ethernet/IP settings
; If your network has DHCP service, set that key to 1 and all other parameters
; will be set automatically. Otherwise, enter parameters for your network.
;
; The DoNotInstall key is useful for testing the activity
; timer (Ethernet driver prevents system from going to sleep
; using the timer) or creating dialup connections.
;
; The NetUserInterface key allows you to disable the "no network
; connection" message when you enable DHCP but don't have your
; system connected to the network.
;
; WINS is used primarily for Ethernet ActiveSync communication.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Comm\SMC90001\Parms]
"DoNotInstall"=dword:0 ; 1=do not install Ethernet driver
; (avail: ADS build 2.19 and later)

[HKEY_LOCAL_MACHINE\Platform]
"NETUserInterface"=dword:0 ; 1=Always Yes, 2= Always No,
; other: Pops up Dialog Box

[HKEY_LOCAL_MACHINE\Comm\SMC90001\Parms\TcpIp]
"EnableDHCP"=dword:1 ; 1 = DHCP
"IpAddress"="192.168.1.4" ; MTS FelixRT IP
"DefaultGateway"="0.0.0.0"
"Subnetmask"="255.255.255.0"
"DNS"="0.0.0.0"
"WINS"="0.0.0.0"

;---------------------------------------------------------------------
; Serial ActiveSync Connections
;
; The following keys simplify serial ActiveSync connections.
; They allow automatic connections, and allow you to select
; the Graphics Client serial port to use for your ActiveSync
; connection.
;
; These keys are available in ADS WinCE builds 3.07 and later
;---------------------------------------------------------------------
[HKEY_CURRENT_USER\ControlPanel\Comm]
"AutoCnct"=dword:01 ; 01=enable automatic/direct connections
to desktop computer
; 00=disable

"Cnct"="com1" ; use COM1 for ActiveSync connections
;"Cnct"="com2" to use COM2
;"Cnct"="com3" to use COM3

;---------------------------------------------------------------------
; Persistent ActiveSync Partnerships
;
; The following are registry settings that you can
; add to your ADSLOAD.REG file once you have established
; an Ethernet ActiveSync partnership with your development
; system. This retains your ActiveSync Partnership
; even when power has been lost to your system, or when
; you perform a hardware (pushbutton) reset.
;
; Note that you will have to enter some of the registry
; entries that are specific to your PC.
; These are marked with a "!" for easy searching.
;
; You can read the values for the keys marked with ! from
; your CE device by running \windows\regedit on the device.
;---------------------------------------------------------------------

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows CE Services]
"RasTimeoutResponse"=dword:0000003c
"Version"=dword:00020000

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows CE Services\Partners]
"PCur"=dword:00000001
"Connectoid"="Network Connection"
"AutoDisc"=dword:00000000

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows CE Services]
"ExcludeExts"="lnk,tmp,cdb,mdb"

; ! Enter these setting from your CE device after establishing
; an ActiveSync connection with your host PC
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows CE Services\Partners\P1]
"PName"="MyWorkstation"
"PId"=dword:05af05af

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows CE Services\Partners\P2]
; can enter second host PC partnership information here
"PName"="MyWorkstation2"
"PId"=dword:fa50fa50

; ! Uncomment and update only if you are using Platform Manager and
; TCP/IP Ethernet debugging (ActiveSync is easier)
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows CE Tools\Platform Manager]
; "TLData"="881354794E3332464F52544800"
; "TLName"="TCPIPC.DLL"

[HKEY_LOCAL_MACHINE\Windows CE Services\synchronization\objects\MicrosoftTable]
"Store"="adosync.dll"

;---------------------------------------------------------------------
; NT Login
; The following keys eliminate the need for you to type a
; user name and domain to log into an NT PC.
;
; The password is stored in a binary encrypted form which can
; be extracted from the CE registry. However, the ADS registry
; loader doesn't currently support binary strings. If you don't
; want to type in a password, create a user account on your NT
; workstation that does not require a password. Windows 9x PCs do
; not have security and will display all shared files without a
; password.
;---------------------------------------------------------------------

[HKEY_LOCAL_MACHINE\Comm\Ident]
"Domain"="MyNTStationName"
"Username"="UserAccountName"

;---------------------------------------------------------------------
; Flash Disk
;
; Set the size of the flash disk. Maximum size and start
; address are determined by how much space the build of CE
; takes up in onboard flash (see HWT file). The first 1MB
; of flash is reserved for system files.
;
; The Start and Length values, added together, must be less
; than or equal to the following values:
;
; 09000000 16MB flash installed
; 0A000000 32MB flash installed
;
; The FATUserInterface key automatically responds to dialog boxes
; with messages about the file system. This key is primarily
; useful for headless systems. If your system doesn't include a
; display, ADS recommends that you set this key to answer "1" (yes)
; so that file system errors don't prevent your application
; from running.
;---------------------------------------------------------------------
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\FlashFx]
; "Start"=dword:08B00000 ; 10MB CE image
; "Length"=dword:0500000 ; 5MB flash disk (16MB flash installed)
; "Length"=dword:1500000 ; 21MB flash disk (32MB flash installed)

; "Start"=dword:08D00000 ; 12MB CE image
; "Length"=dword:0300000 ; 3MB flash disk (16MB flash installed)
; "Length"=dword:1300000 ; 19MB flash disk (32MB flash installed)

; "Start"=dword:08900000 ; 8MB CE image
; "Length"=dword:0700000 ; 7MB flash disk (16MB flash installed)
; "Length"=dword:1700000 ; 23MB flash disk (32MB flash installed)

"Start"=dword:09000000 ; 15MB CE image
; "Length"=dword:0000000 ; 0MB flash disk (16MB flash installed)
"Length"=dword:1000000 ; 16MB flash disk (32MB flash installed)


[HKEY_LOCAL_MACHINE\Platform]
"FATUserInterface"=dword:0 ; 1=Always Yes, 2= Always No,
; other: Pops up Dialog Box

;---------------------------------------------------------------------
; Touch Panel Calibration
;---------------------------------------------------------------------



;---------------------------------------------------------------------
; MTS - Settings for National Instruments PCMCIA DAQCard 6036E
;---------------------------------------------------------------------

[HKEY_LOCAL_MACHINE\Drivers\PCMCIA\RLP]
"Dll"="nirlpdriver.dll"
"Prefix"="RLP"
[HKEY_LOCAL_MACHINE\Drivers\PCMCIA\Detect\70]
"Dll"="nirlpdriver.dll"
"Entry"="DetectNiRlp"
Go to Top of Page
  Topic  
 Forum Locked
 Send Topic to a Friend
 Printer Friendly
Jump To:
Eurotech Support Forums © Eurotech Inc. Go To Top Of Page
This page was generated in 0.2 seconds. Snitz Forums 2000