Strange delay in esp_modem, when not using debug output

jesper
Posts: 25
Joined: Thu Nov 09, 2017 4:38 pm

Strange delay in esp_modem, when not using debug output

Postby jesper » Wed Mar 01, 2023 5:59 am

I have successfully created a project with the espressif_esp_modem component.
I tried the ppos_client example on a ESP32 against a Quectel BG600 modem, using the BG96 DCE.

After having sent/received the MQTT data, the modem is switched into command mode before destroying DCE and NETIF.
There is an annoying 6 - 12 second delay, from the switch to command mode and the netif interrupt, as can be seen in the log dump here:

Code: Select all

I (15933) MAIN: Switching to COMMAND mode
I (27933) esp-netif_lwip-ppp: User interrupt
I was trying to hunt down the reason for this, and enabled debug output in sdkconfig.
But then, the delay disappeared, as can be seen below:

Code: Select all

I (16947) MAIN: Switching to COMMAND mode
D (16947) esp_netif_handlers: esp_netif action stopped with netif0x3ffb6dc8 from event_id=0
D (16947) esp-netif_lwip-ppp: esp_netif_stop_ppp: Stopped PPP connection: 0x3ffb7028
D (16957) esp-netif_lwip-ppp: Phase Terminate
D (16967) esp-netif_lwip-ppp: Phase Network
D (16967) esp_netif_lwip: esp_netif_internal_dhcpc_cb lwip-netif:0x3ffb6e4c
D (16977) esp_netif_lwip: esp_netif_start_ip_lost_timer esp_netif:0x3ffb6dc8
D (16977) esp_netif_lwip: if0x3ffb6dc8 start ip lost tmr: interval=120
D (16987) esp-netif_lwip-ppp: Phase Establish
D (16997) esp_netif_lwip: check: remote, if=0x3ffb6dc8 fn=0x400eb89c
0x400eb89c: esp_netif_update_default_netif_lwip at /Users/jesper/esp/esp-idf/components/esp_netif/lwip/esp_netif_lwip.c:270

D (16997) esp-netif_lwip-ppp: Phase Disconnect
D (17007) esp-netif_lwip-ppp: Phase Dead
I (17007) esp-netif_lwip-ppp: User interrupt
Very peculiar.
Looks like a bug to me.

Can anyone explain this?
Or perhaps confirm this on a similar setup?

/J
MagicMicros Co., Ltd. - Rayong, Thailand
Electronics design, PCB layout & programming.

Who is online

Users browsing this forum: Google [Bot] and 75 guests