Fail to connect to running application from USBDM

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

Fail to connect to running application from USBDM

跳至解决方案
1,191 次查看
uribendelac
Contributor III

Hi,

I have an application that has initialized the KL27Z256 microcontroller and is stuck in an endless loop. I try to connect to the microcontroller from USBDM - I set the Startup options to "Connect to running target" and "Halt Target", but when I try, I get an error saying "

Cannot access memory at address 0x746

Failed to execute MI command:

-break-insert -t main

"

Any idea what could be wrong?

Uri

0 项奖励
回复
1 解答
959 次查看
uribendelac
Contributor III

OK, thanks. Initially I couldn't connect while issue a reset, since that would cause the bootloader to run first, causing the USB enumeration to fail. Now that I have managed to program the security bytes I have disabled the bootloader so that issuing a reset is not a problem anymore.

Uri

在原帖中查看解决方案

0 项奖励
回复
2 回复数
959 次查看
pgo
Senior Contributor V

Hi Uri,

I set up a KL27 running a small loop with a printf so I could see that it was executing.

I was able to connect to the target although it complained about thread list which I don't understand.  The debugger display was also not initially synchronized so it could certainly do with some improvement.

It is possible that it cannot connect to a target due to a few reasons such as disabled debug interface pins or the target has halted with a bus fault.  The only reliable connection process is with a target reset and even then it may not be possible.

Other than that I can't really suggest a reason.

bye

0 项奖励
回复
960 次查看
uribendelac
Contributor III

OK, thanks. Initially I couldn't connect while issue a reset, since that would cause the bootloader to run first, causing the USB enumeration to fail. Now that I have managed to program the security bytes I have disabled the bootloader so that issuing a reset is not a problem anymore.

Uri

0 项奖励
回复