Forum Topic - Trouble getting PPP link over serial for debugging target: (5 Items)
   
Trouble getting PPP link over serial for debugging target  
Hi,

First of all I apologise for another thread on PPP over serial as I realise that similar threads have popped up many 
times in the past, but after scrawling through them I still could not find the answer.

I'm targetting the i.MX31 on custom hardware, however I am using the i.MX31ADS BSP's serial driver on ser1 and the ksh 
terminal works successfully on it.  I am running Momentics IDE 4.6 on Windows XP. 

I have followed the guide: http://www.qnx.com/developers/docs/6.4.1/ide_en/user_guide/target.html carefully however no 
matter what I try I cannot get windows to connect to the target, even using the settings as outlined in "Example for 
linking an embedded system running QNX Neutrino to a Windows network connection".  Now I do know that the serial driver 
on the i.MX31 is started by default disabling hardware flow control, therefore I tried starting pppd without the "-
crtscts" option, but with no success. e.g.

/usr/sbin/pppd persist auth +chap 10.0.0.1:10.0.0.2 netmask 255.255.255.0 /dev/ser1 115200

Upon starting pppd, there is garbage/data periodically sent over the serial link by the target so something is happening
, however whenever I try to connect to the target with windows I get the "Dialing..." progress window but it always 
fails with error "777 - The connection attempt failed because the modem (or other connecting device) on the remote 
computer is out of order.

I only have the one serial connection on our target and currently no USB or ethernet, therefore I cannot have a second 
terminal to debug the PPP connection with. 

Does anyone have any suggestions?

Thanks,
Radek.


RE: Trouble getting PPP link over serial for debugging target  
You could use portmon on windows to observe the packets exchanged over the serial link. 

Ashwin

-----Original Message-----
From: Radek Pesina [mailto:community-noreply@qnx.com] 
Sent: Friday, July 31, 2009 11:32 AM
To: drivers-networking
Subject: Trouble getting PPP link over serial for debugging target

Hi,

First of all I apologise for another thread on PPP over serial as I realise that similar threads have popped up many 
times in the past, but after scrawling through them I still could not find the answer.

I'm targetting the i.MX31 on custom hardware, however I am using the i.MX31ADS BSP's serial driver on ser1 and the ksh 
terminal works successfully on it.  I am running Momentics IDE 4.6 on Windows XP. 

I have followed the guide: http://www.qnx.com/developers/docs/6.4.1/ide_en/user_guide/target.html carefully however no 
matter what I try I cannot get windows to connect to the target, even using the settings as outlined in "Example for 
linking an embedded system running QNX Neutrino to a Windows network connection".  Now I do know that the serial driver 
on the i.MX31 is started by default disabling hardware flow control, therefore I tried starting pppd without the "-
crtscts" option, but with no success. e.g.

/usr/sbin/pppd persist auth +chap 10.0.0.1:10.0.0.2 netmask 255.255.255.0 /dev/ser1 115200

Upon starting pppd, there is garbage/data periodically sent over the serial link by the target so something is happening
, however whenever I try to connect to the target with windows I get the "Dialing..." progress window but it always 
fails with error "777 - The connection attempt failed because the modem (or other connecting device) on the remote 
computer is out of order.

I only have the one serial connection on our target and currently no USB or ethernet, therefore I cannot have a second 
terminal to debug the PPP connection with. 

Does anyone have any suggestions?

Thanks,
Radek.






_______________________________________________

Networking Drivers
http://community.qnx.com/sf/go/post34984


Re: RE: Trouble getting PPP link over serial for debugging target  
Hi,

Thanks for the tip, that's a nice tool!

Only thing is I'm not sure what to make of the data (log file attached)?  Any ideas?

Thanks,
Radek.

Attachment: Text portmon-ppp.LOG 13.89 KB
RE: RE: Trouble getting PPP link over serial for debugging target  
The dialer first opens the serial port. Gives modem init commands expecting a modem at the other end. (ATE1 = Modem 
command echo enable. Some more command could be sent as per settings). 
In your case there is no modem in between so you could send good responses for any commands received before starting 
starting pppd or disable the modem commands if possible. 

But still AFAIR the winx client also send client string which needs to be responded with clientserver before ppp 
negotiation begins. You could use chat program to do this. 


HTH
Ashwin

-----Original Message-----
From: Radek Pesina [mailto:community-noreply@qnx.com] 
Sent: Friday, July 31, 2009 11:57 AM
To: drivers-networking
Subject: Re: RE: Trouble getting PPP link over serial for debugging target

Hi,

Thanks for the tip, that's a nice tool!

Only thing is I'm not sure what to make of the data (log file attached)?  Any ideas?

Thanks,
Radek.





_______________________________________________

Networking Drivers
http://community.qnx.com/sf/go/post34986
Re: RE: RE: Trouble getting PPP link over serial for debugging target  
Hi Ashwin,

Okay got there in the end - the windows ppp deamon sends out the string 'CLIENT' once every three seconds. It expects to
 receive the string 'CLIENTSERVER', and when it does it starts PPP handshaking. So the chat command defines expect and 
send statements. expect=CLIENT, send=CLIENTSERVER.
This works a treat :)

So basically I needed to start PPPD with the "chat CLIENT CLIENTSERVER" argument (as below).

/tmp/pppd connect "chat CLIENT CLIENTSERVER" nodetach auth +chap 192.168.1.23:192.168.1.22 netmask 255.255.255.0 /dev/
ser1 115200 &

Maybe this would be worth-while adding to the "Preparing Your target" section of the QNX help?


Cheers,
Radek.