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

    GPY full flash erase

    Scheduled Pinned Locked Moved GPy
    45 Posts 7 Posters 4.6k Views 7 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.
    • kodarnK Offline
      kodarn @kjm
      last edited by

      @kjm Ah, um, no, it was on a LoPy4 board.

      1 Reply Last reply Reply Quote 0
      • C Offline
        Clemens
        last edited by

        It was a nice feature before that a new (firmware flashed) device was accessible by WiFi this is gone with the 1.20.1 release and makes the setup for some scenarios more complicated. I fear this feature was switched off to be replaced by PyCom's own setup wizard via pybytes in the future.

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

          @kjm I tested this short script, and it sets up the AP. Note, that you can set ssid, password, and IP address as you like. The DNS settings are more or less useless.

          #
          # set device in AP mode
          #
          from network import WLAN
          wlan=WLAN(mode=WLAN.AP, ssid="my_wlan_1", auth=(WLAN.WPA2, "wlan_password"))
          wlan.ifconfig(id=1, config=("192.168.4.1", "255.255.255.0", "0.0.0.0", "0.0.0.0"))
          
          K 2 Replies Last reply Reply Quote 1
          • robert-hhR Offline
            robert-hh @Clemens
            last edited by

            @Clemens In my homebrew 1.20.0.r1 this feature is still present. It could be related to the fact, that the version 1.20.1 you can install via the pycom updater is a pybytes variant. For that, the automatic AP setup my be not useful, since that prevent access to the internet.

            C 1 Reply Last reply Reply Quote 1
            • robert-hhR Offline
              robert-hh @kjm
              last edited by

              @kjm I do not assume that GPY and the other board behave different with respect to WiFi.

              1 Reply Last reply Reply Quote 0
              • C Offline
                Clemens @robert-hh
                last edited by

                @robert-hh we at hiveeyes use and promote your firmware build as a good medicine in case the official version makes problems. So many thanks for this. It's a bit pity that you have to do the work pycom should jump in normally!

                K 1 Reply Last reply Reply Quote 0
                • K Offline
                  kjm @Clemens
                  last edited by

                  @Clemens I'm confused now. Are there two different 1.20.1.r1, the official pycom one & Rob's? We don't use pybytes so I'd be keen to try Rob's. Where can I get a copy & what do I use to load it if the pycom updater only does the pybytes variant?

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

                    @kjm You can always build the firmware from the sources. That's easiest done on a Linux system. A virtual machine or WSL of Windows 10 also works. The latest version of the Dev branch creates the tar bundles, which can installed using the Pycom updater. On Linux system, you can do that also w/o the pycom updater. Using the Pycom updater has the advantage, that ot resets the Lora and Sigfox MAC, if that was lost after a full flash erase.

                    Nevertheless, going that way is a big initial step, if you are not used to it. For Linux, any old system is sufficient, which many people may have around. Using Xubuntu or Mint xfce is an easy install process. Setting up the build environment is documented, but there are quite a few chances to omit things.

                    b.t.w: I could update my pre-built bundles.
                    b.t.w.2: I asked several times also to update the "official" non-pybytes variant. I think pycom refuses to do so, promoting pybytes as their entry into a service business.

                    C K 2 Replies Last reply Reply Quote 1
                    • C Offline
                      crumble @robert-hh
                      last edited by

                      @robert-hh said in GPY full flash erase:

                      I think pycom refuses to do so, promoting pybytes as their entry into a service business.

                      Pycom marked the "normal" firmware as legacy. So I do not think, that they will update this branch.

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

                        Hi there,

                        we might want to divert that to a different forum thread, but just for the sake of completeness we also started brewing our own firmware images and publish them to [1]. Please let us know if we can be helpful for the community in any way on this topic.

                        Cheers,
                        Andreas.

                        P.S.: Disclaimer: @Clemens and me are on the same team working on a datalogger software called Terkin for MicroPython [2]. We learned many things from @robert-hh and are taking different kinds of deep-dives into things we wouldn't better not have known about [3].

                        [1] https://packages.hiveeyes.org/hiveeyes/foss/pycom/
                        [2] https://community.hiveeyes.org/t/developing-terkin-for-micropython/233
                        [3] https://community.hiveeyes.org/t/random-memory-corruption-faults-on-esp32-wrover-rev-1-and-rev-2-when-running-in-dual-core-mode/2515

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

                          @kjm Looking at the source code I can see, that the WiFi settings for boot are now taken from a flash configuration data set. I did not dig further about how this data is set. The intention may be to set that in the pybytes configuration dashboard. Since my devices start that AP with software implementing that property, and these have been erased, It may be that the default is: start the AP.

                          1 Reply Last reply Reply Quote 0
                          • K Offline
                            kjm @robert-hh
                            last edited by

                            @robert-hh I'm still confused. Am I right in thinking there are two 1.20.1.r1 firmwares now? The pybytes version (which has no adhoc wifi) that the pycom updater will install and your version that I have to assemble on a linux machine before I can install it?

                            robert-hhR 1 Reply Last reply Reply Quote 0
                            • A Offline
                              andreas
                              last edited by

                              @kjm Anyone can build firmware images from the sources. Pycom is obviously featuring their offical firmware builds stronger with respect to features of their product platform while we are aiming to freeze our foundation modules into different builds in order to brew customized firmware images better fitting the requirements of our community.

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

                                @kjm As @andreas told, the firmware builds I make are not that special. They include only my favorite scripts as frozen bytecode, and I have tailored the build scripts to support my build environment. Sometimes I try special variants, like a version the supports Lora EU433, or an option to invert UART, .....,
                                It is not explained by PyCom, which of the various branches in the PyCom repository is the recent "official" one. By convention, it should be 'master'. But the actual development seems to happen at Dev (tagged as default), which seems to include the pybytes code. But there is also a branch called 'pybytes-master'.
                                Edit: This is the list of actual branches with their most recent update times:

                                Dev (default)           Oct 30, 2019
                                Release/v1.20           Oct 7, 2019
                                pybytes-master          Oct 5, 2019
                                OTA_1_20_Prep/master    Sep 15, 2019
                                fw_fixes                Sep 10, 2019
                                release-candidate       Aug 22, 2019
                                Release/v1.18           May 15, 2019
                                master                  May 14, 2019
                                bug_fixes               Apr 15, 2019
                                pypic_pid_fix           Mar 1, 2019
                                development             Nov 12, 2018
                                spi_bitorder            Nov 7, 2017
                                
                                K 1 Reply Last reply Reply Quote 1
                                • K Offline
                                  kjm @robert-hh
                                  last edited by

                                  @robert-hh I don't think I'm smart enough to roll my own firmware. When I run the latest Windows pycom firmware updater it starts by telling me the latest firmware is 1.16.1 but then later it says it downloaded & used 1.20.1.r1 I assume that's the Oct 5th pybytes-master in your list, with no adhoc wifi? How is this different from Oct7th Release/v1.20?

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

                                    This post is deleted!
                                    1 Reply Last reply Reply Quote 0
                                    • K Offline
                                      kjm @robert-hh
                                      last edited by

                                      @robert-hh said in GPY full flash erase:

                                      @kjm I tested this short script, and it sets up the AP. Note, that you can set ssid, password, and IP address as you like. The DNS settings are more or less useless.

                                      Is this a way to setup an adhoc wifi that I can turn on/off with import pycom, machine; pycom.wifi_on_boot(1); machine.reset() ?

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

                                        @kjm 1.16.1 is the version of the firmware updater itself. Whereas 1.20.1r1 is the latest revision of the firmware for the PyCom modules. Both the Dev and Release/ v1.20 have the revision number 1.20.1.r1, the differ in the pybytes revision. Dev shows pybytes 1.2.0, Release/v1.20 shows pybytes 1.1.3. The branch pybytes-master has the firmware revision 1.18.3. That's all in the file pycom_version.h in the repository.
                                        b.t.w.: I build my firmware w/o pybytes support.

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

                                          @kjm said in GPY full flash erase:

                                          Is this a way to setup an adhoc wifi that I can turn on/off with import pycom, machine; pycom.wifi_on_boot(1); machine.reset() ?

                                          No. This little script will turn on an AP, configured to your needs, if you put it into boot.py or main.py

                                          K 1 Reply Last reply Reply Quote 0
                                          • K Offline
                                            kjm @robert-hh
                                            last edited by

                                            No. This little script will turn on an AP, configured to your needs, if you put it into boot.py or main.py

                                            Do you know if there is flavour of LittleFS firmware that still has adhoc wifi? If so could I download it with the pycom updater with the 'legacy' option?

                                            robert-hhR 2 Replies 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
                                            • 3
                                            • 1 / 3
                                            • First post
                                              Last post

                                            Pycom on Twitter

                                            Pycom