Author Topic: Restore OAK after wrong flash  (Read 2044 times)

nos86

  • Newbie
  • *
  • Posts: 4
Restore OAK after wrong flash
« on: June 08, 2016, 12:12:39 pm »
Hello All,

I currently a problem with my OAKs...

In the past I flashed, wrongly starting from adress 0x000000. I think I corrupted the bootload space.
I followed instruction to restore firmware, but all commands start to write from 0x1000 location.

Does anyone know that is the right command to flash all memory including bootload, Digistump firmware and so on?


Thanks in advance,
Salvo

kh

  • Jr. Member
  • **
  • Posts: 64
  • OakTerm developer
Re: Restore OAK after wrong flash
« Reply #1 on: June 09, 2016, 04:17:19 pm »
Hi @nos86,

Do you remember the command you ran? Did you just write blank.bin to 0x0000 instead of 0x1000, or did you write more or all of the flash?

If that's all, you just need to reflash OakBoot to the first sector. Get the OakBoot binary from here: https://github.com/digistump/OakBoot/raw/master/oakboot.bin and then flash it with the following command:

Code: [Select]
python esptool.py -p YOUR_COM_PORT -b 115200 write_flash -fs 32m 0x0000 oakboot.bin

If you overwrote the config and backup config sectors at 0x100000 and 0x200000, recovery is more complicated.

nos86

  • Newbie
  • *
  • Posts: 4
Re: Restore OAK after wrong flash
« Reply #2 on: June 11, 2016, 06:39:49 am »
Hi kh,

actually I did several trial flashing also different firmware (NodeMCU), but I never flashed 0x100000 or 0x200000..

So, I'll try to flash the OakBoot file and see what happens.

Thanks so much for support,
Salvo