CF2.0 Debug Adapter How to question.

Firmware/software/electronics/mechanics
Post Reply
lxrocks
Member
Posts: 31
Joined: Sat Feb 15, 2014 1:24 am

CF2.0 Debug Adapter How to question.

Post by lxrocks »

Hi
I would like to set my self up to be able to debug the firmware. I've done a bit of research, but I don't have clear picture on how it all fits together and what i can actually do with it in addition to being an easy way to perform a low level flash.

To set myself up, would I be correct in assuming I need to buy a Debug Adapter and possibly something like the Bus Blaster v3/4. Use a Jtag cable to connect the DebugAdptr and Bus Blaster together and then I could run OpenOCD / urJtag or similar to debug the firmware.

Another thing which is not clear to me, will I be able to perform some form of 'Source Level' debugging with this setup. ie compile with debugging on, set break points and have code stop at specific lines, or will I only be able to see processor registers.

Many thanks in advance.
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: CF2.0 Debug Adapter How to question.

Post by arnaud »

Hi,

To setup the debug adapter you can see this wiki page: http://wiki.bitcraze.se/projects:crazyf ... pter:index

As for the jtag usb programmer you need one that handles SWD. We use the STLink-V2 is is cheap and works well. This is the dongle that is configured by default in the virtual machine and in our projects source. JLinks are also tested (though they are much more expensive). Also it is possible to use ST discovery boards but we have not tested it yet.

With SWD you will be able to flash and debug the CPUs, including source level debugging using openocd/gdb and Eclipse. The Eclipse in the virtual machine is pre-configured for debugging Crazyflie.
drkenlai
Beginner
Posts: 3
Joined: Sat Apr 30, 2016 7:53 pm

Re: CF2.0 Debug Adapter How to question.

Post by drkenlai »

Hi arnaud,

I also want to be able to flash and debug the nRF firmware.

I have bought the below STLink-V2, but I can't mount it on virtual machine and got the following error:
Failed to attach the USB device STMicroelectronics STM32 STLink [0100] to the virtual machine Bitcraze VM 0.8.
Have I got the wrong STLink-V2? Would appreciate if you can let know the process to work with this debugger or which exact debugger your team is using. Thanks.


http://cpc.farnell.com/stmicroelectroni ... CS-SC12550
Post Reply