ESP8266 2MB + OTA

backupluis
Posts: 11
Joined: Tue Nov 29, 2016 11:10 am

Re: ESP8266 2MB + OTA

Postby backupluis » Sat Oct 08, 2022 6:43 pm

FrenkR wrote:Issue resolved. If you have partition of size 1MB or 2MB, then "irom0_0_seg" address-es are the same for both partitions (looks like 0x1000 or 0x101000 are the same?). If you have 512KB partitions, then you must create LD script with different ROM addresses same way as is in LD files for 1024KB OTA partition segmentation(e.g.eagle.app.v6.new.1024.app1.ld, eagle.app.v6.new.1024.app2.ld).

If you don't do that, then uprading from app1 to app2 with the same bin will work, but if you will empty segment1, bin2 will stop working (which makes sense).

I hope that I saved 3 days of hard work "hunting" all those zillion of exceptions.
Rgds,
Frenk


I have a problem that looks like this one, first off all, Im using rtos sdk 1.4, yes, its very old and I want to move to 2 or even to 3 but I can't until I resolve some problems.
I been using this sdk version since 2017 in a wroom 2 board without any problems, even ota updates works well, but some days ago I found a ESP8266-1 8Mbits board in my lab and start to move the project to this board, just to have a starting source before try to migrate to sdk v2.

I can't do OTA update from user2 to user1 (Looks like the same problem noted in this thread). while OTA from user1 to user2 works well, from user2 to user1 hangs just after the flash erase then reboot by watchdog timer in the same user2 but it no longer boots, so, in my case, user2 seems to need something from user1,

I check my ld files and in my case irom0_0_seg are differents:
eagle.app.v6.new.1024.app1.ld irom0_0_seg : org = 0x40201010, len = 0x2B000
eagle.app.v6.new.1024.app2.ld irom0_0_seg : org = 0x40281010, len = 0x2B000

But I see something that looks weird, my two bin files are equals, user1.1024.new.bin and user2.1024.new.bin are binary equal.
I don't know too much about the internals of the compilers and the sdk, so, my question is:

is ok that both files have the same content?
If so, why we have to generate two files if the content its the same.
If not, why my setup generate both files with the same content and where I have to start digging to try to resolve it.

I really appreciate if you can explain or help me a little about my problem/confusion.

Thanks
Luis

backupluis
Posts: 11
Joined: Tue Nov 29, 2016 11:10 am

Re: ESP8266 2MB + OTA

Postby backupluis » Sat Oct 08, 2022 7:10 pm

backupluis wrote:
FrenkR wrote:Issue resolved. If you have partition of size 1MB or 2MB, then "irom0_0_seg" address-es are the same for both partitions (looks like 0x1000 or 0x101000 are the same?). If you have 512KB partitions, then you must create LD script with different ROM addresses same way as is in LD files for 1024KB OTA partition segmentation(e.g.eagle.app.v6.new.1024.app1.ld, eagle.app.v6.new.1024.app2.ld).

If you don't do that, then uprading from app1 to app2 with the same bin will work, but if you will empty segment1, bin2 will stop working (which makes sense).

I hope that I saved 3 days of hard work "hunting" all those zillion of exceptions.
Rgds,
Frenk


I have a problem that looks like this one, first off all, Im using rtos sdk 1.4, yes, its very old and I want to move to 2 or even to 3 but I can't until I resolve some problems.
I been using this sdk version since 2017 in a wroom 2 board without any problems, even ota updates works well, but some days ago I found a ESP8266-1 8Mbits board in my lab and start to move the project to this board, just to have a starting source before try to migrate to sdk v2.

I can't do OTA update from user2 to user1 (Looks like the same problem noted in this thread). while OTA from user1 to user2 works well, from user2 to user1 hangs just after the flash erase then reboot by watchdog timer in the same user2 but it no longer boots, so, in my case, user2 seems to need something from user1,

I check my ld files and in my case irom0_0_seg are differents:
eagle.app.v6.new.1024.app1.ld irom0_0_seg : org = 0x40201010, len = 0x2B000
eagle.app.v6.new.1024.app2.ld irom0_0_seg : org = 0x40281010, len = 0x2B000

But I see something that looks weird, my two bin files are equals, user1.1024.new.bin and user2.1024.new.bin are binary equal.
I don't know too much about the internals of the compilers and the sdk, so, my question is:

is ok that both files have the same content?
If so, why we have to generate two files if the content its the same.
If not, why my setup generate both files with the same content and where I have to start digging to try to resolve it.

I really appreciate if you can explain or help me a little about my problem/confusion.

Thanks
Luis


I reply myself, just to leave record of the problem, I just read in some other post that user1 and user2 could NOT be equals, so, I start to check files I use to compile, this files was used for wroom 2 and I make new versions for esp-1, in some of the edits, I've removed the make clean between user1 and user2, thats why my bin files are equal, then, recompile and reflash, then test ota from user1 to user2 => OK, then from user2 to user1 => OK, so, my problem its solved.

AgentSmithers
Posts: 195
Joined: Sat Apr 01, 2017 1:21 am
Contact:

Re: ESP8266 2MB + OTA

Postby AgentSmithers » Thu Nov 03, 2022 3:47 am

Thanks for the Feedback, I hope Espresiff brings this forum back and saves our BLOG POST DATA! :)

Who is online

Users browsing this forum: No registered users and 186 guests