Rob,
You don't say what device you're using, but if it's OS5, then that is most likely your problem.
We've had erratic results using SrmSetWakeupHandler on OS5 devices, we were not able to solve these, and had to rewrite the product to use the Alarm Manager callback routines instead.
Regards
John Sutton


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED]
Sent: 02 August 2005 01:07
To: Palm Developer Forum
Subject: trouble with serial communcation -- SrmSetWakeupHandler

I am attempting my first Palm app so be gentle. Basically I am  using the serial interface to receive and display data.   I am attempting to use SrmSetWakeupHandler but it's not going so well.  When I run on the device itself everything is good until I actually try to shove data to the Palm.  I get a fatal error and it hangs.  I have a feeling that my callback function isn't getting called properly.  When I set the callback to NULL then the fatal goes away, but ofcourse nothing happens :)  I put in a test FrmAlert in my callback to check if it's even making it there and it never shows up.  Any thoughts?  I have 2 specific questions;
 
1) does anybody have a good working example of using SrmSetWakeupHandler and how to set the callback function(not the ones from palm dev, I have already read through that one)?  It might just be a simple C coding error on my side.  When I compile, Codewarrior gives me an error that my WakeupHandlerProcPtr variable isn't initialized before use.
 
2) Is there a way to use the emulator to debug these sort of problems?  I don't really have a good way to control and drive the serial stream into the PC for the emulator to use.  Currently I am using DockLight to generate the rs232 patterns from my PC to my Palm device for testing.  I can't figure out a way to use DockLight to drive patterns to the emulator without doing a loop around serial connection on my PC.  I was hoping there is an easy way to drive phoney bits to the serial manager directly in sofware.
 
Thanks for any and all help.
-Rob
--
For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ --
For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/

Reply via email to