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

    I can not upload a sketch to my WiPy 3.0 using Arduino IDE.

    Scheduled Pinned Locked Moved WiPy 2&3
    18 Posts 2 Posters 1.0k 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.
    • A Offline
      armant
      last edited by armant

      Any help would be appreciated. I get ```

      A fatal error occurred: Failed to connect to ESP32: Invalid head of packet (0x08).
      robert-hhR 1 Reply Last reply Reply Quote 0
      • robert-hhR Offline
        robert-hh @armant
        last edited by

        @armant It looks like the WiPy is in firmware update mode. Please check the state of P2 (GPIO0). It must not be low for normal operation.

        A 1 Reply Last reply Reply Quote 1
        • A Offline
          armant @robert-hh
          last edited by

          @robert-hh Thank you for the response. GPIO0 is low, how can I set it to High or how can I get out of this current mode?

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

            @armant there must be something externally pulling it low. If not, pull it up with a resistor, e.g. 4.7 kOhm. The ESP has a weak pull-up for GPIO0, but that may not be sufficient, if something is connected to it.

            A 1 Reply Last reply Reply Quote 1
            • A Offline
              armant @robert-hh
              last edited by

              @robert-hh Thanks again. I have tired to pull it up with 6.8 kOhm resistor but still did not work. Is there any other way to get it out of update firmware mode?

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

                @armant No. At the time of Reset, GPIO0 must be high. I wonder why it is low at your device. Is anything connected to it?

                A 1 Reply Last reply Reply Quote 1
                • A Offline
                  armant @robert-hh
                  last edited by

                  @robert-hh I have just powered it up on a breadboard and connected a UART serial connection. Other than that nothing else is connected to it. As you have figured I am not using the standard expansion boards.

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

                    @armant In that case, GPIO0 (alias P2), the 4th pin from the reset switch, should be high. It may be that the WiPy has firmware loaded. In that case you should upload a firmware. You do not need a specific board for that and you can use the Pycom update tool. Only the device must be in upload mode (GPIO0 low at reset time), which you device seems to be.

                    A 1 Reply Last reply Reply Quote 1
                    • A Offline
                      armant @robert-hh
                      last edited by

                      @robert-hh said in I can not upload a sketch to my WiPy 3.0 using Arduino IDE.:

                      Pycom update too

                      Thank you I have updated the firmware. GPIO0 is at high now but I get the following error when trying to upload a sketch : ```

                      A fatal error occurred: Failed to connect to ESP32: Timed out waiting for packet header
                      robert-hhR 1 Reply Last reply Reply Quote 0
                      • robert-hhR Offline
                        robert-hh @armant
                        last edited by

                        @armant That is still a message from the boot loader. if you just connect a terminal emulator at 115200 baud and push reset, which messages do you see?

                        A 1 Reply Last reply Reply Quote 1
                        • A Offline
                          armant @robert-hh
                          last edited by

                          @robert-hh said in I can not upload a sketch to my WiPy 3.0 using Arduino IDE.:

                          terminal emulator

                          I can not make the connection anymore. I tried Atom and PuTTy but got no message and failed to connect. I used to get some messages when I pushed the reset.

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

                            @armant With Putty you have to set flow control to None.

                            A 1 Reply Last reply Reply Quote 1
                            • A Offline
                              armant @robert-hh
                              last edited by

                              @robert-hh Still could not make the connection
                              My baud is 115200, data bits 8 , stop bits 1, parity none and flow control none.

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

                                @armant That is strange. At least the boot loader should come up with messages like:

                                ets Jun  8 2016 00:22:57
                                
                                rst:0x1 (POWERON_RESET),boot:0x12 (SPI_FAST_FLASH_BOOT)
                                configsip: 0, SPIWP:0xee
                                clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
                                mode:DIO, clock div:1
                                load:0x3fff8028,len:8
                                load:0x3fff8030,len:2156
                                ho 0 tail 12 room 4
                                load:0x4009fa00,len:19208
                                entry 0x400a05f4
                                
                                A 2 Replies Last reply Reply Quote 1
                                • A Offline
                                  armant @robert-hh
                                  last edited by

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

                                    @robert-hh I managed to update the firmware again and get the serial working but again GPIO0 is not high this time and I can not program.

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

                                      @armant Can you pull GPIO0 high externally, push reset & look at the messages? And, b.t.w., how and at which Pin do you power the device?

                                      A 1 Reply Last reply Reply Quote 1
                                      • A Offline
                                        armant @robert-hh
                                        last edited by

                                        @robert-hh I pulled it High externally and now it works. Thank you very much! Really appreciate your help.

                                        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