Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 4 Jun 1999 10:59:00 -0400 (EDT)
From:      Mikhail Teterin <mi@aldan.algebra.com>
To:        questions@freebsd.org
Cc:        miquels@cistron.nl, walker@clinet.fi
Subject:   sio0: minicom works, chat(1) does not :(
Message-ID:  <199906041459.KAA06987@misha.cisco.com>

next in thread | raw e-mail | index | archive | help
Hello!

I'm trying  to automate dealings with  an MS-DOS box over  a serial line
with a  FreeBSD-3.0 machine. The box'  is listening for commands  on its
com2. DOS commands were:

	mode com2 baud=9600 parity=n data=8 stop=1
	ctty com2

Using minicom I have  no problems seeing the DOS prompt  in my xterm and
issuing any  DOS command my heart  pleases (except that BS  key does not
work, but it does not bother me too much).

However, my attempts to automate fail:

	% chat -V -e -v -s "" "echo hello" "hello" < /dev/cuaa0 > /dev/cuaa0
	send (echo hello^M)
	 -- write failed: Input/output error
	Failed

The terminal settings are as follows:

	% stty -a < /dev/cuaa0
	speed 9600 baud; 0 rows; 0 columns;
	lflags: -icanon -isig -iexten -echo -echoe -echok -echoke -echonl
		-echoctl -echoprt -altwerase -noflsh -tostop -flusho -pendin
		-nokerninfo -extproc
	iflags: -istrip -icrnl -inlcr -igncr -ixon -ixoff -ixany -imaxbel -ignbrk
		-brkint -inpck -ignpar -parmrk
	oflags: -opost -onlcr -oxtabs
	cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow
		-dtrflow -mdmbuf
	cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>;
		eol2 = <undef>; erase = ^?; intr = ^C; kill = ^U; lnext = ^V;
		min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T;
		stop = ^S; susp = ^Z; time = 0; werase = ^W;

When minicom is running, the stty's output is a little different:

--- plain.stty     Fri Jun  4 10:19:58 1999
+++ minicom.stty   Fri Jun  4 10:19:47 1999
@@ -5 +5 @@
-iflags: -istrip -icrnl -inlcr -igncr -ixon -ixoff -ixany -imaxbel -ignbrk
+iflags: -istrip -icrnl -inlcr -igncr ixon ixoff -ixany -imaxbel ignbrk
@@ -8 +8 @@
-cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow
+cflags: cread cs8 -parenb -parodd hupcl clocal -cstopb -crtscts -dsrflow
@@ -13 +13 @@
-       stop = ^S; susp = ^Z; time = 0; werase = ^W;
+       stop = ^S; susp = ^Z; time = 5; werase = ^W;

Should I change anything? Thanks in advance for any clues!

	-mi


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199906041459.KAA06987>