Chat freely about anything...

User avatar
By lah
#48448 Hello,

I've worked with nodemcu without any problems. Now I'm getting different issues working with esp-12-e, some are solved, but others are not.

During all these tests EN pulled up threw a 1.7k resistor. Reset connected to a press button in pull up configuration.GPIO 0, GPIO2, GPIO15 set according to modes described here :
wiki/doku.php?id=esp8266_gpio_pin_allocations

I'm using this USB-Serial adapter : https://moderndevice.com/product/usb-bub-ii/ based on FT232RL
First I tried to send AT commands threw UART. It did not work. I got esp8266 boot logs until "ready message", but did not get any responses to my AT commands
After some investigations I figured out :
* powering esp8266 from FT232RL 3.3V output is not enough (50mA)
* power on esp8266 needs to be very precise. After powering from FT232RL I powered it from a lab power supply. Settings were 3.33V with 1A => I did not any response from AT command.
I increased Voltage to 3.38V and I get response to AT commands. I added a 100µ capacitor between power and GND : same issue, below 3.36V module do not respond to AT commands.

Is esp8266 so sensitive to its power source? As I Added a capacitor that did not changed low threshold of 3.36V, issue do not come from current peak, how can we explain it?

After having AT command working I tried to flash from UART. I added a pulled up button on reset line, GPIO2 pulled up, GPIO 0 pulled down. Flashing did not started.
After some investigations I figured out :
* GPIO 15 must be pulled down with a resistor (1.8k)

Now flash begins (I checked it with a logic analyzer) but stops... Below are logs. Partial flashing has been made, now I'm unable to boot AT command firmware, instead I get these boot logs :


Code: Select all
 ets Jan  8 2013,rst cause:2, boot mode:(1,7)


 ets Jan  8 2013,rst cause:2, boot mode:(3,7)

ets_main.c


I've tried :
* changing uart speed
* using esptool.py
* another module : same result
* another FTDI (same model)

So how to solve this issue? Have you got some suggestions, explanations?



thanks - lah

Code: Select all
python2 ./esptool.py -p /dev/ttyUSB0 -b 74880 write_flash 0x00000 /tmp/builde5c24a78d3067d20a5e99bdd16cf82ce.tmp/sketch_jun02a.ino.bin
esptool.py v1.2-dev
Connecting...
Running Cesanta flasher stub...

A fatal error occurred: Timed out waiting for packet header



Code: Select all
esptool -vv -cb 115200 -cp /dev/ttyUSB0 -ca 0x00000 -cf  /tmp/builde5c24a78d3067d20a5e99bdd16cf82ce.tmp/sketch_jun02a.ino.bin
esptool v0.4.8 - (c) 2014 Ch. Klippel <ck@atelier-klippel.de>
  setting baudrate from 115200 to 115200
  setting port from /dev/ttyUSB0 to /dev/ttyUSB0
  setting address from 0x00000000 to 0x00000000
  espcomm_upload_file
  espcomm_upload_mem
opening port /dev/ttyUSB0 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
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
  espcomm_send_command: receiving 2 bytes of data
Uploading 223360 bytes from to flash at 0x00000000
  erasing flash
  size: 036880 address: 000000
  first_sector_index: 0
  total_sector_count: 55
  head_sector_count: 16
  adjusted_sector_count: 39
  erase_size: 027000
  espcomm_send_command: sending command header
  espcomm_send_command: sending command payload
  setting timeout 15000
  setting character timeout 150
  done
  setting timeout 1
  setting character timeout 1
  done
  espcomm_send_command: receiving 2 bytes of data
  writing flash
warning: espcomm_send_command: didn't receive command response
warning: espcomm_send_command(FLASH_DOWNLOAD_DATA) failed
closing bootloader
error: espcomm_upload_mem failed
User avatar
By lah
#48714 Just to post some fresh news :
* flash processed stopped using : https://moderndevice.com/product/usb-bub-ii/ , it has a ft232rl - 1435-c

Today I tried with another USB-serial converter :
* http://www.goodluckbuy.com/ftdi-basic-b ... te-se.html it runs at 5V but pin on esp8266 are 5v tolerant... and flashing works like a charm... Moreover, I can flash with a voltage on esp8266 of ~3.2V, This usb serial converter has ft232rl - 1243-c.

I'm interested by a valid explanation!