Hardware debugging


  • Mod

    Just got success with hardware debugging using my JTAGICE3. Same way can be used for other atmel's debuggers

    The reason to look for solution came from this project http://forum.mysensors.org/topic/957/red-green-matrix-information-panel-with-real-time-clock
    Because there is no usual way to upload arduino sketch using JTAG I have to look for a solution based on Atmel Studio.
    The following steps are needed:

    1. To install Atmel Studio and VisualMicro plugin
    2. To setup your arduino project with VisualMicro
    3. Compile project
    4. Launch a second instance of AtmelStudio and go to File/Open menu. Select Open Object File for Debugging and find out the .ELF file inside the Debug folder inside Arduino project compiled by VisualMicro. Select "link to file" instead of copy
    5. Save new atmel Studio project, it will be a project for debug. Go to Project/Options/Tool and choose your debugging tool. Save project.

    After all this you will be able to debug your arduino using debugWire (atmega328) or JTAG (mega).

    After recompilation of the project your files will be reloaded in your debug project after pressing reload
    1Untitled.jpg

    You will probably also asked to recover source mappings:
    2Untitled.jpg

    Made your choice about mapping. You do not need to recover mappings to sources you are not interesting in. For example on my screen shot I have no interest to debug arduino internal sources this why I just press Finish


Log in to reply
 

Suggested Topics

0
Online

11.2k
Users

11.1k
Topics

112.5k
Posts