Subject: Re: db> message after some hours (using Serial Console only)
To: M L Riechers <mlr@rse.com>
From: Bill Studenmund <wrstuden@netbsd.org>
List: port-macppc
Date: 08/01/2002 09:58:24
On Wed, 31 Jul 2002, M L Riechers wrote:

> On Wed, 31 Jul 2002 10:07:13 -0700 (PDT) Bill Studenmund
> <wrstuden@netbsd.org> averred:
>
> >> Perhaps a better idea would be to use GND instead of DTR?
> >
> > No. The spec says (for RS-232) a space (0) is > +3 V, and a mark is < -3
> > V. Ground is not a valid voltage. Using ground relies on the hysteresis of
> > the receiver.
>
> You're right, of course.  The specs really do say that. However, most
> RS-232 receivers (and all of those I've used and/or run across) are
> perfectly happy receiving data switched between ground and, say +5
> Volts. So you can run your 5 Volt only system into a terminal or
> modem, for instance.

How did you check that? Did you pull out a multi-meter on it?

I ask as a long time ago (like late 80's, back when I followed all sorts
of chip releases :-) a number of the line driver makers came up w/ chips
that had +5V/GND in, yet supplied +5/-5 outputs. It's easy, you just add a
tank capacitor power inverter, and you've got -5 V.  All in one package.

For instance, look at: http://www.national.com/ds/DS/DS14C238.pdf . This
puppy is (well claims it is) fully RS-232 compliant on voltages, and only
needs +5/gnd. It's quite proud of its internal DC-DC converter. :-)

> > For a mac it'd be real bad because the mac really has differential
> > data input. Typical serial cables tie RS-232 data in to RD-, and ground
> > RD+....
>
> Aaaarg, Aaaarg, and double Aaaarg.  That's most incommodious, and
> shame on them.  The trick above is to set your RD+ to ~ 3.0 Volts,
> (say, actually about 3 diode drops from ground towards +5 (or whatever
> hi) ~2.4V) simulating a reasonable 3.0 Volt decision point that RS-232
> would use.  (I know, I know, -3 to +3 (supposed) hysteresis, but it
> works. I suspect our modern chips are a bit more sophisticated than
> the spec developed (can it be?) some 40 years ago).

The chips are more sophisticated, yes. But the standard says -3 for Mark.
You really can't change that. If you don't hit at least -3 V, there will
be old devices your new one won't work with. So you HAVE to do it. Since
you have to do it, why play w/ ground as a signal voltage?

> Serial cables ground the RD+ input, huh?  Can't afford $0.001(US)
> diodes and resistors, maybe?  (More likely, can't find a good source
> of hi?)  Maybe that's a source of some of the troubles and confusion
> people have had hooking up to macs.  Maybe me, for one.

Grounding the RD+ is a perfectly fine thing to do. Apple even does it for
the non-balanced inputs (DTD & CTS). Also, using diodes as you describe
above would burn power, while tieing to ground doesn't.

Take care,

Bill