Path: utzoo!dptcdc!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!cs.utexas.edu!uunet!auspex!guy From: guy@auspex.auspex.com (Guy Harris) Newsgroups: comp.mail.uucp Subject: Re: Bidirectional Modem Lines under SunOS 4.0.1 Message-ID: <1445@auspex.auspex.com> Date: 17 Apr 89 19:08:45 GMT References: <1395@auspex.auspex.com> <455@chudich.co.rmit.oz> Reply-To: guy@auspex.auspex.com (Guy Harris) Organization: Auspex Systems, Santa Clara Lines: 53 >Hmmm. A technical point on this... measurements I have made on a Sun-3/260 >with both mti and zs serial ports is this: > > DCD - when low, prevents the Sun driver from receiving data. Any > data received in this state is ignored. > Opening the cua device when DCD is low succeeds but you > can't hear anything! > ie: tie Sun-DCD to Sun-DTR so that you can always hear things > when the device is open (either via cua or tty open). This has not been the default case on the zs ports for quite a while; I assume you ran it on a port with RTS/CTS flow control enabled. (I think RTS/CTS may have been enabled by defaul on very old systems; there are patches to enable it on all ports on SunOS systems up to 4.0, and there is a flag bit that controls it that's settable with "ioctl"s on 4.0.) Were it unconditionally true on all ports, our system wouldn't be successfully dialing out to "uunet", and you wouldn't be reading this article.... This may be true on the MTI ports, since Systech used the Signetics 2661 EPCI chip, which *always* shuts the receiver off when DCD goes down. The Zilog 8530 chip used on the zs ports (and ALM-2 ports) allows this to be turned or off; turning it on also turns RTS/CTS flow control on. The patch mentioned in the previous paragraph causes this to be turned on for all ports; the "ioctl" bit in 4.0 turns it on for a particular port. > DSR - when low, prevents the Sun driver from allowing open's on > the device to complete (unless O_NDELAY is specified or > the kernel is configured to ignore "carrier" or a cua open is > attempted). > ie: tie Sun-DSR to remote-DTR so that the tty open succeeds > when a connection to the remote happens. This is true only on the MTI ports. Systech and Sun compensated for the 2661's obnoxiousness by making DSR be the line that is treated as "carrier detect", and wiring CD high. > CTS - when low, prevents the serial chip from sending data iff: > > - the zs driver has been patched to set the bit in the > scc that enables hardware flow control > (patch needed at least on SunOS 3.whatever) If the bit in the scc is not set, DCD doesn't have to be high in order to receive data; see above. This bit is *not* set by default. I'll bet you applied the patch, which forcibly sets the bit on all ports, since you claim that DCD *must* be high in order for the receiver to work. > - using the mti driver, in which case hardware flow control > is on all the time, regardless of kernel running. Even if you write your own driver, this will still be the case - it's a characteristic of the chip see above.