Since the datasheet is the same as for ATmega1284 and ATmega2560 the depicted
table of interrupt seems to be the same, too.
But on the second impression there are small "*" at some interrupts not
implemented in the affected devices.
So adapt the bootloader__do_spm addresses - thank you oh you dear fail safe.
Without following code added last time, I never would have found it before some
critical fail!
#if defined(_VECTORS_SIZE)
#if (funcaddr___bootloader__do_spm != (BOOTLOADER_ADDRESS+_VECTORS_SIZE))
#error "bootloader__do_spm is not located after interrupts - sth. is very wrong here!"
#endif
#endif
Signed-off-by: Stephan Baerwolf <stephan.baerwolf@tu-ilmenau.de>
* Creation Date: 2012-08-01
* Copyright: (c) 2013 by Stephan Baerwolf
* License: GNU GPL v2 (see License.txt)
* Creation Date: 2012-08-01
* Copyright: (c) 2013 by Stephan Baerwolf
* License: GNU GPL v2 (see License.txt)
*/
#ifndef SPMINTERFACE_H_f70ba6adf7624275947e859bdbff0599
*/
#ifndef SPMINTERFACE_H_f70ba6adf7624275947e859bdbff0599
#elif defined (__AVR_ATmega1280__)
#define funcaddr___bootloader__do_spm 0x1e0e4
#elif defined (__AVR_ATmega1281__)
#elif defined (__AVR_ATmega1280__)
#define funcaddr___bootloader__do_spm 0x1e0e4
#elif defined (__AVR_ATmega1281__)
- #define funcaddr___bootloader__do_spm 0x1e0e4
+ #define funcaddr___bootloader__do_spm 0x1e0cc
#elif defined (__AVR_ATmega1284__) || defined (__AVR_ATmega1284P__)
#define funcaddr___bootloader__do_spm 0x1e08c
#elif defined (__AVR_ATmega2560__)
#define funcaddr___bootloader__do_spm 0x3e0e4
#elif defined (__AVR_ATmega2561__)
#elif defined (__AVR_ATmega1284__) || defined (__AVR_ATmega1284P__)
#define funcaddr___bootloader__do_spm 0x1e08c
#elif defined (__AVR_ATmega2560__)
#define funcaddr___bootloader__do_spm 0x3e0e4
#elif defined (__AVR_ATmega2561__)
- #define funcaddr___bootloader__do_spm 0x3e0e4
+ #define funcaddr___bootloader__do_spm 0x3e0cc
#else
#error "unknown MCU - where is bootloader__do_spm located?"
#endif
#else
#error "unknown MCU - where is bootloader__do_spm located?"
#endif