Frage zu termios - Struktur
-
Hallo,
kann mir jemand auf die Sprünge helfen:
Was genau macht das Flag CLOACL im Element c_cflag in der Struktur termios?
In meinem Buch steht: "Alle Modemstatusleitungen sollen ignoriert werden"
Unter "man termios" findet man "ignore modem control lines". Soweit so gut. Aber welches sind die Modemstatusleitungen? Ich möchte über RS232 eine Kommunikation mit einem anderen PC aufbauen (nutze daher Pin 2,3 und 5). Pin 2 und 3 sind gekreuzt (falls das wichtig wäre).Muß ich dieses Flag setzen? Oder von was hängt das ab?
Gruß, toolen
-
Das Flag heißt CLOCAL - vertippt
-
Kenn mich da selbst nicht so gut aus, aber folgende Links helfen dir vielleicht weiter:
http://www.ussg.iu.edu/hypermail/linux/kernel/0304.0/1584.html
http://www.die.net/doc/linux/man/man1/statserial.1.htmlDragon Fly BSD termios(4) schrieb:
If CLOCAL is set, a connection does not depend on the state of the modem
status lines. If CLOCAL is clear, the modem status lines are monitored.Under normal circumstances, a call to the open() function waits for the
modem connection to complete. However, if the O_NONBLOCK flag is set or
if CLOCAL has been set, the open() function returns immediately without
waiting for the connection.http://leaf.dragonflybsd.org/cgi/web-man?command=termios§ion=4