Sunday 14 December 2014

avr - How do I debug a Arduino Uno with gdb on a Linux pc?


How do I debug (source code single step) a Arduino Uno with gdb on a Linux pc? Please note that I do not like to use AVR Studio in wine or VirtualBox.


Question 1: Physical connection


How and what do I connect to the Uno board? My guess is that since the Uno board is populated with a ATmega328, single step source code should be available? I also guess that I can use either a AVR JTAGICE mkII or a AVR Dragon over the ICSP header?



Question 2: GDB server


Then I noticed that there is some projects like AVaRICE that seems to provide a jtag to gdb function, but there may be other projects?


Question 3: Where is the elf?


And if I get it up and running, where does the Arduino IDE hide the generated output like the elf file with debug symbols (there should be one)? Or do I need to generate a classic Makefile that just uses the Ardino libs?


I tried to find some info on what/how to use, but I have only found those clues that told me what I could do. Can someone push me in the right direction?




No comments:

Post a Comment

arduino - Can I use TI's cc2541 BLE as micro controller to perform operations/ processing instead of ATmega328P AU to save cost?

I am using arduino pro mini (which contains Atmega328p AU ) along with cc2541(HM-10) to process and transfer data over BLE to smartphone. I...