Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By diffstorm
#69893 Yes I do!
Are you sure that's all?

Can you share more details about it, how I can understand the end of firmware? Where it starts and finished, so what it's size etc?
Also can it read it's own firmware with its firmware? So there is an inception, maybe a RAM function needed or to read backup of the firmware?
I'll be glad if you enlighten me as much as you do know about the subject.
Thanks.
User avatar
By martinayotte
#69896
diffstorm wrote:Can you share more details about it, how I can understand the end of firmware? Where it starts and finished, so what it's size etc?
Also can it read it's own firmware with its firmware? So there is an inception, maybe a RAM function needed or to read backup of the firmware?
I'll be glad if you enlighten me as much as you do know about the subject.
Thanks.


The firmware is starting at address 0 and ends at address given by ESP.getSketchSize().
Of course the firmware can read itself, like this ESP.getSketchMD5() is doing.
The only limitation here, is that if you need to send it to the other ESP using chunks, usally the chunk size should be the network packet size, which is 1460 bytes (instead of 512 used my getSketchMD5(), although keeping at 512 would also work).
So, in other words, remove all the stuff related to MD5 calculation, but keep the loop with the flashRead() and sent the buffer to the other ESP.