I am using the ESP32 in a custom board with an LTE module (SIMCom SIM7600A) and a Zigbee module (Silicon Labs EFR32MG1 Zigbee SoC), communicating with both of them through UART.
If I only use the LTE module, I am able to successfully connect to the Internet and perform HTTP/MQTT calls, using a modified version of the official example.
If I only use the Zigbee module, with ESP32 built-in WiFi (instead of LTE), it also works correctly (I can create the Zigbee network, different devices can join the network, and the WiFi connection always remains stable).
However, using the LTE module and doing Zigbee transmissions at the same time, breaks the LTE connections. The steps would be the following:
- Enable LTE connection (sending the corresponding AT commands to the SIM7600 module) and wait for the connection to be established. Successful HTTP/MQTT calls are seen on the logs.
- Create the Zigbee network and allow devices to join (sending the corresponding serial commands to the Zigbee module.
- Make a new device join the network. After repeating this a few times, the HTTP/MQTT calls start to fail.
A fragment of the relevant output can be seen here (the first line is the last successful HTTP connection):
Code: Select all
HTTP GET Status = 200, content_length = 271
I (00:03:39.185) http: HTTP_EVENT_DISCONNECTED
pppos_netif_output[1]: proto=0x21, len = 40
pppos_input[1]: got 17 bytes
LCP terminated by peer
ppp phase changed[1]: phase=9
D (00:03:39.301) esp-netif_lwip-ppp: Phase Network
sifvjcomp[1]: VJ compress enable=0 slot=0 max slot=0
sifdown[1]: err_code=0
ccp_set[1]: is_open=0, is_up=0, receive_method=0, transmit_method=0
ppp phase changed[1]: phase=6
D (00:03:39.317) esp-netif_lwip-ppp: Phase Establish
pppos_send_config[1]: out_accm=FF FF FF FF
ppp_send_config[1]
pppos_recv_config[1]: in_accm=0 0 0 0
ppp_recv_config[1]
pppos_write[1]: len=8
pppos_input[1]: got 14 bytes
pppos_input[1]: got 16 bytes
I (00:03:41.199) user: Request times 55
D (00:03:41.201) HTTP_CLIENT: Begin connect to: http://httpbin.org:80
D (00:03:41.204) TRANS_TCP: [sock=54],connecting to server IP:52.201.75.114,Port:80...
E (00:03:41.217) HTTP_CLIENT: Connection failed, sock < 0
E (00:03:41.218) http: HTTP GET request failed: ESP_ERR_HTTP_CONNECT
I (00:03:41.230) http: HTTP_EVENT_DISCONNECTED
I (00:03:43.229) user: Request times 56
D (00:03:43.231) HTTP_CLIENT: Begin connect to: http://httpbin.org:80
D (00:03:43.233) TRANS_TCP: [sock=54],connecting to server IP:52.201.75.114,Port:80...
E (00:03:43.246) HTTP_CLIENT: Connection failed, sock < 0
E (00:03:43.248) http: HTTP GET request failed: ESP_ERR_HTTP_CONNECT
I (00:03:43.259) http: HTTP_EVENT_DISCONNECTED
I (00:03:45.259) user: Request times 57
D (00:03:45.261) HTTP_CLIENT: Begin connect to: http://httpbin.org:80
D (00:03:45.263) TRANS_TCP: [sock=54],connecting to server IP:52.201.75.114,Port:80...
E (00:03:45.276) HTTP_CLIENT: Connection failed, sock < 0
E (00:03:45.277) http: HTTP GET request failed: ESP_ERR_HTTP_CONNECT
I (00:03:45.289) http: HTTP_EVENT_DISCONNECTED
ppp phase changed[1]: phase=12
D (00:03:45.339) esp-netif_lwip-ppp: Phase Disconnect
Connection terminated.
ppp_link_terminated[1]
ppp_link_end[1]
ppp phase changed[1]: phase=0
D (00:03:45.352) esp-netif_lwip-ppp: Phase Dead
I (00:03:45.353) esp-netif_lwip-ppp: Connection lost
ppp_link_terminated[1]: finished.
D (00:03:45.355) event: running post IP_EVENT:6 with handler 0x400d5244 on loop 0x3ffb5108
0x400d5244: on_ip_event at /home/mbrignone/stack_care/code/esp41/lte_poc_vesta/main/lte_ppp.c:70
D (00:03:45.367) LTE_PPP: IP event! 6
I (00:03:45.378) LTE_PPP: Modem Disconnect from PPP Server
- It doesn't seem to be a UART conflict issue. Constantly sending commands back and forth between the ESP32 and the Zigbee module that doesn’t trigger an actual Zigbee transmission (i.e. request module version or network parameters), doesn’t break the LTE connection. But a new device joining the network does break the connection.
- Running LTE and Zigbee on different cores didn’t solve the issue.
- Creating the Zigbee network and allowing to join devices before enabling LTE didn’t solve the issue.
- The latest ESP-IDF versions (v4.2 and v4.3) have many changes related to PPP. I am using all those latest versions and the issue is still present.
Any ideas or hints related to what could be happening are very welcomed.
Thanks!