Associate III
April 12, 2012
Question
SD Bootloader Interrupt Problem
- April 12, 2012
- 8 replies
- 1119 views
Posted on April 12, 2012 at 17:18
Hi,
I have written a Bootloader that looks at the micro sd card and loads firmware.bin file into address 0x00800C000 and jumps program execution to 0x00800C004. I have changed the Flash address in the code that is loaded to 0x0080C000 and i have also used NVIC_SetVectorTable to change the vector table address.The funny thing is it works if i flash in a debug version of the bin file, if i try to flash in a Release version of the code it throws a hard fault exception???The code also works fine if i load in a basic bin file with no interrupts but as soon as i set up the interrupt for Timer 3 a hard fault exception is thrown.I am using Timer 3 for file system timing in bootloader code but i disable it before jumping to the new code location at 0x0080C004I have attached the code for both the bootloader and the code for the LEDFlash application that i am having trouble running when loaded in release version.Could someone give me some pointers on what I am doing wrong and why the debug bin works but not the Release?Cheers