I think it will not work because my application isn't executing, it is driver executed on backgroung - I set SrmSetWakeupHandler and exit... So the handler perhaps uses current application's stack. And it would be nice to change stack to my own memory when I receive "interrupt"...

BTW: what I should look for in resources? I use prc-tools and pilrc for building resources...

Hynek Sladky



Logan Shaw wrote:
Hynek Sladky wrote:

I am writing routine for Serial WakeupHandler and it sometimes causes soft-reset due to stack overflow. Is it possible to change stack size or to use my own stack during executing my wakeuphandler? How is stack size assigned from PalmOS to applications?

Is it possible to get free stack size? The only function I found which tells something about stack is SysGetStackInfo but it gives me information about total size of stack... I tried this function and it seems that stack in applications is about 4KB and it could be really insufficient...


4KB sounds right.

If you want to change it, you can change the Application Preferences.
This is a resource that lives inside your application.  The OS uses
it to determine how big of a stack to give your application when it
launches.  How you change it depends on what tool you use to build
resources (Palm OS Resource Editor with PODS, Constructor with
CodeWarrior), etc.

  - Logan


--
For information on using the PalmSource Developer Forums, or to unsubscribe, 
please see http://www.palmos.com/dev/support/forums/

Reply via email to