Freedom_bootloader and led_demo_freedom_a000 result in HardFault_Handler

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

Freedom_bootloader and led_demo_freedom_a000 result in HardFault_Handler

跳至解决方案
2,588 次查看
PJay
Contributor II

Hello,

On a FRDM-K66F target I have successfully gone through the "Get Started with the MCU Bootloader for NXP microcontrollers". I can use blhost.exe successfully. 

$ ./blhost.exe -p COM7 -- get-property 1
Ping responded in 1 attempt(s)
Inject command 'get-property'
Response status = 0 (0x0) Success.
Response word 1 = 1258424065 (0x4b020701)
Current Version = K2.7.1

I debug the example project frdmk66f_freedom_bootloader and enter continue.

I am using the frdmk66f_led_demo_freedom_a000 demo application. I have tested both the debug and release binaries.

Using blhost.exe I execute the following commands:

$ ./blhost.exe -p COM7 flash-erase-region 0xA000 0x8000
Ping responded in 1 attempt(s)
Inject command 'flash-erase-region'
Successful generic response to command 'flash-erase-region'
Response status = 0 (0x0) Success.

$ ./blhost.exe -p COM7 write-memory 0xA000 ./frdmk66f_led_demo_freedom_a000.bin
Ping responded in 1 attempt(s)
Inject command 'write-memory'
Preparing to send 6532 (0x1984) bytes to the target.
Successful generic response to command 'write-memory'
(1/1)100% Completed!
Successful generic response to command 'write-memory'
Response status = 0 (0x0) Success.
Wrote 6532 of 6532 bytes.

$ ./blhost.exe -p COM7 execute 0xA000 0 0
Ping responded in 1 attempt(s)
Inject command 'execute'
Successful generic response to command 'execute'
Response status = 0 (0x0) Success.

At this point, MCUXpresso shows an exception. I have attached an image Picture5.png.

This is unmodified demo code, built  and executed.

MCUXpresso IDE v11.3.0 [Build 5222] [2021-01-11]

SDK 2.9.0

Any help would be appreciated.

PJ

 

Using MCUXpresso, I debug the

0 项奖励
回复
1 解答
2,577 次查看
PJay
Contributor II

Hello,

Reviewing the MCU Bootloader v2.5.0 Reference
Manual, I noted the following in section 10.4.2 Bootloader Configuration:

"Load the Release build of the flash-resident bootloader if you
plan to place the user application at 0xA000. Loading the
Debug build requires you to move the application address
beyond the end of the bootloader image. This address can be
determined from the bootloader map file."

I built a Release version of frdmk66f_freedom_bootloader and went through the process of erasing the flash, writing the binary, reading the first 4 bytes and executing the binary. This was successful.

That is good news.

Unfortunately, I will need to figure out a way to debug or obtain serial logging in the MCU bootloader. Any suggestions would be appreciated.

Thanks,

PJ 

在原帖中查看解决方案

0 项奖励
回复
1 回复
2,578 次查看
PJay
Contributor II

Hello,

Reviewing the MCU Bootloader v2.5.0 Reference
Manual, I noted the following in section 10.4.2 Bootloader Configuration:

"Load the Release build of the flash-resident bootloader if you
plan to place the user application at 0xA000. Loading the
Debug build requires you to move the application address
beyond the end of the bootloader image. This address can be
determined from the bootloader map file."

I built a Release version of frdmk66f_freedom_bootloader and went through the process of erasing the flash, writing the binary, reading the first 4 bytes and executing the binary. This was successful.

That is good news.

Unfortunately, I will need to figure out a way to debug or obtain serial logging in the MCU bootloader. Any suggestions would be appreciated.

Thanks,

PJ 

0 项奖励
回复