RE: should RTS init in serial core be tied to CRTSCTS
From: Tosoni
Date: Mon Mar 12 2007 - 05:24:01 EST
Krzysztof Halasa wrote:
> "Tosoni" <jp.tosoni@xxxxxxxxx> writes:
> > As far as I know in the old times this was the *standard*
> way to use a modem
> > (per CCITT V24), and even nowadays many modems can handle
> this method for
> > transmit, to stay compatible with the standard.
>
> I think it wasn't standard for real modems as they were full-duplex
> (even these 1200/75 or what was that) but it was for other devices
> such as current loops (which were frequently half-duplex).
>
It has always been the standard for all modems. The mistake comes from the
fact that the serial ports has been used extensively to drive things which
are *not* modems (say, printers and VT100 consoles on Unix systems). Such
devices did not need the standard-specified RTS function.
CCITT V24 says about RTS: "...this signal drives the DCE and sets it to
transmit data..." (translated from french)
CCITT V24 does not constraint the DCE to being half or full duplex.
CCITT V24 says nothing about using RTS to handle flow control.
> I've seen such devices quite recently, perhaps ~ 10 years ago.
> OTOH I think even "current" PC BIOSes use such signaling.
Even Windows implements the CCITT view of RTS, via a flag named "RTS_TOGGLE"
>
> > Think of radio modems. Some are inherently half duplex.
>
> Sure. But /dev/ttyS* ports are full-duplex, with CRTSCTS or without,
> so they don't use such handshaking.
A full duplex port can be used for both full- and half- duplex. A half
duplex modem cannot be used on a full-duplex-only port. So Linux should be
adapted to the standard, since we cannot adapt the standard to Linux.
> /proc is probably no-no.
Then sysfs sounds good to me.
>
> For such signaling, it would perhaps be better to invent another flag,
> similar to CRTSCTS. The driver would, of course, need some real code
> for that.
Another flag would help to drive modems, yes. But it would not help keeping
RTS low at open, because we need to open the port (which raises RTS) in
order to set the flag. Hence the need for an extra parameter in sysfs.
Best regards,
Jean-Pierre Tosoni
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/