pert
October 12, 2017, 2:17pm
2
sailaja:
in above link,they are saying
"if it is set to 0xF0 bootloader will look for a bin file on the sdcard named
firmware.bin and use it to flash the firmware then reset the byte to 0xFF so it
does this only once "
In the above only once means,if we want to upgrade more times code through sd card ... is it possible ?
Of course.
sailaja:
can you please suggest correct procedure to upload code from sd card multiple times ??
You just need to set EEPROM address 0x1FF to 0xF0. The easiest way to do this is by simply adding the code to your sketch to either do this automatically in setup() or to do it on demand according to some input of your choice. For information on how to write to EEPROM see:
https://www.arduino.cc/en/Reference/EEPROM
or:
http://www.nongnu.org/avr-libc/user-manual/group__avr__eeprom.html
Some possible alternatives:
unfortunately it does not have official support for ATmega2560. Supposedly it was discovered how to get it working:
opened 09:41AM - 05 Nov 15 UTC
help wanted
We are looking for someone looking deeper into ATmega2560 support!
This is copi… ed from @per1234 in Issue #1
I managed to get the ATmega2560 to load a program from the SD card but it's far from ideal. I discovered the program will run under these circumstances:
- Set high fuse to DB instead of DA to disable the Boot Reset vector(BOOTRST=1).
- The standard Arduino boards.txt enables the Boot Reset vector(BOOTRST=0) as does your hfuse setting in README.md.
- Use Atmel AVRISP mkII to Burn Bootloader instead of USPasp.
- I normally use my USBasp due to the mkII not working correctly for Burn Bootloader with current versions of Arduino IDE for me without some ugly workarounds.
- Press the reset button after powering the board with the SD card attached.
- The program has been loaded into the MCU flash but doesn't run until the reset button is pressed. With the other boards the program begins to run immediately after it has been loaded from the SD card.
After the program has been loaded from the SD no other programs will load from the SD card until the bootloader is burned again. If I change any of the above conditions it doesn't work. With all of these conditions it works consistently. I have no idea what this means, it's a bit more advanced than my current skill level.
but I haven't had any time to try it out yet.
If you want a separate programmer to do this, here's instructions and code to make one:
or if you want to buy one:
http://www.crossroadsfencing.com/BobuinoRev17/Programmer.html