Subject: Probs w/ pppd over null modem
To: None <port-mac68k@netbsd.org>
From: Johan Carlsson <carlsson@earthling.net>
List: port-mac68k
Date: 10/21/1998 20:22:10
Sorry if this is slightly off-topic since it involves a PC running FreeBSD
(I'm goofing around w/ all the BSDs). I'm taking it to this friendly and
all-knowing list anyway (have mercy ;-).

So, I'm trying to connect a FreeBSD PC (acheron) w/ a NetBSD IIsi (spock)
w/ a null-modem cable from PC COM2 to the Mac modem port. FreeBSD 2.7.2
(homebrewed kernel but I haven't messed w/ sio1 or ppp0) and NetBSD/mac68k
1.3.2 GENERICIWMSBC#5, respectively. Since there seems to be some
arbitrariness wrt how a RS-232 DB-9 to RS-422 DIN-8 null modem should be
wired I've tried four different ones (see below). The result is the same
w/ all of them, like this:

I fire up pppd from the command line on the PC:

acheron # pppd cuaa1 9600 debug kdebug 7 crtscts modem silent

And then on the IIsi:

spock # pppd tty00 9600 debug kdebug 7 crtscts modem

This is from /var/log/messages on the IIsi:

Oct 20 15:45:29 spock pppd[200]: pppd 2.3.1 started by johan, uid 0
Oct 20 15:45:29 spock pppd[200]: Using interface ppp0
Oct 20 15:45:29 spock pppd[200]: Connect: ppp0 <--> /dev/tty00
Oct 20 15:45:29 spock /netbsd: ppp0 output:
ff03c0210101000e05067116979c07020802
Oct 20 15:46:01 spock pppd[200]: LCP: timeout sending Config-Requests
Oct 20 15:46:01 spock pppd[200]: Connection terminated.
Oct 20 15:46:03 spock pppd[200]: Exit.
Oct 20 15:45:58 spock last message repeated 9 times

And this is from /var/log/messages on the PC:

Oct 20 15:46:29 acheron pppd[744]: pppd 2.3.5 started by carlsson, uid 0
Oct 20 15:46:29 acheron pppd[744]: Connect: ppp0 <--> /dev/cuaa1
Oct 20 15:47:09 acheron pppd[744]: Modem hangup, connected for 1 minutes
Oct 20 15:47:09 acheron pppd[744]: Connection terminated, connected for 1
minutes

I don't really know what "LCP: timeout sending Config-Requests" means.
I've also tried not to use hard carrier/hw handshaking (local/nocrtscts)
and the alternative serial device (ttyd1) on the PC to no avail. Only
difference is bytes 41-56 (1-40 and 57-72 are identical) in the ten
packets sent by the IIsi.

These are the null modems I've tried (one and two are the standard ways,
I think, three and four are variants based on the FreeBSDish null modem
found in their Handbook, chapter 14.2.2.1):

           One:                           Two:
        DTR -- GPi                     DTR -- GPi
         TD -- RxD-                     TD -- RxD-
         RD -- TxD-                     RD -- TxD-
   DCD, DSR -- HSKo          DCD, DSR, CTS -- HSKo
        CTS -- TxD+                     SG -- Gnd, RxD+
         SG -- Gnd, RxD+               RTS -- HSKi
        RTS -- HSKi

          Three:                          Four:
         TD -- RxD-                     TD -- RxD-
         RD -- TxD-                     RD -- TxD-
        DCD -- HSKi, TxD+         DCD, DSR -- HSKo, HSKi
         SG -- Gnd, RxD+                SG -- Gnd, RxD+
        DSR -- HSKo               CTS, RTS -- GPi
   CTS, RTS -- GPi

Electrically speaking they're all OK, I checked w/ a multimeter. Dunno if
they're sane, though.

Oh yeah, I didn't reboot between all the test (I did kill and restart pppd
of course). Maybe it would've been good if stty had refreshed the serial
devices between each test?

Hope I didn't leave something relevant out, TIA,

Johan