I am programming the TWR-KV46F150M board using IAR-Embedded Workbench 8.40.2 and debugging with PEmicro.
Recently, I was writing a uart_putString() function based on the uart_putchar() from the TWR-KV46F150M QSP. After I have downloaded the code to the board and try to test the uart_putString() function, I encountered an exception and then I quitted the debug mode. Ever since then, I cannot download any program to the board, including those which used to work fine from the QSP, like the LED Demo program. The error message was "The flashloader program reported an error. A fatal error has occurred, the debugger will now terminate". I experience the same error message whether or not I check the "Override default .board file" options under the "use flashloader" option.
I have been researching for a solution and one is to disable the flash loader. I followed the suggestion but then the program will get stuck in some disassembly code, showing that a hard fault exception has occurred, but i dont know what caused it or how can i fix it. This has nothing to deal with the software because it is LED demo program in the QSP, which used to work fine.
Below are some screen captures of the problems i mentioned.
1) Use Flashloader (with or without "Override default .board file)
2) Flashloader disabled
3) The uart_putString() function that called all the problems at first place