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

    How to solve the firmware update failures

    Scheduled Pinned Locked Moved Announcements & News
    63 Posts 15 Posters 47.1k Views 16 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.
    • L Offline
      livius
      last edited by

      i try type it but the same error
      in previous post you have copy from cmd.exe window - without any modification - maybe i miss something?

      think about people first, then computers

      1 Reply Last reply Reply Quote 0
      • X Offline
        Xykon administrators
        last edited by

        What happens when you run "esptool.py version" and "esptool.py --chip esp32". Can you please post exact output of both commands?

        Christian Ehlers

        1 Reply Last reply Reply Quote 0
        • L Offline
          livius
          last edited by

          I see that i have python 2.7.11
          with python 2.7.12 now all looks good :)

          Will be good to see in steeps that we need python 2.7.12

          esptool.py v2.0-dev
          Connecting...
          Uploading stub...
          Running stub...
          Stub running...
          Attaching SPI flash...
          Configuring flash size...
          Erasing flash...
          Unc size 615696 comp size 362758 comp blocks 355
          Wrote 362758 bytes at 0x00210000 in 32.6 seconds (89.1 kbit/s)...
          Hash of data verified.

          Leaving...

          think about people first, then computers

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

            Very nice to hear you got it working @livius

            If anyone still has problems with firmware update failures: 0.9.2.b1 has just been released. This release fixes the bug where the flash memory gets write protected in some cases.

            X 1 Reply Last reply Reply Quote 0
            • X Offline
              Xykon administrators @Ralph
              last edited by

              If anyone still has problems with firmware update failures: 0.9.2.b1 has just been released. This release fixes the bug where the flash memory gets write protected in some cases.

              I just tried the new firmware updater for Windows, it goes through the questions about LoPy/country/COM port but then fails immediately. Trying to figure out why.

              I manually flashed the firmware, partition table and bootloader so it's not a big problem but I'm curious why the updater doesn't work.

              Christian Ehlers

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

                @Xykon Hi, we are having the same problem, although after multiple attempts, it did get past that immediate fail, but, then had a fail with an unknown error in pythonW. Not sure what is going at the moment.

                1 Reply Last reply Reply Quote 0
                • L Offline
                  livius
                  last edited by

                  Maybe because it is still wipy_0.9.1.b1.bin not wipy_0.9.2.b1.bin
                  i look into the folder and there is 1 not 2.

                  think about people first, then computers

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

                    The correct 0.9.2.b1 is in the 'firmware' folder. I tried copying into the main 'upgrader' folder, but, the Upgrader still fails. Thought it might be the version of python (I was running 3.5) but, 2.7.12 fails also.

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

                      Thanks for pointing this out. It must be an issue with the windows build of the updater, since the mac version works. We'll try to figure it out and get back to you guys as soon as we can.

                      1 Reply Last reply Reply Quote 0
                      • L Offline
                        livius
                        last edited by

                        i do manual update by:
                        esptool.py --chip esp32 --port COM8 --baud 115200 write_flash 0x210000 wipy_0.9.2.b1.bin -fs 4MB -z
                        esptool.py --chip esp32 --port COM8 --baud 115200 write_flash 0x204000 partitions.bin -fs 4MB -z
                        esptool.py --chip esp32 --port COM8 --baud 115200 write_flash 0x201000 bootloader.bin -fs 4MB -z

                        i can connect by ftp and by telnet

                        by tenet i got:

                        import os
                        os.uname()
                        (sysname='WiPy', nodename='WiPy', release='0.9.2.b1', version='333b92c on 2016-10-26', machine='WiPy with ESP32')

                        but when i start wipy2.0 with board2.0
                        i can not connect by pymark - i do not know why it not "listen" on UART
                        but i can do above operations again - and as i understand corectly it is done by UART?

                        think about people first, then computers

                        X 1 Reply Last reply Reply Quote 0
                        • X Offline
                          Xykon administrators @livius
                          last edited by

                          @livius There are some extra steps in the updater to preserve your flash memory (MAC address, files on /flash). Since you skipped these steps it's likely your boot.py was overwritten.

                          Upload a new boot.py file with the following code:

                          import os
                          from machine import UART
                          uart = UART(0, 115200)
                          os.dupterm(uart)

                          P.S. Does anyone know where to find the formatting guide for this forum? I've seen people post source codes with a nice black background and syntax highlighting. How do you do that? Is there a help button somewhere for this?

                          Christian Ehlers

                          1 Reply Last reply Reply Quote 1
                          • X Offline
                            Xykon administrators
                            last edited by

                            import os
                            from machine import UART
                            uart = UART(0, 115200)
                            os.dupterm(uart)

                            Christian Ehlers

                            1 Reply Last reply Reply Quote 1
                            • L Offline
                              livius
                              last edited by

                              Thank you for the help but it does not change anything
                              still pymakr can not connect :(
                              I see that update script does erase only some block(3.5MB)
                              i ommit that and i clear block

                              If someone have mre concept :)

                              think about people first, then computers

                              1 Reply Last reply Reply Quote 0
                              • L Offline
                                livius
                                last edited by

                                interested that UART work ok
                                with com port monitor i retrive data without any problem only PYMAKR can not connect

                                think about people first, then computers

                                1 Reply Last reply Reply Quote 0
                                • X Offline
                                  Xykon administrators
                                  last edited by

                                  So far I did manage to get the Linux updater to work.

                                  In ./bin/updater I set BAUD_RATE = 115200 and commented #self.esp.change_baud(baudrate)

                                  I tried the same thing in the Windows version but it still doesn't work.

                                  Christian Ehlers

                                  1 Reply Last reply Reply Quote 0
                                  • X Offline
                                    Xykon administrators
                                    last edited by

                                    OK I got the Windows updater to work as well (though not the GUI).

                                    First make the same modifications to "C:\Program Files (x86)\Pycom\Pycom Firmware Update\Upgrader\bin\updater.py"

                                    Line12: BAUD_RATE = 115200
                                    Line23:#self.esp.change_baud(baudrate)

                                    Now open a command prompt and run:

                                    cd "C:\Program Files (x86)\Pycom\Pycom Firmware Update\Upgrader"
                                    ..\Python27\python.exe bin\updater.py --port COM4 --file firmware\lopy_0.9.2.b1_868.bin

                                    Make sure that you choose the correct COM port and firmware file for your module/region.

                                    Christian Ehlers

                                    D A 2 Replies Last reply Reply Quote 5
                                    • L Offline
                                      livius
                                      last edited by

                                      @LarryTru
                                      you are the best :)

                                      This work for me - but Pymark still can not connect to WiPy2.0 :(
                                      Before upgrade it work ok.
                                      I can only conect by: wifi, ftp, telnet
                                      boot.py looks ok
                                      I also can see data sended by UART programmatically on com port monitor but Pymark can not :(

                                      think about people first, then computers

                                      1 Reply Last reply Reply Quote 1
                                      • L Offline
                                        livius
                                        last edited by

                                        Xykon not LarryTru

                                        think about people first, then computers

                                        1 Reply Last reply Reply Quote 1
                                        • A Offline
                                          AgriKinetics
                                          last edited by

                                          @Xykon Thank you for the assistance - it worked like a dream :)

                                          1 Reply Last reply Reply Quote 1
                                          • X Offline
                                            Xykon administrators
                                            last edited by

                                            It turns out the problem with using 921600bps for firmware upload not working for me was my own test setup... if you use the official expansion board using just the command line on Windows without making changes to updater.py should work as well.

                                            If you happen to use RS232 for UART0 then reducing the firmware upload speed to 115200bps seems to be necessary.

                                            Christian Ehlers

                                            1 Reply Last reply Reply Quote 1

                                            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
                                            • 3
                                            • 4
                                            • 2 / 4
                                            • First post
                                              Last post

                                            Pycom on Twitter

                                            Pycom