Huzzah ESP8266 Upload Problems

For Adafruit customers who seek help with microcontrollers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Huzzah ESP8266 Upload Problems

Post by adafruit_support_rick »

I'll look into it!

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Huzzah ESP8266 Upload Problems

Post by adafruit_support_rick »

OK!

User avatar
andrsd
 
Posts: 6
Joined: Thu Apr 14, 2016 9:55 pm

Re: Huzzah ESP8266 Upload Problems

Post by andrsd »

I am having similar problems like @light_dayforger. Huzzah connected via FTDI on Mac OS X 10.11.3 (or linux). I actually managed to upload the sketch several times, but it is now failing with:

Code: Select all

esptool v0.4.8 - (c) 2014 Ch. Klippel <[email protected]>
	setting board to nodemcu
	setting baudrate from 115200 to 115200
	setting port from /dev/tty.usbserial to /dev/cu.usbserial-FTZ8B03L
	setting address from 0x00000000 to 0x00000000
	espcomm_upload_file
	espcomm_upload_mem
opening port /dev/cu.usbserial-FTZ8B03L at 115200
	tcgetattr
	tcsetattr
	serial open
opening bootloader
resetting board
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
resetting board
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
resetting board
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
trying to connect
	setting character timeout 0
	done
	setting character timeout 1
	done
	espcomm_send_command: sending command header
	espcomm_send_command: sending command payload
warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed
I tried to switch to using "Generic ESP8266 Module", but that did not help (I set the recommended reset mode). In another thread I found that people connected GPIO0 to ground. Tried that and did not help either. When I connect the board to power, red LED is dimmed, I can press the GPIO0 switch, it goes bright red, pressing the reset, I see the blue LED blink and red LED is dim again. I am out of ideas now. Can someone help me?

User avatar
oldeck
 
Posts: 2
Joined: Tue Feb 18, 2014 10:17 pm

Re: Huzzah ESP8266 Upload Problems

Post by oldeck »

+1 on the problems with FTDI on a mac. This board is so frustrating. This is my first Adafruit product, hope the others are better.

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Huzzah ESP8266 Upload Problems

Post by adafruit_support_rick »

Connect GPIO0 to GND through a 220 ohm resistor. Leave it connected, and try to upload. It might take a couple of tries, but it should unstick the ESP8266. You can then remove the resistor connection.

User avatar
andrsd
 
Posts: 6
Joined: Thu Apr 14, 2016 9:55 pm

Re: Huzzah ESP8266 Upload Problems

Post by andrsd »

Connect GPIO0 to GND through a 220 ohm resistor. Leave it connected, and try to upload. It might take a couple of tries, but it should unstick the ESP8266. You can then remove the resistor connection.
I found this advise in another thread. I tried with 150 ohm resistor, but may be not enough, so I'll try again tonight.

I noticed that if I used the resistor the red LED was dim, but without the resistor it was bright. Should there be a change in the brightness? And is 150 ohm enough (I may not have 220 on hand)?

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Huzzah ESP8266 Upload Problems

Post by adafruit_support_rick »

150 ohm is OK.

If the LED is bright, then you're not in programming mode. You have to hold the Reset button and click the GPIO0 button to get the module into programming mode.

User avatar
andrsd
 
Posts: 6
Joined: Thu Apr 14, 2016 9:55 pm

Re: Huzzah ESP8266 Upload Problems

Post by andrsd »

So I tried connecting GPIO#0 to GND and upload the sketch several times (around 1000, used a script for it) and it did not help. However, this wiki page on boot process has an interesting information. When I connect GPIO #0 and #15 to GND and GPIO #2 to 3.3V (on the Huzzah). Then if I press the reset button, the upload goes through both via Ardunio or esptool.py. esptool.py can successfully read chip id, its mac, etc. The problem that remains is, that when the upload is done, the huzzah still sits in bootmode and the code is not executed. When I connect via terminal on 74880 bauds and press reset, I'd see:

Code: Select all

ets Jan 8 2013,rst cause:2, boot mode:(7,0)
. Sometimes it is (7,7). By changing the LOW and HIGH on GPIO #0, #2 and #15, the first number of the boot mode changes.

I also tried to write the bootloader and nodemcu that has lua (not sure if this is the right terminology). I have `esp_init_data_default.bin` from the SDK and `nodemcu-master-7-modules-2016-04-08-20-57-30-integer.bin` generated by nodemcu-build.com. I used this command:

Code: Select all

./esptool.py -p /dev/cu.usbserial-FTZ8B03L write_flash 0x00 nodemcu-master-7-modules-2016-04-08-20-57-30-integer.bin 0x3fc000 esp_init_data_default.bin
Again the upload finished, but the huzzah is still stuck in the bootmode.

I am also referencing this thread where similar problems are being dealt with...

Any ideas on how to proceed are welcome.

User avatar
andrsd
 
Posts: 6
Joined: Thu Apr 14, 2016 9:55 pm

Re: Huzzah ESP8266 Upload Problems

Post by andrsd »

adafruit_support_rick wrote:150 ohm is OK.

If the LED is bright, then you're not in programming mode. You have to hold the Reset button and click the GPIO0 button to get the module into programming mode.
Just saw your message. I was holding GPIO #0 and clicking reset. It might be a simple PEBKAC we are dealing with. Will retry tonight. Thanks!

User avatar
andrsd
 
Posts: 6
Joined: Thu Apr 14, 2016 9:55 pm

Re: Huzzah ESP8266 Upload Problems

Post by andrsd »

andrsd wrote:
adafruit_support_rick wrote:150 ohm is OK.

If the LED is bright, then you're not in programming mode. You have to hold the Reset button and click the GPIO0 button to get the module into programming mode.
Just saw your message. I was holding GPIO #0 and clicking reset. It might be a simple PEBKAC we are dealing with. Will retry tonight. Thanks!
I managed to unstuck the Huzzah from boot mode by following the instructions that @adafruit_support_rick provided. It was a PEBKAC on my side pressing the buttons in an incorrect order. Thanks for your patience and help!

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Huzzah ESP8266 Upload Problems

Post by adafruit_support_rick »

That's great!

User avatar
cbrucewarren
 
Posts: 77
Joined: Sun Mar 09, 2014 1:57 pm

Re: Huzzah ESP8266 Upload Problems

Post by cbrucewarren »

I am having similar issues, but selecting "generic ESP" doesn't seem to work. Sometimes it will upload after I have removed and replaced the usb connector.
I have had more success by selecting "ESP 12-E" board., but that is almost as flaky.

I had thought it may be due to having battery on charge, but I have same issues when I remove the battery.

Aside: when I choose the ESP12-E, it compiles with storage of 26% of memory; if I choose "generic ESP", then it more than doubles to 64%

Thoughts/suggestions?

User avatar
cbrucewarren
 
Posts: 77
Joined: Sun Mar 09, 2014 1:57 pm

Re: Huzzah ESP8266 Upload Problems

Post by cbrucewarren »

I should have added that this is the version with builtin USB and battery charger.....

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Huzzah ESP8266 Upload Problems

Post by adafruit_support_rick »

If it works sometimes, you may have a flaky USB connection. Try some different cables, try connecting through a USB2.0 hub, try a different computer if you can

User avatar
pgebhard
 
Posts: 2
Joined: Wed Apr 23, 2014 12:26 pm

Re: Huzzah ESP8266 Upload Problems

Post by pgebhard »

I've got a Feather Huzzah and have tried the whole "leave GPIO0 connected to GND via a 220 ohm resistor while uploading" and I've tried the "hold the Reset button, connect GPIO0 to GND, and release" and I still cannot upload to my Feather Huzzah. It must be stuck in some mode, but I can't get it out of that mode. The errors I see while attempting to upload are below:

Code: Select all

warning: espcomm_send_command: didn't receive command response
warning: espcomm_send_command(FLASH_DOWNLOAD_BEGIN) failed
closing bootloader
error: espcomm_upload_mem failed 

Locked
Please be positive and constructive with your questions and comments.

Return to “Microcontrollers”