lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Force PPP TermReq (Lwip 2.0.0 RC2)


From: Patrick Klos
Subject: Re: [lwip-users] Force PPP TermReq (Lwip 2.0.0 RC2)
Date: Thu, 4 Aug 2016 10:15:56 -0400
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0

On 8/4/2016 9:54 AM, Greg Smith wrote:

Hello.

I'm looking for a way to let a PPP peer know that the connection is dropped and needs to reestablish in 2.0.0rc2.  In my case, one particular usage of this is if one peer unexpectedly resets (for example, via power loss) and then comes back up and wants to reconnect.  At this point, it's lost its IP address, etc. and needs to reconnect to the peer.  But for some reason, the peer (not Lwip) is ignoring all LCP packets.  (I'm not sure if that's good protocol or not, but I have to deal with it.) 


If the peer just came up, why isn't it simply starting PPP on it's side?  Or is the LwIP host the peer that got reset in this case? 

Does the serial link have any means to tell that the link went down? (i.e. modem control signal?  carrier detect?)  Or is this a simple 3-wire serial connection between 2 devices (GND, RX, TX)?

Can you get a trace of the serial line to show the exact bytes that are going back and forth?  That usually has all the clues you need to find and fix a problem (unless the non-LwIP peer has a broken PPP).

So I was thinking that if I could explicitly tell the peer to terminate (TermReq), then perhaps we could restart normally.


Based on what you said, your non-LwIP peer would ignore that packet as well since it is an LCP packet.

Unfortunately, if I just try a ppp_close() (on the peer that reset), Lwip is smart enough to realize it's in the DEAD state and does not try to send a TermReq.  Is there a way to force it to send a TermReq?  Or is there some other way to let the peer know that the connection needs to be reestablished?


Again, the TermReq packet is an LCP packet.  If your peer is ignoring all LCP packets (as you stated earlier), it's just ignore that packet as well.  I'm sure you could find a way to get LwIP to send the packet - just not sure if it'll help given your symptoms.

Describe the exact link setup between the peers and get a packet trace.  :o)

Patrick Klos
Laufer Wind


reply via email to

[Prev in Thread] Current Thread [Next in Thread]