Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2002-01

Serial Port programming under Linux...

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Rainer Hantsch

Hello everybody,

and all the best in the new year!

I have a small problem and I hope that somebody is here who knows an answer.

In the past (many years ago), I wrote a small RTTY (Radio Tele TYping) program for my father (he is an radio amateur). This program was written in TP and used X00 to do the serial communication with his self built modem. DTR switches between sending and receiving, TxD and RxD are used like a normal wire link to another terminal, but uses 45.5 bps/ 5 Data-Bits/ 2 Stop-Bits/ No-Partity.

Because of this very low speed it is no must to do special buffering, but it still would be nice if I wouldn't have to work on a character-by-character level, if possible.
With X00 on DOS, which also supports nothing below 1200bps, I had to initialize X00 first (setting the correct data length,...) and then re-configure the UART with direct access to the much lower speed. X00 didn't recognize that and so I had what I wanted: 45.5 bps, buffered through X00. But this is surely NOT portable to LINUX...
Instead, it starts to be a real problem to setup a serial port to this very exotic speed of 45.5 bps, expecially because I never programmed such things before! I had a look into the ObjCOM unit which I plan to use, but it is very confusing and poorely documented.
Another handicap is that my father's shack (equipment) is 80km away from my office, so it is very hard to find the solution by trial and error...

My questions:
-------------
o Does LINUX support only those speeds which are pre-defined in 'serial.h', or does it allow also other speeds?
o Does anybody have experience with ObjCOM? OnjCOM seems to be the best replacement for X00-Fossil, because it adds buffering, if I understood it right. I wrote to the developer of this unit, but it seems that he is either not really interested in helping or he also has not enough experience himself... :-/

I will be very happy to receive some useful hints which really help me solving my little problem.

Thanks for your answers,

Ing. Rainer Hantsch

\\|// Ing. Rainer HANTSCH - Hardware + Software (o o) Forget Windoze! -- We focus on L-I-N-U-X... --oOOo-(_)-oOOo-------------------------------------------------- Ing. Rainer HANTSCH | e-Mail:
Khunngasse 21/20 | www : http://www.hantsch.co.at A-1030 Vienna | Tel. : ++43 - 1 - 7988538 0 ---------------------| Fax : ++43 - 1 - 7988538 18 ** AUSTRIA ** | Mobile: ++43 - 664 - 9194382 -----------------------------------------------------------------

Reply by email

Marco van de Voort
to Rainer Hantsch
Show quoted text 10 lines
o Does LINUX support only those speeds which are pre-defined in 'serial.h', or does it allow also other speeds? o Does anybody have experience with ObjCOM? OnjCOM seems to be the best replacement for X00-Fossil, because it adds buffering, if I understood it right. I wrote to the developer of this unit, but it seems that he is either not really interested in helping or he also has not enough experience himself... :-/ I will be very happy to receive some useful hints which really help me solving my little problem.

I don't know, but:
Talk to the people of www.openxp.de, they are busy with this kind of stuff.

Reply by email