We currently run Linux in a Freescale imx35 processor. We have coded several applications, but never done any debug.

  • What hardware should i use?
  • can i run breakpoints and watch variables and registers in run time?
  • What pins should I use for this purpose??
  • Our code cross compiled with gcc.
  • I suppose we should use OCD.

First and foremost, you might want to decide what exactely you plan on debugging.

If it's just a normal application (plus some minor calls to the kernel), you should be fine with gdb (or kgdb) via Ethernet; you probably won't need any hardware at all but it requires some configuration and you can't go any deeper than kgdb allows. Yet, this should suffice for most requirements. You can find some documents on module debugging on the Freescale website.

If you're going the low-level way (debugging bootloaders, deep kernel debugging, start-up behaviour) you might want to go the (far more) expensive way and look for either ARMs DS-5/DSTREAM combination or you might want to look at the Lauterbach Tools, e.g. Trace32. Both of them come at a .. price, we're talking a few k€. Using the latter, you will be able to perform debugging and tracing, usually through an interface called ETM (Embedded Trace Macrocell). This can be available via JTAG or via separate Pins (for high speed trace applications).

| improve this answer | |
  • \$\begingroup\$ Perfect gdb is what we need !!! it seems we have gdb-server in our boards already... Does it work for multi-thread programs also ??? can we run it from windows ??? \$\endgroup\$ – Cristian Mardones Sep 17 '15 at 11:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.