RICM4 2017 2018 - Nucleo: Difference between revisions

From air
Jump to navigation Jump to search
Line 48: Line 48:
*GND: connect to GND of microcontroller
*GND: connect to GND of microcontroller
*VCC+CH-PD: connect to 3v3 output of microcontroller
*VCC+CH-PD: connect to 3v3 output of microcontroller
Trying to flash [https://github.com/jeelabs/esp-link/releases/tag/V3.0.14 esp-link-v3.0.14] onto the esp8266ex (512KB flash size, 40m frequency), using [https://github.com/espressif/esptool esptool.py] esptool.py is to be found in ~/.local/lib/python2.7/site-packages), following those steps :
Trying to flash [https://github.com/jeelabs/esp-link/releases/tag/V3.0.14 esp-link-v3.0.14] onto the esp8266ex (512KB flash size, 40m frequency), using [https://github.com/espressif/esptool esptool.py] (if strangely installed, esptool.py is to be found in ~/.local/lib/python2.7/site-packages), following those steps :
*flash boot_v1.X.bin from the official SDK or from the release tgz to 0x00000
*flash boot_v1.X.bin from the official SDK or from the release tgz to 0x00000
*flash blank.bin from the official SDK or from the tgz to 0x3FE000
*flash blank.bin from the official SDK or from the tgz to 0x3FE000

Revision as of 14:01, 27 February 2018

Project presentation

The goal of this project is to be able to re-program the NUCLEO STM32F446RE from a remote place, using wifi.

An user must be able to send a binary program to the Wifi Chipset ESP8266EX plugged on the NUCLEO STM32F446RE. That last one receives the binary, flashes it, and execute its new program.

Then and if we have time, we can look forward on the security issues of this system and try to fix them.

Equipment

  • OLIMEXINO-328
  • NUCLEO STM32F446RE
  • Wifi Chipset ESP8266EX
  • Two computers with the sofware Arduino and Mbed.

Team

Members :

  • CHANET Zoran
  • CHARLOT Servan

Supervisor :

  • Olivier RICHARD

Progress

Week 1 (15/01/18)

This subject was assigned to us.

Received the cards. (But one of them was broken)

Discovering the cards and the documentation.

Week 2 (22/01/18)

Testing codes samples on the cards to get familiar with the language.

Week 3 (29/01/18)

Experimenting the input/outputs capacities of the cards, by redirecting power on some chosen pin to trigger a LED, or sending data on the serial port.

Week 4 (05/02/18)

Linking the two cards together to simulate a serial connection between them.

Then, sending data to one card (via the serial port of a computer) and see if we are able to receive it on the other one (by printing it on the serial port, connected to another computer).

Week 5 (12/02/18)

Creating UML diagrams and this page.

Studying the ESP8266EX documentation and finding a way to to connect it to the Nucleo.

Week 6 (26,27/02/18)

Configuration of the ESP8266.

Hardwiring : (according to jeelabs ESP-link documentation, esp-01 device)

  • URXD: connect to TX of microcontroller
  • UTXD: connect to RX of microcontroller
  • GPIO0: connect to RESET of microcontroller
  • GPIO2: optionally connect green LED to 3.3V (indicates wifi status)
  • GND: connect to GND of microcontroller
  • VCC+CH-PD: connect to 3v3 output of microcontroller

Trying to flash esp-link-v3.0.14 onto the esp8266ex (512KB flash size, 40m frequency), using esptool.py (if strangely installed, esptool.py is to be found in ~/.local/lib/python2.7/site-packages), following those steps :

  • flash boot_v1.X.bin from the official SDK or from the release tgz to 0x00000
  • flash blank.bin from the official SDK or from the tgz to 0x3FE000
  • flash esp_init_data_default.bin from the official SDK or from the tgz to 0x3FC000
  • flash user1.bin to 0x01000
esptool.py --port /dev/ttyUSB0 --baud 460800 write_flash -fs 512KB -ff 40m \
  0x00000 boot_v1.6.bin 0x1000 user1.bin \
  0x7C000 esp_init_data_default.bin 0x7E000 blank.bin


/!\ Error : A fatal error occurred: Failed to connect to Espressif device: Timed out waiting for packet header /!\ → changing the baud rate doesn't seem to solve the issue

New attempt based on these connections :

  • URXD: connect to TX of microcontroller
  • UTXD: connect to RX of microcontroller
  • GPIO0: connect to GND of microcontroller
  • GND: connect to GND of microcontroller
  • VCC+CH-PD: connect to 3v3 output of microcontroller

Exact same error.

According to jeelabs ESP-link documentation again, on both hardwiring models an attempt of putting GPIO2 to high in order to flash the ESP8266 was unsuccessfully made.