larsks / blog.oddbit.com

3 stars 0 forks source link

post/2019-01-22-debugging-attiny-code-pt-2/ #38

Open utterances-bot opened 2 months ago

utterances-bot commented 2 months ago

Debugging attiny85 code, part 2: Automating GDB with scripts :: blog.oddbit.com

This is the second of three posts about using gdb and simavr to debug AVR code. The complete series is: Part 1: Using GDB A walkthrough of using GDB to manually inspect the behavior of our code. Part 2: Automating GDB with scripts Creating GDB scripts to automatically test the behavior of our code. Part 3: Tracing with simavr Using simavr to collect information about the state of microcontroller pins while our code is running.

https://blog.oddbit.com/post/2019-01-22-debugging-attiny-code-pt-2/

taspenwall commented 2 months ago

Thanks for the great write up. I'm able to start simavr and connect avr-gdb just fine and can do most debugging tasks. What I can't seem to throw and interrupt and trigger my ISR. It doesn't seem to respond to a change in PINB. I think I'm just not telling GDB that I want an interrupt the right way right now. I was wondering with your experiencing with simavr and avr-gdb if you might know how interrupts are handled with simavr.

larsks commented 2 months ago

@taspenwall I haven't touched the avr stuff in a several years now; off the top of my head I'm not sure how simavr handles interrupts (or if it handles interrupts). I know that at the time I wrote this I ran into a number of limitations in the simulator; this may have been one of them.