Re: Coldfire V2 devices and serial debuggers
Oliver Betz <[email protected]> Thu, 12 Feb 2009 09:09:57 +0100
| Newsgroups | gmane.comp.hardware.motorola.microcontrollers.coldfire |
|---|---|
| Message-ID | <[email protected]> |
Chris Johns wrote: [...] >The BDM protocol will support access to certain CPU resources while the >program is running. The Sourceforge tools provide an open source library of >code with calls that allow access to the BDM protocol. If BDM allows it the >BDM drivers and support libraries will also allow it. There are how-ever some >constraints that make what you want difficult with BDM. The main one is CPU >registers are not accessible when the processor is running. This means >variables held in registers will not be seen and the same goes for the PC so >now does the external host program know where the PC is and where to step next. As long as we talk about watching a running program, this will apply to a serial debugger as well - a serial debugger won't show local variables on stack or in registers of a running application. Just peeking global or static variables via Coldfire V2 BDM has minimal impact (a small number of CPU cycles for each access). With a serial debugger, you could control _when_ the CPU is interrupted, but in total the handling would take longer => more load. And you have better control over the CPU, BDM doesn't need a bootloader etc. If your application disables interrupts, you might be out of luck with a serial debugger. As I wrote, if someone needs single step debugging of one task while an interrupt service routine is still running, a good serial debugger might be better. A bad debugger might crash also if interrupts remain enabled during single step etc. If you are willing to spend some money, you get very nice BDM debuggers saving a lot of time. Be aware that there might be BDM debuggers _not_ allowing realtime variable watch but indeed halting the CPU for hundreds of microseconds. I heared about Codeworrier doing so, but I didn't test it myself. Oliver --- [email protected] Send a post to the list. [email protected] Join the list. [email protected] Join the list in digest mode. [email protected] Leave the list.