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

    expansionV3 + lopy4, P2 during RST

    Scheduled Pinned Locked Moved Expansion Board
    5 Posts 2 Posters 170 Views 2 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.
    • F Offline
      frecfrec
      last edited by

      Hello,
      I have a expansion board V3.1 (with expansion31_0.0.11.dfu), with a Lopy4 plugged.
      We use visual code with PlatformIO, in C++ to develop and upload the firmware.

      I haave 2 questions:

      Actually, I have to connect P2 to GND to be able to upload.
      1 => Is there a way to update the LOPY4 firmware without any P2_to_GND manipulation ?
      2 => Is there a way to update the LOPY4 firmware without pushing RST physical button ?

      J 1 Reply Last reply Reply Quote 0
      • J Offline
        jcaron @frecfrec
        last edited by

        @frecfrec I'm not sure that works with the expansion board (I believe it does with the 3.x versions which have a similar PIC to the PySense/PyTrack), but AFAIR the CLI update tool (pycom-fwtool-cli) should be able to instruct the PIC on the board to take the required steps to switch to firmware update mode. If it doesn't by default, you can add the --pic option.

        1 Reply Last reply Reply Quote 1
        • F Offline
          frecfrec
          last edited by

          Thank you for you answer, using windows10, I tried to flash using pycom-fwtool-cli,

          .\pycom-fwtool-cli.exe -p COM9 -s 115200 --pic flash -f .\firmware.bin
          output => You must either specifiy the tar[.gz] file or both the file and partition to flash
          

          but requested input is a .tar.gz and not a .bin file.
          PlatformIO generate .bin files for firmware.bin and partitions.bin

          I'm afraid to break my lopy4, putting those 2 files into a tar.gz file and testing it.

          Is it the right way to do it ?

          J 1 Reply Last reply Reply Quote 0
          • J Offline
            jcaron @frecfrec
            last edited by

            @frecfrec You can probably use another mode that doesn't need a file (maybe reading the config block with cb?) and the --noexit to stay in firmware update mode, then use your usual flashing tool.

            Alternatively, you can use the copy command of the tool to write a .bin file (though I'm not quite sure what the partition parameter should be, it probably depends on what you .bin file actually contains -- you may want to backup existing partitions and compare with the firmware that you are supposed to already have on the device to find the right value).

            1 Reply Last reply Reply Quote 0
            • F Offline
              frecfrec
              last edited by

              @frecfrec said in expansionV3 + lopy4, P2 during RST:

              .\pycom-fwtool-cli.exe -p COM9 -s 115200 --pic flash -f .\firmware.bin

              finally done creating a tar.gz file containing:

              • firmware.bin (our firmware compiled with platformIO)
              • bootloader.bin (copied from a tar.gz sample)
              • partition.bin (copied from a tar.gz sample)

              sample used for bootload.bin and partition.bin:
              https://packages.hiveeyes.org/hiveeyes/foss/pycom/official/pybytes/LoPy4-1.20.2.rc3.tar.gz

              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