This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Connection to 3G using PPP (RL-TCPNet)

Hello
I'm using STM32F407 with RL-TCPNet. My taks is connect 3G modem ( Telit, UL-865) to my device.
RL stack is working fine when PC connect to my device using PPP connection ( PC-Client, device-Server)

Now, i tried connect 3G modem to my device. After command to modem "ATD*99***1#" modem send back "CONNECT" and start LCP packages. The RL-TCPNet stack is not response and after 5-6 tries modem is send "NO CARRIER".
Before send command "ATD*99***1#" i'm setting the stack using next lines
ppp_listen ("Keil","");
SendToPPPStack ("CLIENT");
When i'm listening the UART communication i can see answer from stack "CLIENTSERVER".

I found that i need to establish PPP connection first before open TCP sockets. Could it be reason for the troubles with connections?
Have somebody an example to work with 3G modem using PPP connection?

Regards,
Sergiy

Parents
  • Hi,

    I'm not sure if this helps but I've just been doing something similar with my own Nordic NRF51 based board and the Middleware Network Component (Version 6.2) using a Telit GL865 modem.

    A local connection (Windows 7 client to NRF51 server) works fine using a null modem cable.

    The nrf51 board is now acting as a client. I have the modem configured in passive mode which I think is the default.

    I found I had to tweak the standard modem driver and insert some time delays between steps. The Telit AT command reference recommends a minimum of 20ms between each command and without these delays things were getting very confused.

    Using...

    netstat = ppp_connect("*99***1#", "", "");
    

    ...now works OK.

    Once the 'CONNECT' reply from the modem had been received the PPP negotiation is started by the NRF51 and the link comes up. I'm currently using the evaluation SIM card which came with my Telit EVK2 board and modem.

    I did find that although the Keil documentation says that Net_Config_PPP.h ignores local IP selection if automatic IP is enabled, this seems not to be the case. After the modem assigns an IP address (via IPCP) the client will attempt to negotiate use of the fixed address specified which causes the connection to be immediately terminated (NO CARRIER). Changing the local address to 0.0.0.0 appears to solve this.

    HTH
    Bob Holland

Reply
  • Hi,

    I'm not sure if this helps but I've just been doing something similar with my own Nordic NRF51 based board and the Middleware Network Component (Version 6.2) using a Telit GL865 modem.

    A local connection (Windows 7 client to NRF51 server) works fine using a null modem cable.

    The nrf51 board is now acting as a client. I have the modem configured in passive mode which I think is the default.

    I found I had to tweak the standard modem driver and insert some time delays between steps. The Telit AT command reference recommends a minimum of 20ms between each command and without these delays things were getting very confused.

    Using...

    netstat = ppp_connect("*99***1#", "", "");
    

    ...now works OK.

    Once the 'CONNECT' reply from the modem had been received the PPP negotiation is started by the NRF51 and the link comes up. I'm currently using the evaluation SIM card which came with my Telit EVK2 board and modem.

    I did find that although the Keil documentation says that Net_Config_PPP.h ignores local IP selection if automatic IP is enabled, this seems not to be the case. After the modem assigns an IP address (via IPCP) the client will attempt to negotiate use of the fixed address specified which causes the connection to be immediately terminated (NO CARRIER). Changing the local address to 0.0.0.0 appears to solve this.

    HTH
    Bob Holland

Children
No data