Subject: cellphone modem troubles
To: None <tech-net@netbsd.org>
From: Matthias Ferdinand <mf+tech-net@mfedv.net>
List: tech-net
Date: 12/26/2006 03:53:05
Hello,

I converted my Compaq Armada M700 notebook (P3) from SuSE Linux 9.1 to 
NetBSD3.0. While most other things work ok,  I seem to have trouble 
accessing the data/fax capability of my cellphone (Siemens ME45 or Siemens 
S35) from the notebook. Connected via data cable to serial port /dev/tty00.

Settings under /etc/ppp/... are the same as they were before under Linux.

NetBSD 3.0 GENERIC, pppd-2.4.3nb1

Combinations that work, dialing into a Lucent Portmaster digital modem:
 a) pppd using a normal voice modem on /dev/tty00 (Creatix 28.800)
 b) minicom using ME45 cellphone on /dev/tty00
    (Hardware flow control, 19200 8N1)
 c) pppd using ME45 cellphone on a Debian Linux host

>From b) and c) I conclude that the phone and the cable are ok, from a) I 
conclude that pppd and kernel ppp are basically working.

Now trying the ME45, /var/log/messages contains the following:

Dec 26 03:13:37 shlab pppd[173]: pppd 2.4.3 started by adminmf, uid 0
Dec 26 03:13:38 shlab chat[754]: abort on (BUSY)
Dec 26 03:13:38 shlab chat[754]: abort on (NO CARRIER)
Dec 26 03:13:38 shlab chat[754]: abort on (NO DIALTONE)
Dec 26 03:13:38 shlab chat[754]: abort on (NO ANSWER)
Dec 26 03:13:38 shlab chat[754]: abort on (ERROR)
Dec 26 03:13:38 shlab chat[754]: abort on (DELAYED)
Dec 26 03:13:38 shlab chat[754]: send (at S7=45 S0=0 M1 L3 V1 X4 &c1 E1 
Q0^M)
Dec 26 03:13:38 shlab chat[754]: expect (OK)
Dec 26 03:13:38 shlab chat[754]: at S7=45 S0=0 M1 L3 V1 X4 &c1 E1 Q0^M^M
Dec 26 03:13:38 shlab chat[754]: OK
Dec 26 03:13:38 shlab chat[754]:  -- got it
Dec 26 03:13:38 shlab chat[754]: send (atdt068166810^M)
Dec 26 03:13:39 shlab chat[754]: expect (CONNECT)
Dec 26 03:13:39 shlab chat[754]: ^M
Dec 26 03:14:00 shlab chat[754]: atdt068166810^M^M
Dec 26 03:14:00 shlab chat[754]: CONNECT
Dec 26 03:14:00 shlab chat[754]:  -- got it
Dec 26 03:14:00 shlab pppd[173]: Serial connection established.
Dec 26 03:14:00 shlab pppd[173]: Using interface ppp0
Dec 26 03:14:00 shlab pppd[173]: Connect: ppp0 <--> /dev/tty00
Dec 26 03:14:00 shlab pppd[173]: Modem hangup
Dec 26 03:14:00 shlab pppd[173]: Connection terminated.
Dec 26 03:14:02 shlab pppd[173]: Exit.

Immediately after "Serial connection established", pppd says "Modem 
hangup".

And sometimes (very rarely, indeed), it says "not 8-bit clean":
Dec 26 03:19:10 shlab pppd[234]: Serial connection established.
Dec 26 03:19:10 shlab pppd[234]: Using interface ppp0
Dec 26 03:19:10 shlab pppd[234]: Connect: ppp0 <--> /dev/tty00
Dec 26 03:19:10 shlab pppd[234]: Modem hangup
Dec 26 03:19:10 shlab pppd[234]: Connection terminated.
Dec 26 03:19:10 shlab pppd[234]: Serial link is not 8-bit clean:
Dec 26 03:19:10 shlab pppd[234]: All received characters had bit 7 set to 0
Dec 26 03:19:10 shlab pppd[234]: Last 2 characters were: \0\0
Dec 26 03:19:12 shlab pppd[234]: Exit.

pppd options I tried (without any difference)
  - nocrtscts
  - crtscts
  - cdtrcts
  - nocdtrcts
  - crtscts nocdtrcts
  - nocrtscts cdtrcts
  - none of these settings
  - passive

I am running out of things to try. Can somebody give me some more hints? 
Perhaps I need to look into 8N1 (... not 8-bit clean ...), where is this 
set in pppd (or outside of pppd?) ? Other differences in serial port 
handling between NetBSD and Linux?

Thankful for any help.

Best regards
Matthias Ferdinand