Custom Terminal Line Discipline - TIOCSERGETLSR

Brett Swimley brett.swimley at aedinc.net
Wed Mar 13 17:41:12 UTC 2002


Hello,

I need to register a custom line discipline for my tty driver to
allow me to monitor the transmitter shift register to see when my last
character has been transmitted. Then I can control an RF tranceiver with my
UART's RTS output.

All the documentation I have found refers to using ioctl with TIOCSERGETLSR
to get the line status register and monitoring TIOCSER_TEMT.  However, these
are not defined in rtems-ss-20011025.  I can write my custom Line Discipline
to provide this values.

What I really need is:

Linux defines TIOCSERGETLSR as 0x5459.  I was going to define this in
ttycom.h.  Is this the proper place to do this?

Likewise, TIOCSER_TEMT is defined as bit 0 (e.g 0x01) of the Again, is
ttycom.h the proper place to define this?

Regards,

Brett Swimley




More information about the users mailing list