Signed-off-by: Stephan Baerwolf <stephan.baerwolf@tu-ilmenau.de>
static const uchar currentRequest = 0;
#endif
static const uchar currentRequest = 0;
#endif
-static unsigned char wdtstatus;
-
static const uchar signatureBytes[4] = {
#ifdef SIGNATURE_BYTES
SIGNATURE_BYTES
static const uchar signatureBytes[4] = {
#ifdef SIGNATURE_BYTES
SIGNATURE_BYTES
GICR = (1 << IVCE); /* enable change of interrupt vectors */
GICR = (0 << IVSEL); /* move interrupts to application flash section */
GICR = (1 << IVCE); /* enable change of interrupt vectors */
GICR = (0 << IVSEL); /* move interrupts to application flash section */
/* We must go through a global function pointer variable instead of writing
* ((void (*)(void))0)();
* because the compiler optimizes a constant 0 to "rcall 0" which is not
/* We must go through a global function pointer variable instead of writing
* ((void (*)(void))0)();
* because the compiler optimizes a constant 0 to "rcall 0" which is not
int __attribute__((noreturn)) main(void)
{
/* initialize */
int __attribute__((noreturn)) main(void)
{
/* initialize */
- wdtstatus = WDTCR;
- wdt_disable(); /* main app may have enabled watchdog */
bootLoaderInit();
odDebugInit();
DBG1(0x00, 0, 0);
bootLoaderInit();
odDebugInit();
DBG1(0x00, 0, 0);
GICR = (1 << IVSEL); /* move interrupts to boot flash section */
#endif
if(bootLoaderCondition()){
GICR = (1 << IVSEL); /* move interrupts to boot flash section */
#endif
if(bootLoaderCondition()){
+ wdt_disable(); /* main app may have enabled watchdog */
#if BOOTLOADER_CAN_EXIT
uchar i = 0, j = 0;
#endif
#if BOOTLOADER_CAN_EXIT
uchar i = 0, j = 0;
#endif