How to debug an application in MCUXpresso when there is a bootloader

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to debug an application in MCUXpresso when there is a bootloader

280件の閲覧回数
RogerDavisWork
Contributor II

We are using MCUXpresso for K81 development with a JLink debugger.  We have a bootloader in the first 16K that successfully transitions to an application above that including moving the vectors seemlessly. This all works when running live, but I cannot figure out how to use MCUXpresso to debug the application in this scenario.

For example, I can debug the Bootloader and step in assembly into the application, and I can let it run and halt and see that it halts at a valid address in the application.

But what I want is to flash the bootloader and then debug the application with its source symbols.  When I try to do this, it never breaks at main() and always seems to be in the weeds when I halt.

If I disconnect the debugger and reboot the target, it clearly runs just fine with the code that is getting flashed, both in the bootloader and application areas. So, the problem appears to be related to getting MCUXpresso and JLink to be able to debug it properly.

What would help is some basic steps to make this work within the IDE.

タグ(2)
0 件の賞賛
1 返信

242件の閲覧回数
ErichStyger
Senior Contributor V

You have to properly load the symbols with gdb.

if you want to debug the bootloader and the application, then just attach and load the symbols:

https://mcuoneclipse.com/2020/11/03/debugging-bootloader-and-application-with-one-debug-session/

 

0 件の賞賛