Rasmus Larsen
posted this on March 11, 2010 13:37
Q:
Which pins do I need to connect to debug and program the EFM32?
A:
The EFM32 has a 2-wire Serial Wire debug interface which is used for programming and debugging. To use this, you must connect the DBG_SWDIO and DBG_SWCLK pins on the EFM32 to your Serial Wire compliant debugger. The EFM32 Gecko Development Kit and the EFM32 Gecko Starter Kit both include a j-link debugger inside the kit itself with the SWCLK and SWDIO pins available on the debug out port (SWCLK on pin 9 and SWDIO on pin 7).
In addition to the two Serial Wire pins, the EFM32 includes an additional Serial Wire Viewer Output pin (DBG_SWO). This is used to output trace data like Program Counter samples and timestamps etc, but is not mandatory for debug/programming. To use this pin you must also enable it as an output in GPIOn_ROUTE and chose a location in addition to setting up your IDE to handle the output data.
If you also want to have access to the reset from your debugger you can connect the RESET pin (pin 15) in the debug out port to your reset pin, but this is optional.
You should also read AN0002 EFM32G Hardware Design Considerations for information on how to connect debug to the device.