Welcome to the Pycom forum Forum
    • \[\[global:header.categories\]\]
    • \[\[global:header.recent\]\]
    • \[\[global:header.tags\]\]
    • \[\[global:header.popular\]\]
    • Login

    Explore Pybytes | Official Documentation | Report a Firmware Bug/Issue | GitHub

    Crash when connecting to my home Wifi router

    Scheduled Pinned Locked Moved LoPy
    26 Posts 6 Posters 11.3k Views 6 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • A Offline
      abilio @JF002
      last edited by

      @JF002, sorry ... don't know how the word access ended up there :P I was looking for model, but autocomplete/dictionary in cellphones always play games. I already see you have OpenWRT running (personal favorite). Thanks for trying with a static IP.

      Your tests, together with @macfreek report, will help us out finding the origin of the issue. I'll report back as soon as I have news.

      J 1 Reply Last reply Reply Quote 0
      • A Offline
        abilio @macfreek
        last edited by

        @macfreek, just to try ease the detective work, when you mean it happened after 0.9.6, does it mean it didn't happen to you in 0.9.5?

        M 1 Reply Last reply Reply Quote 0
        • J Offline
          JF002 @abilio
          last edited by

          @abilio said in Crash when connecting to my home Wifi router:

          @JF002, sorry ... don't know how the word access ended up there :P I was looking for model, but autocomplete/dictionary in cellphones always play games. I already see you have OpenWRT running (personal favorite). Thanks for trying with a static IP.

          Oh Ok :) It's a TP-Link TL-WDR3600 running OpenWrt 15.05, and only the 2.4Ghz radio is enabled. Multiple devices are connected to it : smartphone, laptop, PS3, RaspberryPi3, another dev board based on ESP8266,...

          Your tests, together with @macfreek report, will help us out finding the origin of the issue. I'll report back as soon as I have news.

          Just ask if you need other test :) I'll wait for your update!

          1 Reply Last reply Reply Quote 0
          • M Offline
            macfreek @abilio
            last edited by

            @abilio I have only tested 0.9.0 and 0.9.6. I'm happy to test other versions. Where can I download them? So far I only used the full installer but am happy to use OTA, TFTP or serial as soon as I find a howto.

            A 1 Reply Last reply Reply Quote 0
            • A Offline
              abilio @macfreek
              last edited by abilio

              @macfreek, old versions are still available in the server. https://software.pycom.io/downloads/pycom_firmware_update_0.9.5.b1.dmg will lead you to version 0.9.5.b1 for example. Take into account that for some versions we had to re-release the installer to fix issues, so some of them will be named a bit different. Here the list of those specific cases, for mac: pycom_update_0.9.6.b1a.dmg, pycom_update_0.9.3.b2a.dmg. 0.9.3 also got a b1, pycom_update_0.9.3.b1.dmg.

              Thats for the mac (taking into account your nickname ;) ) in case you want Windows, they are called a bit different (ie: pycom_firmware_update_0.9.5.b1.exe). Linux version is called the same as mac, but the extension is .tar.gz instead of .dmg .

              For other users that might look at this post, please don't downgrade your board unless you want to test something very specific, like in this case.

              Thanks for offering you help in the investigation,

              Abilio

              M 1 Reply Last reply Reply Quote 0
              • M Offline
                macfreek @abilio
                last edited by macfreek

                @abilio That URL only shows the text "Unauthorized" for me (though the HTTP code is just 200 instead of 401). As for your PM, I'm afraid my availability today is rather limited. I hope to test it today, but it may be tomorrow. And good guess about the OS preference (despite that I have the nickname for over 20 years).

                Edit: there was a typo in the URL you posted. The correct URL is: https://software.pycom.io/downloads/pycom_update_0.9.5.b1.dmg. I'm going to download it, and test if the problem occurs in that version as well.

                1 Reply Last reply Reply Quote 0
                • R Offline
                  rdixey
                  last edited by

                  Hello Abilio,

                  This WIFI bug continues the same with firmware 0.9.7.b1 as I reported a week ago for firmware 0.9.6.b1.

                  Am I assuming correctly that you are a Pycom engineer?

                  Who at Pycom is responsible for correcting firmware bugs?

                  What is Pycom's SLA for correcting defects with released firmware?

                  Robert Dixey

                  1 Reply Last reply Reply Quote 0
                  • W Offline
                    williamv
                    last edited by

                    hi, same issue here with my new LoPy with 0.9.6.b1a firmware, Netgear R7000 router. Wifi crashes after 1-2-3 minutes. Fixed ip does not make a difference.
                    Let me know if you need more info or if i can do any testing to get this resolved.

                    MicroPython v1.8.6-40-gd10463e on 2016-11-25; LoPy with ESP32
                    Type "help()" for more information.

                    I (434227) wifi: n:3 0, o:6 0, ap:255 255, sta:3 0, prof:6
                    I (435201) wifi: state: 0 -> 2 (b0)
                    I (435204) wifi: state: 2 -> 3 (0)
                    I (435208) wifi: state: 3 -> 5 (10)
                    I (435231) wifi: connected with xyzssid, channel 3
                    Guru Meditation Error of type InstrFetchProhibited occurred on core 0. Exception was unhandled.
                    Register dump:
                    PC : 002c002c PS : 00060330 A0 : 801252ce A1 : 3ffdf9f0
                    A2 : 00000001 A3 : 3ffd96ac A4 : 002c002c A5 : 00000008
                    A6 : 00000000 A7 : 3ffd3398 A8 : 8011ef50 A9 : 00000002
                    A10 : 3ffd96ac A11 : 00000001 A12 : 3ffd4f14 A13 : 00000000
                    A14 : 3ffdf2fc A15 : 3ffd4cf8 SAR : 00000019 EXCCAUSE: 00000014
                    EXCVADDR: 002c002c LBEG : 00000000 LEND : 00000000 LCOUNT : 00000000
                    Rebooting...
                    ets Jun 8 2016 00:22:57

                    rst:0x3 (SW_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
                    configsip: 0, SPIWP:0x00
                    clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
                    mode:QIO, clock div:2
                    load:0x3fff9010,len:8
                    load:0x3fff9018,len:812
                    ho 0 tail 12 room 4
                    load:0x40078000,len:3692
                    load:0x4009f000,len:944
                    entry 0x4009f1f0
                    rtc v134 Oct 20 2016 12:36:18˜øXTAL 40M
                    I (879) phy: phy_version: 246, Nov 18 2016, 17:30:07, 0, 0

                    tcpip_task_hdlxxx : 3ffdfba4, prio:18,stack:2048
                    frc2_timer_task_hdl:3ffe972c, prio:22, stack:2048
                    I (1576) wifi: pp_task_hdl : 3ffebf50, prio:23, stack:8192
                    mode : softAP(24:0a:c4:00:92:77)
                    dhcp server start:(ip: 192.168.4.1, mask: 255.255.255.0, gw: 192.168.4.1)
                    MicroPython v1.8.6-40-gd10463e on 2016-11-25; LoPy with ESP32
                    Type "help()" for more information.

                    1 Reply Last reply Reply Quote 0
                    • M Offline
                      macfreek
                      last edited by macfreek

                      FYI, the crash does not occur with firmware 0.9.5.b1, only with 0.9.6.b1 and 0.9.7.b1.

                      Just a little help in tracking it down, the following DHCP request packet will NOT crash the micropython board (generated with the dhcping tool):

                      22:45:15.298227 IP 172.25.129.170.68 > 255.255.255.255.67: BOOTP/DHCP, Request from f4:5c:89:8d:0b:dd, length 250

                      while the following DHCP request DOES crash the micropython board (generated by renewing the IPv4 lease):

                      22:43:13.382647 IP 0.0.0.0.68 > 255.255.255.255.67: BOOTP/DHCP, Request from f4:5c:89:8d:0b:dd, length 300

                      The obvious difference is in the sender IP address, but given the difference in length, there may be more differences.

                      Edit: the above packet turned out not to be the cause, but it seems that the likely cause is the SLAAC packet (an ICMPv6 router sollicitation packet), that is often send at the same time as a DHCPv4 request.

                      Good luck hunting down this bug, and let us know if we can be of any assistence.

                      1 Reply Last reply Reply Quote 0
                      • A Offline
                        abilio
                        last edited by

                        Yes, I'm an engineer at Pycom, and our team of firmware engineers (lead by Daniel) take turns into fixing bugs. We prioritize them by severity (this one is a severe one).

                        Sadly, in this case, we've checked and believe is something related with changes in Espressif's IDF in between 0.9.5 and 0.9.6. We're filling a bug report with them. As soon as we get a response, it will be included in that week's release.

                        Thanks everyone for your patience :)

                        J 1 Reply Last reply Reply Quote 0
                        • J Offline
                          JF002 @abilio
                          last edited by

                          @abilio I hope it will be fixed soon :) Keep us up to date!

                          1 Reply Last reply Reply Quote 0
                          • A Offline
                            abilio
                            last edited by

                            It seems that this bug was reported in parallel by another ESP32 user. The suspected cause is an issue with IPV6. If you want to keep track of the issue, see here:

                            https://github.com/espressif/esp-idf/issues/133

                            J 1 Reply Last reply Reply Quote 0
                            • M Offline
                              macfreek
                              last edited by

                              Thanks. From that thread it seems that the culprit was IPv6 router solliciation (as needed for SLAAC, which is often used in conjunction with DHCPv4). It seems I was looking at the correct event, but the wrong packet. My apologies for that. I have not yet reproduced it, but this seems very likely. I will follow the other thread for the upstream bug. Could you report back here once upstream is fixed and a new firmware for the pycom boards is available?

                              A 1 Reply Last reply Reply Quote 0
                              • A Offline
                                abilio @macfreek
                                last edited by

                                @macfreek, We'll report any progress here. Expect it to be included in the release after a solution is found :)

                                1 Reply Last reply Reply Quote 0
                                • W Offline
                                  williamv
                                  last edited by

                                  good find @abilio !! i changed ipv6 settings on my wireless router Netgear R7000 from 6to4-tunnel to Disabled and have not seen the crash again for the last 30 min ;-)

                                  1 Reply Last reply Reply Quote 0
                                  • J Offline
                                    JF002 @abilio
                                    last edited by

                                    @abilio I disabled the IPV6 interface on my router, and indeed, my Lopy does not crash any more.

                                    I'll leave the IPV6 interface disabled for now, but this is a workaround until it is fixed in the firmware :)

                                    1 Reply Last reply Reply Quote 0
                                    • P Offline
                                      PCA
                                      last edited by

                                      @abilio @JF002 same result for me. No more crashes if the wifi router IPV6 interface is disabled...

                                      A 1 Reply Last reply Reply Quote 0
                                      • A Offline
                                        abilio @PCA
                                        last edited by

                                        @williamv, @PCA, @JF002, thank you all for your reports :)

                                        1 Reply Last reply Reply Quote 0
                                        • M Offline
                                          macfreek
                                          last edited by

                                          Now that the bug has been found and fixed upstream, and merged into master, would you dare to take a stab at guessing a reasonable ETA before the upstream is released, and Pycom release a new firmware version? Is that a matter of days, around Christmas, next year, ...?

                                          1 Reply Last reply Reply Quote 0
                                          • R Offline
                                            rdixey
                                            last edited by

                                            I just loaded New firmware release 1.0.0.b1 on my LoPy and tested my WiFi connection and it worked without crashing. I see that this release included an Update to the latest IDF from Espressif, so I assume this addressed the problem. I glad this is fixed since I had no way to turn off IPv6 on my cable modem.

                                            Thanks Pycom

                                            J 1 Reply Last reply Reply Quote 0

                                            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                                            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                                            With your input, this post could be even better 💗

                                            Register Login
                                            • 1
                                            • 2
                                            • 2 / 2
                                            • First post
                                              Last post

                                            Pycom on Twitter

                                            Pycom