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

    WIPY on ESP32-WROOM Procedure

    Scheduled Pinned Locked Moved Firmware
    11 Posts 3 Posters 3.9k 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.
    • C Offline
      crankshaft
      last edited by crankshaft

      Re: [SOLVED] WiPy firmware to a standard WROOM-32?

      OK, I have succeeded with this, here's how to do it:

      1. Setup Build Environment, I created a bash script (OSX/LINUX) to do this, you should run it line by line and be sure to add the paths to XTENSA and the IDF:

        https://github.com/pacmac/micropython-share/blob/master/wipy-wroom/wipy-wroom.sh

      2. Modify pycom-micropython-sigfox/esp32/boards/WIPY/pins.csv and remove any pins (GPIO) that are not on your device.

        Renumber the Pins so that there are no gaps, the default WIPY is 24 pins (P0 to P23) however the esp32 wroom dev board I have does not have pins 37 & 38, so they have to be removed, it is renumbered P0 to P25 (26 pins) as this board has more I/O than the WIPY2 board.

        First Column is the expansion board G# number, second is the GPIO# and the third is the P# Number. I have set the first column to be the same as the GPIO# so that I can call a pin using a the GPIO number i.e. Pin('0') instead of Pin('P2') as the P# is only applicable to the layout of the WIPY board.

        Here's the board this is based on, but there are many clones of this that are pretty much the same:

        http://www.electrodragon.com/product/esp32-devkitc/

        And here's the modified pins file:
        https://github.com/pacmac/micropython-share/blob/master/wipy-wroom/pins.csv

      3. Make (build) the Binaries:
        make BOARD=WIPY -j5 TARGET=boot
        make BOARD=WIPY -j5 TARGET=app

      4. Erase & flash the device using your USB Port & dio flash mode:
        make BOARD=WIPY -j5 erase ESPPORT=/dev/tty.SLAB_USBtoUART
        make BOARD=WIPY -j5 flash ESPPORT=/dev/tty.SLAB_USBtoUART ESPFLASHMODE=dio

      And that should be it, took a few hours to figure it out, thanks so much to everyone in the original post who contributed.

      It is also possible to create a combined firmware.bin file that you can use to upload to the device using pytool.py instead of using the development environment.

      1 Reply Last reply Reply Quote 3
      • B Offline
        bucknall
        last edited by

        Thanks for writing this up! Hopefully, it'll be useful to the community!

        Thanks! :)

        Developer Evangelist - Pycom

        1 Reply Last reply Reply Quote 0
        • J Offline
          jack Pybytes Beta
          last edited by

          I wonder how it should be configured?--pins.csv
          What does each column mean?

          C 1 Reply Last reply Reply Quote 0
          • J Offline
            jack Pybytes Beta
            last edited by

            When i excute “make BOARD=WIPY -j4 TARGET=boot”
            export error "make: *** No rule to make target 'GNUmakefile'。"

            C 1 Reply Last reply Reply Quote 0
            • C Offline
              crankshaft @jack
              last edited by

              @jack - I think that the first columns is an alias, can be anything you want, I just renamed mine to be the same as the gpio id, the second column is the gpio and the 3rd is the wipy P number.

              J 1 Reply Last reply Reply Quote 0
              • C Offline
                crankshaft @jack
                last edited by

                @jack - Check that you have setup the SYSTEM PATHS to xtensa and pycom-esp-idf correctly.

                1 Reply Last reply Reply Quote 0
                • J Offline
                  jack Pybytes Beta @crankshaft
                  last edited by

                  @crankshaft
                  Can you help me?
                  When I modify the pins.csv file, the compiler error:

                  mods/pybadc.c:68:85: error: 'PIN_MODULE_P20' undeclared here (not in a function)
                  {.pin = &PIN_MODULE_P20, .channel = ADC1_CHANNEL_5, .enabled = false},
                  ^
                  CC mods/pybdac.c
                  ../py/mkrules.mk:47: recipe for target 'build/WIPY/release/mods/pybadc.o' failed
                  make: *** [build/WIPY/release/mods/pybadc.o] Error 1

                  J 1 Reply Last reply Reply Quote 0
                  • J Offline
                    jack Pybytes Beta @jack
                    last edited by

                    @jack
                    This is the content of the pins.csv file:
                    0_1497542366375_upload-b95ebc08-2e28-4f74-be3e-3410cdc9e9ea G36 GPIO36 P36
                    G39 GPIO39 P39
                    G34 GPIO34 P34
                    G35 GPIO35 P35
                    G32 GPIO32 P32
                    G33 GPIO33 P33
                    G25 GPIO25 P25
                    G26 GPIO26 P26
                    G27 GPIO27 P27
                    G14 GPIO14 P14
                    G12 GPIO12 P12
                    G13 GPIO13 P13
                    G9 GPIO9 P9
                    G10 GPIO10 P10
                    G11 GPIO11 P11
                    G6 GPIO6 P6
                    G7 GPIO7 P7
                    G8 GPIO8 P8
                    G15 GPIO15 P15
                    G2 GPIO2 P2
                    G0 GPIO0 P0
                    G4 GPIO4 P4
                    G16 GPIO16 P16
                    G17 GPIO17 P17
                    G5 GPIO5 P5
                    G18 GPIO18 P18
                    G19 GPIO19 P19
                    G21 GPIO21 P21
                    G3 GPIO3 P3
                    G1 GPIO1 P1
                    G22 GPIO22 P22
                    G23 GPIO23 P23

                    C 1 Reply Last reply Reply Quote 0
                    • C Offline
                      crankshaft @jack
                      last edited by

                      @jack - look at my note # 3:

                      "Renumber the Pins so that there are no gaps,"

                      The error message you received tells you the problem: "PIN_MODULE_P20' undeclared here"

                      You have not declared P20, you must renumber the pins, see my example pins.csv

                      J 2 Replies Last reply Reply Quote 0
                      • J Offline
                        jack Pybytes Beta @crankshaft
                        last edited by

                        @crankshaft
                        In fact, I don't have p20.
                        In addition, I found that the pins.c files generated by the compilation process are not consistent with the pins.csv I defined.
                        {
                        Create build/WIPY/release/pins.c
                        CC build/WIPY/release/pins.c
                        }
                        Please check your files.

                        1 Reply Last reply Reply Quote 0
                        • J Offline
                          jack Pybytes Beta @crankshaft
                          last edited by

                          @crankshaft
                          0_1497577114115_QQ图片20170616093413.png

                          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