[lwip-users] ppp over serial works with gsm modem sim900d but not working with sim5216j using same controller harware
hii , i have implemented ppp over serial using gsm modem sim900d. and it works fine.device gets ip address properly. but when I replaced GSM modem with sim5216j ,ppp not able to established connection with sim5216j. i am using same code and hardware which used for sim900d implementation. so i have monitored gsm modem response for ppp frames,which i found not as per protocol. for ex. sim 900d response for ipcp frame: 7E FF 03 80 21 02 03 00 16 03 06 DF E8 B4 7F 81 06 3B 90 7F 75 83 06 CA 38 D7 29 1A 39 7E sim 5216j response for ipcp frame: 7E 80 21 02 0A 00 16 03 06 6A CF 56 68 81 06 3B 90 7F 75 83 06 CA 38 D7 29 DE 27 7E so as per my knowlege,address byte and control byte i.e. 2nd and 3rd byte of sim 900d response is missing in sim5126j response. so any one have idea whats going on.please help me if u have faced this kind of problem or have solution for it. regards, Rohan Mande. -- View this message in context: http://lwip.100.n7.nabble.com/ppp-over-serial-works-with-gsm-modem-sim900d-but-not-working-with-sim5216j-using-same-controller-hare-tp24261.html Sent from the lwip-users mailing list archive at Nabble.com. ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] PPP no IP address assigned
Hello Michael, On Wed, Apr 01, 2015 at 08:47:03AM +0200, Michael Waeber wrote: Hi all I try to integrate PPP with a GPRS modem in our system. lwIP works well for ethernet in our system since 3 years. Since PPP is currently actively developed I've upgraded from 1.4.1 to current Master (16.03.2015). The modem is connected to GPRS, then the PPP session is started. The communication parameters are negotiated successfully (LCP). The authentication is OK: Login OK. Now lwIP sends a Configuration request (IPCP): Raw: ff 03 80 21 01 01 00 16 03 06 00 00 00 00 81 06 00 00 00 00 83 06 00 00 00 00 6e db 7e Interpreted (Wireshark): Protocol: Internet Protocol Control Protocol (0x8021) Options: (18 bytes), IP address, Primary DNS Server IP Address, Secondary DNS Server IP Address IP address: 0.0.0.0 Primary DNS Server IP Address: 0.0.0.0 Secondary DNS Server IP Address: 0.0.0.0 That's a perfect IPCP request ;-) After this frame the communication is dead, no answer received, no other frame sent. I've tried using various combinations of - No auth, PAP, Chap - With/without VJ header compression Questions: a) Has anybody a hint why it does not work? I think the provider should send a IPCP Configuration Request/Ack/Nack? Yes, your modem should. There is no PPP inside the GSM network, the PPP session is only between your device and your modem over its serial link. b) I do not receive a callback (see pppos_create()). After a long timeout I try to restart, but without success: The stack is in a deadlock, I can't close the session. ppp_close(m_pSelf-ppp, true) does not give a callback either. So the only solution is to reset the whole system. How do I reset a hanging PPP session if no communication happens? Looks like your lwIP timeouts are not working or you don't have enough of them, PPP needs a lot of timeouts, could you check that first ? Sylvain signature.asc Description: Digital signature ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] ppp over serial works with gsm modem sim900d but not working with sim5216j using same controller harware
Looking at your frames, the SIM900 outputs a PPP frame with HDLC address and control bytes, while the SIM5216 does not. I'm by no means a PPP expert, but just looking for PPP in wikipedia shows this: /The Address and Control fields always have the value hex FF (for all stations) and hex 03 (for unnumbered information), *and can be omitted whenever PPP LCP Address-and-Control-Field-Compression (ACFC) is negotiated*./ You should actually check if that is the case before calling SimCom tech support. Besides that, those two HDLC-like framed PPP frames containing an IPCP message are equivalent, you are being assigned an IP address and provided primary + secondary DNS addresses -- ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] ppp over serial works with gsm modem sim900d but not working with sim5216j using same controller harware
Hello, On Wed, Apr 01, 2015 at 03:18:02AM -0700, rohanm wrote: hii , i have implemented ppp over serial using gsm modem sim900d. and it works fine.device gets ip address properly. but when I replaced GSM modem with sim5216j ,ppp not able to established connection with sim5216j. i am using same code and hardware which used for sim900d implementation. so i have monitored gsm modem response for ppp frames,which i found not as per protocol. for ex. sim 900d response for ipcp frame: 7E FF 03 80 21 02 03 00 16 03 06 DF E8 B4 7F 81 06 3B 90 7F 75 83 06 CA 38 D7 29 1A 39 7E sim 5216j response for ipcp frame: 7E 80 21 02 0A 00 16 03 06 6A CF 56 68 81 06 3B 90 7F 75 83 06 CA 38 D7 29 DE 27 7E so as per my knowlege,address byte and control byte i.e. 2nd and 3rd byte of sim 900d response is missing in sim5126j response. I suppose this is wrong too, accomp (Address/Control compression) is only acceptable for IP/IPv6 packet AFAIK, but that's not a big deal. Anyway, it should works, because we don't care if accomp is enabled or disabled in PPPoS input path. (see pppos_input() around PDADDRESS and PDCONTROL). Could you enable PPP debug so we can check what is decoded by the PPP stack ? #define PPP_DEBUG LWIP_DBG_ON #define PRINTPKT_SUPPORT1 Sylvain And please stop using Nabble, dammit. signature.asc Description: Digital signature ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
[lwip-users] PPP no IP address assigned
Hi all I try to integrate PPP with a GPRS modem in our system. lwIP works well for ethernet in our system since 3 years. Since PPP is currently actively developed I've upgraded from 1.4.1 to current Master (16.03.2015). The modem is connected to GPRS, then the PPP session is started. The communication parameters are negotiated successfully (LCP). The authentication is OK: Login OK. Now lwIP sends a Configuration request (IPCP): Raw: ff 03 80 21 01 01 00 16 03 06 00 00 00 00 81 06 00 00 00 00 83 06 00 00 00 00 6e db 7e Interpreted (Wireshark): Protocol: Internet Protocol Control Protocol (0x8021) Options: (18 bytes), IP address, Primary DNS Server IP Address, Secondary DNS Server IP Address IP address: 0.0.0.0 Primary DNS Server IP Address: 0.0.0.0 Secondary DNS Server IP Address: 0.0.0.0 After this frame the communication is dead, no answer received, no other frame sent. I've tried using various combinations of - No auth, PAP, Chap - With/without VJ header compression Questions: a) Has anybody a hint why it does not work? I think the provider should send a IPCP Configuration Request/Ack/Nack? b) I do not receive a callback (see pppos_create()). After a long timeout I try to restart, but without success: The stack is in a deadlock, I can't close the session. ppp_close(m_pSelf-ppp, true) does not give a callback either. So the only solution is to reset the whole system. How do I reset a hanging PPP session if no communication happens? Best regards Michael ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] ppp over serial works with gsm modem sim900d but not working with sim5216j using same controller harware
thank you for ur quick response. pfa. LOG_2.log http://lwip.100.n7.nabble.com/file/n24269/LOG_2.log this is what i got in the log. sorry for messy log. -- View this message in context: http://lwip.100.n7.nabble.com/ppp-over-serial-works-with-gsm-modem-sim900d-but-not-working-with-sim5216j-using-same-controller-hare-tp24261p24269.html Sent from the lwip-users mailing list archive at Nabble.com. ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] PPP no IP address assigned
On 4/1/2015 2:47 AM, Michael Waeber wrote: Hi all I try to integrate PPP with a GPRS modem in our system. lwIP works well for ethernet in our system since 3 years. Since PPP is currently actively developed I've upgraded from 1.4.1 to current Master (16.03.2015). The modem is connected to GPRS, then the PPP session is started. The communication parameters are negotiated successfully (LCP). The authentication is OK: Login OK. Now lwIP sends a Configuration request (IPCP): Raw: ff 03 80 21 01 01 00 16 03 06 00 00 00 00 81 06 00 00 00 00 83 06 00 00 00 00 6e db 7e May I ask exactly what the LCP negotiations looked like? What options were negotiated? If nothing else, what was the ACCM set to? Patrick Klos Klos Technologies, Inc. ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] PPP no IP address assigned
Hello Sylvain On 01.04.2015 14:02, Sylvain Rochet wrote: snip .. That's a perfect IPCP request ;-) After this frame the communication is dead, no answer received, no other frame sent. I've tried using various combinations of - No auth, PAP, Chap - With/without VJ header compression Questions: a) Has anybody a hint why it does not work? I think the provider should send a IPCP Configuration Request/Ack/Nack? Yes, your modem should. There is no PPP inside the GSM network, the PPP session is only between your device and your modem over its serial link. OK, thanks for this information. I will check this issue with the modem documentation and/or manufacturer. b) I do not receive a callback (see pppos_create()). After a long timeout I try to restart, but without success: The stack is in a deadlock, I can't close the session. ppp_close(m_pSelf-ppp, true) does not give a callback either. So the only solution is to reset the whole system. How do I reset a hanging PPP session if no communication happens? Looks like your lwIP timeouts are not working or you don't have enough of them, PPP needs a lot of timeouts, could you check that first ? What do you exactly mean with timeouts? We have set NO_SYS=1, so there is no such thing as OS timeout. Is the PPP part not driven by the TCP main task tcp_tmr()? Do i have to call another function for PPP if NO_SYS=1? I've increased MEMP_NUM_SYS_TIMEOUT from 10 to 50, but receive no callback either. Regards Michael ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] PPP no IP address assigned
Hello Michael, On Wed, Apr 01, 2015 at 05:27:41PM +0200, Michael Waeber wrote: On 01.04.2015 14:02, Sylvain Rochet wrote: Looks like your lwIP timeouts are not working or you don't have enough of them, PPP needs a lot of timeouts, could you check that first ? What do you exactly mean with timeouts? We have set NO_SYS=1, so there is no such thing as OS timeout. Is the PPP part not driven by the TCP main task tcp_tmr()? Do i have to call another function for PPP if NO_SYS=1? You don't have to, tcp_tmr() should do the job. I've increased MEMP_NUM_SYS_TIMEOUT from 10 to 50, but receive no callback either. It really should retry a few seconds later, could you dig what is happening in IPCP (ipcp.c/fsm.c) ? What do you have for FSM_DEFTIMEOUT in lwipopts.h/opt.h ? Sylvain signature.asc Description: Digital signature ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users
Re: [lwip-users] PPP no IP address assigned
Hello Michael, On Wed, Apr 01, 2015 at 09:56:37PM +0200, Sylvain Rochet wrote: It really should retry a few seconds later, could you dig what is happening in IPCP (ipcp.c/fsm.c) ? What do you have for FSM_DEFTIMEOUT in lwipopts.h/opt.h ? To be sure I tested with an input drop filter which drop the 10 first IPCP replies, this is what I get: sent [IPCP ConfReq id=0x1 addr 0.0.0.0 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] 1427927750: drop IPCP input 1427927750: drop IPCP input 1427927753: drop IPCP input sent [IPCP ConfReq id=0x1 addr 0.0.0.0 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] 1427927756: drop IPCP input 1427927756: drop IPCP input 1427927756-1427927750 = FSM_DEFTIMEOUT - OK 1427927759: drop IPCP input sent [IPCP ConfReq id=0x1 addr 0.0.0.0 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] 1427927762: drop IPCP input 1427927762: drop IPCP input 1427927762-1427927756 = FSM_DEFTIMEOUT - OK 1427927765: drop IPCP input sent [IPCP ConfReq id=0x1 addr 0.0.0.0 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] 1427927768: drop IPCP input rcvd [IPCP ConfReq id=0x1 addr 192.168.4.254 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] sent [IPCP ConfRej id=0x1 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] rcvd [IPCP ConfReq id=0x2 addr 192.168.4.254] sent [IPCP ConfAck id=0x2 addr 192.168.4.254] rcvd [IPCP ConfReq id=0x2 addr 192.168.4.254] sent [IPCP ConfAck id=0x2 addr 192.168.4.254] rcvd [IPCP ConfReq id=0x2 addr 192.168.4.254] sent [IPCP ConfAck id=0x2 addr 192.168.4.254] sent [IPCP ConfReq id=0x1 addr 0.0.0.0 ms-dns1 0.0.0.0 ms-dns2 0.0.0.0] rcvd [IPCP ConfNak id=0x1 addr 192.168.4.100 ms-dns1 8.8.8.8 ms-dns2 8.8.4.4] sent [IPCP ConfReq id=0x2 addr 192.168.4.100 ms-dns1 8.8.8.8 ms-dns2 8.8.4.4] rcvd [IPCP ConfAck id=0x2 addr 192.168.4.100 ms-dns1 8.8.8.8 ms-dns2 8.8.4.4] Sylvain signature.asc Description: Digital signature ___ lwip-users mailing list lwip-users@nongnu.org https://lists.nongnu.org/mailman/listinfo/lwip-users