[Ovmsdev] Instability on GSM

Mark Webb-Johnson mark at webb-johnson.net
Sun Dec 17 11:09:14 HKT 2017


I’m working on this crash. It is deep within lwip. It seems that the open socket messes things up when the PPP connection goes down (but we’ve seen this with wifi as well, in the past).

Changing the PPPoS code to keep the interface active (even if the PPP link is down) didn’t seem to help.

I’m trying to add the necessary signals to indicate network going down (rather than network went down). We can then pick up on that and close the socket, before the actual network connection is shut down. I’ll get this done within the next couple of days.

Regards, Mark.

> On 17 Dec 2017, at 9:59 AM, Tom Parker <tom at carrott.org> wrote:
> 
> Hi,
> 
> I let my ovms run on GSM for a while and it's not very stable. I'm not sure if wifi is better or worse but here's a log starting from a reboot with the button, connecting, disconnecting and crashing. My esp-idf looks up to date:
> 
> commit 88ab5d4830e2eeb24fbae1d5f7d66a2e33bdbde0
> Author: Stephen Casner <casner at acm.org>
> Date:   Sun Oct 22 00:25:10 2017 -0700
> 
> Welcome to the Open Vehicle Monitoring System (OVMS) - Async Console
> I (605) simcom: State: Enter PoweringOn state
> I (605) simcom: Power Cycle
> D (1485) SIMCOM tx: 41 54 0d 0a                                     AT..
> D (1495) SIMCOM rx: 41 54 0d                                        AT.
> I (1495) simcom: State: Enter PoweredOn state
> D (1495) SIMCOM rx: 0d 0a 4f 4b 0d 0a                               ..OK..
> D (1505) SIMCOM line: 4f 4b                                           OK
> Launching OVMS Server V2 connection (oscv2)
> Logging level for * set to debug
> Power mode of simcom is now on
> OVMS > level info
> Logging level for * set to info
> I (11485) simcom: State timeout, transition to 2
> I (11485) simcom: State: Enter PoweringOn state
> I (11485) simcom: Power Cycle
> I (17475) simcom: State: Enter PoweredOn state
> I (36485) simcom: State: Enter MuxStart state
> I (36485) gsm-mux: Start MUX
> I (36495) gsm-mux: Channel #0 is open
> I (36505) gsm-mux: Channel #1 is open
> I (36505) gsm-mux: Channel #2 is open
> I (36515) gsm-mux: Channel #3 is open
> I (36515) gsm-mux: Channel #4 is open
> I (37485) simcom: State: Enter NetWait state
> I (47525) simcom: CREG Network Registration: RegisteredRoaming
> I (48485) simcom: State: Enter NetStart state
> I (49555) simcom: PPP Connection is ready to start
> I (50485) simcom: State: Enter NetMode state
> I (50485) gsm-ppp: Initialising...
> I (77405) gsm-ppp: StatusCallBack: None
> I (77405) gsm-ppp: status_cb: Connected
> I (77405) gsm-ppp:    our_ipaddr  = 10.170.199.15
> I (77405) gsm-ppp:    his_ipaddr  = 10.64.64.64
> I (77405) gsm-ppp:    netmask     = 255.255.255.255
> I (77405) gsm-ppp:    our6_ipaddr = ::
> I (80505) ovms-server-v2: Status: Network connectivity established
> I (80505) ovms-server-v2: Connection is redacted
> I (81905) ovms-server-v2: Connected to OVMS Server V2 at ovms.dexters-web.de
> I (81905) ovms-server-v2: Status: Connected to server
> I (81905) ovms-server-v2: Status: Logging in...
> I (81905) ovms-server-v2: Sending server login: MP-C 0 redacted
> I (101915) ovms-server-v2: Server response is incomplete (0 bytes)
> E (101915) ovms-server-v2: Status: Error: Server response is incomplete
> I (107445) simcom: CREG Network Registration: Searching
> I (107485) simcom: Lost network connection (NetworkRegistration in NetMode)
> I (107485) simcom: State: Enter NetLoss staGuru Meditation Error of type LoadProhibited occurred on core  0. Exception was unhandled.
> Register dump:
> PC      : 0x40180151  PS      : 0x00060830  A0      : 0x80180192 A1      : 0x3ffcf080
> 0x40180151: ip4_route at /home/ubuntu/esp/esp-idf/components/lwip/core/ipv4/ip4.c:250 (discriminator 2)
> 
> A2      : 0x0000f01d  A3      : 0x00000000  A4      : 0x3ffeae94 A5      : 0x3f429c7c
> A6      : 0x3ffd18c0  A7      : 0x00000000  A8      : 0x80180145 A9      : 0x3ffcf060
> A10     : 0x00000000  A11     : 0x00000000  A12     : 0x3ffdcd3c A13     : 0x3ffc09a0
> A14     : 0x00000003  A15     : 0x00060023  SAR     : 0x00000010 EXCCAUSE: 0x0000001c
> EXCVADDR: 0x0000f0d2  LBEG    : 0x4000c2e0  LEND    : 0x4000c2f6 LCOUNT  : 0xffffffff
> 
> Backtrace: 0x40180151:0x3ffcf080 0x4018018f:0x3ffcf0a0 0x4017e37e:0x3ffcf0c0 0x401789f3:0x3ffcf100 0x40178a15:0x3ffcf130 0x40178ab6:0x3ffcf150 0x40178f14:0x3ffcf170 0x4017c64e:0x3ffcf190 0x4017c68f:0x3ffcf1b0 0x401850b9:0x3ffcf1d0 0x4018547d:0x3ffcf1f0 0x401854c4:0x3ffcf210 0x401898d5:0x3ffcf230 0x401853b4:0x3ffcf250 0x4018cdaa:0x3ffcf270 0x4018cde6:0x3ffcf290 0x401884b9:0x3ffcf2b0 0x401898d5:0x3ffcf2d0 0x401893fc:0x3ffcf2f0 0x40184fa1:0x3ffcf310 0x401a2aac:0x3ffcf330 0x40173589:0x3ffcf350
> 0x40180151: ip4_route at /home/ubuntu/esp/esp-idf/components/lwip/core/ipv4/ip4.c:250 (discriminator 2)
> 
> 0x4018018f: ip4_route_src at /home/ubuntu/esp/esp-idf/components/lwip/core/ipv4/ip4.c:159
> 
> 0x4017e37e: tcp_rst at /home/ubuntu/esp/esp-idf/components/lwip/core/tcp_out.c:1336 (discriminator 4)
> 
> 0x401789f3: tcp_abandon at /home/ubuntu/esp/esp-idf/components/lwip/core/tcp.c:1630
> 
> 0x40178a15: tcp_abort at /home/ubuntu/esp/esp-idf/components/lwip/core/tcp.c:1630
> 
> 0x40178ab6: tcp_netif_ipv4_addr_changed_pcblist at /home/ubuntu/esp/esp-idf/components/lwip/core/tcp.c:1630
> 
> 0x40178f14: tcp_netif_ipv4_addr_changed at /home/ubuntu/esp/esp-idf/components/lwip/core/tcp.c:1947
> 
> 0x4017c64e: netif_set_ipaddr at /home/ubuntu/esp/esp-idf/components/lwip/core/netif.c:452
> 
> 0x4017c68f: netif_set_addr at /home/ubuntu/esp/esp-idf/components/lwip/core/netif.c:330
> 
> 0x401850b9: cifaddr at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/ppp.c:704
> 
> 0x4018547d: ipcp_clear_addrs at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/ipcp.c:2192
> 
> 0x401854c4: ipcp_down at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/ipcp.c:2156
> 
> 0x401898d5: fsm_lowerdown at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/fsm.c:146
> 
> 0x401853b4: ipcp_lowerdown at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/ipcp.c:687
> 
> 0x4018cdaa: upper_layers_down at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/auth.c:715
> 
> 0x4018cde6: link_down at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/auth.c:701
> 
> 0x401884b9: lcp_down at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/lcp.c:2341
> 
> 0x401898d5: fsm_lowerdown at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/fsm.c:146
> 
> 0x401893fc: lcp_lowerdown at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/lcp.c:485
> 
> 0x40184fa1: ppp_close at /home/ubuntu/esp/esp-idf/components/lwip/netif/ppp/ppp.c:704
> 
> 0x401a2aac: pppapi_do_ppp_close at /home/ubuntu/esp/esp-idf/components/lwip/api/pppapi.c:355
> 
> 0x40173589: tcpip_thread at /home/ubuntu/esp/esp-idf/components/lwip/api/tcpip.c:474
> 
> 
> Rebooting...
> ets Jun  8 2016 00:22:57
> 
> rst:0xc (SW_CPU_RESET),boot:0x1f (SPI_FAST_FLASH_BOOT)
> configsip: 156795334, SPIWP:0x00
> clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
> mode:DIO, clock div:2
> load:0x3fff0008,len:8
> load:0x3fff0010,len:4392
> load:0x40078000,len:11080
> load:0x40080000,len:252
> 0x40080000: _WindowOverflow4 at ??:?
> 
> entry 0x40080034
> 0x40080034: _WindowOverflow4 at ??:?
> 
> I (46) boot: ESP-IDF v2.1-20-g88ab5d4 2nd stage bootloader
> I (46) boot: compile time 11:13:21
> I (79) boot: Enabling RNG early entropy source...
> 
> _______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.teslaclub.hk
> http://lists.teslaclub.hk/mailman/listinfo/ovmsdev




More information about the OvmsDev mailing list