>"Anamika NG" <[EMAIL PROTECTED]> a éit dans le message de RÃgis St-Gelais 
>wrote:

> > My PDA application doesn't work on Palm OS 5. My application
> > basically sends commnads through Serial port, receives the
> > response and displays the value to the user.
> >
> > I noticed that only some commands that is sent out by my
> > application receives the response while others not. After
> > extensive debugging, I noticed that when the buffer which
> > holds the bytes received from Serial port is big (500 bytes),
> > it doesn't get any response for that command. 
> > However , If I make the buffer small, I get the response.
> >
> > I am still using Old Serial Manager functions (OldSerMgr.h)
> > just to be backwards compatible. Could this be causing any
> > problem on Palm OS 5?

> > or Is there any limitation on the no of bytes received from
> > Serial Port in Palm OS 5? or is there anything I am missing
> > here??


> I think that on OS 5 you need to load the old serial manager
> library. Search the archive, it was discused before.


Or write wrapper functions to selectively call old or new APIs depending on 
what's currently available on the device. This is even better as you're then 
taking advantage of the most efficient serial library available on every device.

You may check whether the New Serial Manager is available like this:

UInt32    feature;

if ( FtrGet( sysFileCSerialMgr, sysFtrNewSerialPresent, &feature ) == errNone )

As for APIs, writing the wrappers is very simple as arguments are almost the 
same for both serial libraries.


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

Reply via email to