Download firmware problem

trojek
Posts: 15
Joined: Mon Sep 26, 2016 4:18 am

Download firmware problem

Postby trojek » Thu Sep 29, 2016 1:03 am

I downloaded the newest(0049b5d615f233b82d3ac4005fe9b85535e758cb) version of ESP_MESH_DEMO. I change 4 required (erver_ip, MESH_ROUTER_BSSID, MESH_ROUTER_SSID, MESH_ROUTER_PASSWD) parameters in user_config.h, and prepare firmware using gen_misc.h. Everything I did excactly as in the README. Only change was that I get user1.1024.new.2.bin, not user1.1024.new.1.bin due to that spi size and map: 1024 (512KB + 512KB) is option 2 not 1.
Then I take esp device and upload firmware on it (using esptool.py on Linux and ESP8266 Flash Download Tool for Windows). Devise don't connect to my AP and when I connect it to UART I get response as on the image below:
Image

I try to connect to it on different speeds as follows: 9600, 115200, 74880.

What should I do to upload id correctly?

ESP_Alen

Re: Download firmware problem

Postby ESP_Alen » Thu Sep 29, 2016 12:58 pm

trojek wrote:I downloaded the newest(0049b5d615f233b82d3ac4005fe9b85535e758cb) version of ESP_MESH_DEMO. I change 4 required (erver_ip, MESH_ROUTER_BSSID, MESH_ROUTER_SSID, MESH_ROUTER_PASSWD) parameters in user_config.h, and prepare firmware using gen_misc.h. Everything I did excactly as in the README. Only change was that I get user1.1024.new.2.bin, not user1.1024.new.1.bin due to that spi size and map: 1024 (512KB + 512KB) is option 2 not 1.
Then I take esp device and upload firmware on it (using esptool.py on Linux and ESP8266 Flash Download Tool for Windows). Devise don't connect to my AP and when I connect it to UART I get response as on the image below:
Image

I try to connect to it on different speeds as follows: 9600, 115200, 74880.

What should I do to upload id correctly?


Download speeds is 115200
UART speeds is 74880

trojek
Posts: 15
Joined: Mon Sep 26, 2016 4:18 am

Re: Download firmware problem

Postby trojek » Thu Sep 29, 2016 2:54 pm

I set parameters as you told but it still don't work correctly.
To download firmware I use commands as follows:

Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 erase_flash


Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 write_flash -fm qio -fs 8m -ff 40m 0xfc000 ~/ESP8266_MESH_DEMO/bin/esp_init_data_default.bin


Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 write_flash -fm qio -fs 8m -ff 40m 0xfe000 ~/ESP8266_MESH_DEMO/bin/blank.bin


Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 write_flash -fm qio -fs 8m -ff 40m 0x00000 ~/ESP8266_MESH_DEMO/bin/boot_v1.4\(b1\).bin


Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 write_flash -fm qio -fs 8m -ff 40m 0x01000 ~/ESP8266_MESH_DEMO/bin/upgrade/user1.1024.new.2.bin


There are binary files which I download to esp device: http://rojek.cc/esp_firmware.zip

Do you have any idea what's wrong?

ESP_Alen

Re: Download firmware problem

Postby ESP_Alen » Thu Sep 29, 2016 5:35 pm

1. please use 115200 to download default.init.bin, blank.bin, boot.bin, user1.bin
2. use 74880 to get txt information about com.

trojek
Posts: 15
Joined: Mon Sep 26, 2016 4:18 am

Re: Download firmware problem

Postby trojek » Thu Sep 29, 2016 6:01 pm

I did as you said but it still doesn't work. I modify download command by adding: --baud 115200, so now it looks like this:

Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 --baud 115200 write_flash -fm qio -fs 8m -ff 40m 0xfc000 ~/ESP8266_MESH_DEMO/bin/esp_init_data_default.bin


Than I connect via putty on speed 74880.

Do you have any other idea?

ESP_Alen

Re: Download firmware problem

Postby ESP_Alen » Thu Sep 29, 2016 9:00 pm

trojek wrote:I did as you said but it still doesn't work. I modify download command by adding: --baud 115200, so now it looks like this:

Code: Select all

sudo python ~/esp-open-sdk/xtensa-lx106-elf/bin/esptool.py --port /dev/ttyUSB0 --baud 115200 write_flash -fm qio -fs 8m -ff 40m 0xfc000 ~/ESP8266_MESH_DEMO/bin/esp_init_data_default.bin


Than I connect via putty on speed 74880.

Do you have any other idea?


Sorry, I have no idea.
Tomorrow, i shall schedule another guy to try to fix the problem.

trojek
Posts: 15
Joined: Mon Sep 26, 2016 4:18 am

Re: Download firmware problem

Postby trojek » Thu Sep 29, 2016 11:49 pm

I try to connect via putty on Windows and it works. I still don't connect to AP but the firmware is downloaded correct.
Now I can debug why it is problem with connection (flush ssid: pwd:@▒▒?@▒▒?) - it don't recognize my ssid..., but this is case to another topic.

In conclusion, I try on 3 machines (2 linux based and one with windows installed) to upload firmware on various methods (using esptool and espressif gui tool for windows). All methods of downloading firmware work correctly. The problem is with connecting via UART on machines with linux. I used putty on linux and windows and I get reasonable information only on windows. On linux I tried also another software: minicon (which is recommended by espressif) but it dosn't suport baud rate 74880, cu but I get the same "rubbish" as when I use putty. What is strange I have some devices with firmware created a few days ago (baud rate 115200) and I can connect to it by putty in linux. Probably it's bug.

ESP_Alen

Re: Download firmware problem

Postby ESP_Alen » Sat Oct 08, 2016 1:45 pm

trojek wrote:I try to connect via putty on Windows and it works. I still don't connect to AP but the firmware is downloaded correct.
Now I can debug why it is problem with connection (flush ssid: pwd:@▒▒?@▒▒?) - it don't recognize my ssid..., but this is case to another topic.

In conclusion, I try on 3 machines (2 linux based and one with windows installed) to upload firmware on various methods (using esptool and espressif gui tool for windows). All methods of downloading firmware work correctly. The problem is with connecting via UART on machines with linux. I used putty on linux and windows and I get reasonable information only on windows. On linux I tried also another software: minicon (which is recommended by espressif) but it dosn't suport baud rate 74880, cu but I get the same "rubbish" as when I use putty. What is strange I have some devices with firmware created a few days ago (baud rate 115200) and I can connect to it by putty in linux. Probably it's bug.


you can modify the UART_BAUT_RATIO to support 115200.

trojek
Posts: 15
Joined: Mon Sep 26, 2016 4:18 am

Re: Download firmware problem

Postby trojek » Sat Oct 08, 2016 5:20 pm

I changed baud rate to 115200. Now I can connect via UART on this speed on linux.
On the commit 0049b5d615f233b82d3ac4005fe9b85535e758cb the value of parameter UART_BAUT_RATIO was changed from 115200 to 74800. I don't know exactly why it was necessary, but currently everything works well. Thank you.

ESP_Alen

Re: Download firmware problem

Postby ESP_Alen » Mon Oct 10, 2016 6:17 pm

trojek wrote:I changed baud rate to 115200. Now I can connect via UART on this speed on linux.
On the commit 0049b5d615f233b82d3ac4005fe9b85535e758cb the value of parameter UART_BAUT_RATIO was changed from 115200 to 74800. I don't know exactly why it was necessary, but currently everything works well. Thank you.


I have merged your achievement, thanks very mush for what you did for mesh.

Who is online

Users browsing this forum: No registered users and 54 guests