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

    Failed to write compressed data to flash

    Scheduled Pinned Locked Moved Support & Troubleshooting
    9 Posts 4 Posters 81 Views 4 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.
    • Don-iotD Offline
      Don-iot
      last edited by Don-iot

      Just bought a batch of 25 GPys and after two successful ones, I fail to write the latest firmware to the three next devices, they complain about "Failed to write compressed data to flash" result was C100 in the firmware update tool. Anyone knows what it is and the cure? I use TTL to USB adapter, with the standard expansion board all I get is RX data error…

      When I connect these to VScode I get the error E (31) esp_image: image at 0x10000 has invalid magic byte.

      1 Reply Last reply Reply Quote 0
      • G Offline
        Gijs
        last edited by

        Hi,
        The error code C100 relates to a Bad checksum after writing a block. This will make the Firmware Updater tool throw an error. Reflashing should usually solve the problem. A solution to this issue could be to check the power supply & wiring to your GPy. As voltage fluctuations could influence the bits being written.
        Best,
        Gijs

        1 Reply Last reply Reply Quote 0
        • Don-iotD Offline
          Don-iot
          last edited by

          Thanks @Gijs that may clarify the problem, I will try again perhaps with a USB hub with a powersupply in between to even out things. But generally speaking, the expansion board should be sufficient when powered from my Macs USB-C ports, right? I tried two ports, two different methods/hardware boards and got successful attempts in between each upload with two devices, but five device failed repeatedly. Would CLI upload be better than the software tool?

          J 1 Reply Last reply Reply Quote 0
          • J Offline
            jcaron @Don-iot
            last edited by

            @Don-iot I believe the CLI upload tool lets you pick the speed, don't remember if the GUI version does. In some situations reducing the speed may help.

            Don-iotD 1 Reply Last reply Reply Quote 1
            • Don-iotD Offline
              Don-iot @jcaron
              last edited by

              @jcaron @Gijs So the fix was to use the Pycom Firmware tool, use my TTL adapter and use an extra 5V connected to the device. All fed via my USB hub. So that solved the communication issue. Now I just need to figure out how to get passed this warning. My only fix seems to be to reboot the computer. And that is ok, but updating 20 devices gets even more time consuming when I have to reboot after every 2-3 devices. Any idea what this warning is all about? failed.png

              robert-hhR 1 Reply Last reply Reply Quote 0
              • robert-hhR Offline
                robert-hh @Don-iot
                last edited by

                @Don-iot Maybe you should set up a small linux system with a dedicated USB port, good cables etc. for that task. I did hundreds of firmware flashes with a Linux box and had no problems beside some CH340 based USB/UART modules which cannot cope with 921600 baud. Running at 460800 solved that.
                P.S.: Almost all the time I flash out of the development environment. But that is using the tools of the CLI updater. So for the firmware upgrade itself there is no difference.

                Don-iotD 1 Reply Last reply Reply Quote 1
                • Don-iotD Offline
                  Don-iot @robert-hh
                  last edited by

                  @robert-hh Thanks Robert, good idea thanks for sharing. In this case I had a couple of devices that needed to be erased and not just updated and I am not confident enough to perform that with CLI. But for a regular software update I agree, then CLI and TTL adapter is the way to go.

                  robert-hhR 1 Reply Last reply Reply Quote 0
                  • robert-hhR Offline
                    robert-hh @Don-iot
                    last edited by

                    @Don-iot I would see it the other way. Using CLI and esptool.py is the only reliable way for a full erase of the device.

                    Don-iotD 1 Reply Last reply Reply Quote 0
                    • Don-iotD Offline
                      Don-iot @robert-hh
                      last edited by

                      @robert-hh Probably so but for my use I am currently quite ok with my homebrew and Pycoms firmware update tool, but when i level-up I will have a look at your suggestions. Thanks for support!

                      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 / 1
                      • First post
                        Last post

                      Pycom on Twitter

                      Pycom