raburton / rboot

An open source bootloader for the ESP8266
https://richard.burtons.org/tag/rboot/?order=ASC
MIT License
300 stars 72 forks source link

big flash help #56

Closed kiralikbeyin closed 5 years ago

kiralikbeyin commented 5 years ago

First of all please can you write maximum ota flash size?

I want to flash a 666k bin

1-I am using https://github.com/SuperHouse/esp-open-rtos/blob/master/examples/http_client_ota/http_get.c example (265k updater)

2-Rboot of https://github.com/SuperHouse/esp-open-rtos didnt work so i am using https://github.com/apiel/aboot/blob/master/aboot/aboot.h @apiel

https://github.com/SuperHouse/esp-open-rtos/issues/668#issuecomment-410457336

3-I was using 2 steps update with arduino. https://github.com/xoseperez/espurna/wiki/TwoStepUpdates

2 steps update :
1-Trigger update with normal 666k firmware.
2-Get an 265k updater firmware.
3-265k updater will get new 667k firmware

Will it work with rboot?

4-Last log https://github.com/SuperHouse/esp-open-rtos/issues/727

SPIEraseSector at position 0x15e000 sector 350
SPIEraseSector at position 0x15f000 sector 351
Writing default boot config.
Header size: 632064
Booting at ram 640256.
sp 0x3ffff710
epc1=0x40001800, epc2=0x00000000, epc3=0x00000000, excvaddr=0xffffffef, depc=0x00000000
Fatal exception (28):
epc1=0x40001800, epc2=0x00000000, epc3=0x00000000, excvaddr=0x00007ff0, depc=0x00000000
Fatal exception (28):

I am open to use arduino ota update but i must switch back to esp-open-rtos also i dont how to make it

Thanks for any help.

raburton commented 5 years ago

0) rBoot is a bootloader, it does not do OTA updates! However, a bootloader allows you to have OTA updates. I supplied sample code in rboot-sample and rboot-sample-bigflash as an example of how you could do OTA updates with the basic SDK (while using rBoot), but lots of frameworks that have used rBoot as a bootloader have implemented their own OTA code - this is a good thing because that is code in the user application and should use the frameworks normal mechanisms for downloads, scheduling, etc. rBoot is perfectly capable of booting full 1mb roms.

1) I'm not familiar with this code as I didn't write it and don't use it, if you think the problem is in this code then you'll need to raise the issue with the author.

2) So you aren't actually using rBoot then? This appears to be a renamed, cut-down, fork of rBoot so what did you hope to gain by switching to it? Does it fix some problem you were previously having with rBoot?

3) It would work, but this should be totally unnecessary. If you are really short of memory in your application you could use a smaller intermediate rom, or you could just make the download more efficient / stop some normal tasks to free up memory /etc.

4) That little bit of log out of context doesn't mean anything to me. The messages shown before the crash do not come from rBoot.

I get the impression you don't know where you are having the problem, but it is almost certainly not in rBoot (well 100% certain, since you aren't even using rBoot!).