Atmega32 debugging with avarice and avr-gdb

This is really great!
I could setup the environment.

My config:

[env:ATmega32]
platform = atmelavr
framework = arduino
board = ATmega32
debug_port = :4242
debug_load_cmds = 
debug_load_mode = manual
debug_tool = custom
debug_init_cmds =
  target remote $DEBUG_PORT
  file "$PROG_PATH"
  load /home/faeren/Projects/PlatformIO/testatmega32/.pio/build/ATmega32/firmware.elf
debug_server =
  avarice
  -1 
  -j/dev/ttyUSB0 
  --ignore-intr 
  :4242

I just have problems with adding breakpoints and stepping out of functions.

Adding breakpoint:

In case of stepping out the debug session just closes.

Do you have any idea why?

Thanks for your support!

Best regards,
Mate

1 Like