On all Palm branded units with RS232 ports, DTR is hardwired so forget about
controlling it. RTS is necessary for flow control over 9600 baud but I
don't think there are APIs to directly control RTS. That's not to say you
can't, there are applications that do by accessing the hardware directly.
The only one I can think of off-hand is an app someone wrote to control an
X10 firecracker serial module using the RTS line. You may be able to dig up
the source code, I think the project was called 'Sparkler'.
----- Original Message -----
From: "Randy" <[EMAIL PROTECTED]>
Newsgroups: palm-dev-forum
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent: Friday, April 16, 2004 2:35 PM
Subject: Program control of RTS/DTR lines?
> Originally posted in comm-dev-forum but no answer.
>
> I searched the net/Palm/archives and get conflicting information about
> whether you can or can not truely control the RTS line from within a
> program. Not have the API do auto-flow control but to drive the RTS line
> high or low on my program command.
>
> I've found out that the DTR "is not supported on all hardware" and appears
> always high. I;ve found nothing to say which HW actually does support DTR
> control.
>
> I'm particularly interested for the M5xx series.
>
> I've tried various combinations of code (like below) using the new Serial
> Mgr lib with an without srmSettingsFlagRTSAutoM bit set but using POSE
>
> (v3.5) and a serial sniffer HW, the RTS line never changes.
>
> void SetRTS(bool setrts)
>
> paramSize = sizeof(flags);
>
> status = SrmControl(port->portId, srmCtlGetFlags, &flags, ¶mSize);
>
> if (eSUCCESS == status)
>
> {
>
> if (setrts)
>
> flags |= srmSettingsFlagRTSInactive;
>
> else
>
> flags &= ~srmSettingsFlagRTSInactive;
>
> paramSize = sizeof(flags);
>
> status = SrmControl(port->portId, srmCtlSetFlags, &flags, ¶mSize);
>
>
>
>
>
> Any TRUE information? Should the above code really suppose to set the RTS
> line state hi/lo?
>
> Or is some direct MPU peek/poke needed ala L.Marcolina post re' Zire71
> (comm-dev-forum).
>
> Thanks
>
>
>
>
>
>
>
> --
> For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/