R2 Project Log – External Interrupts

I’ve done some playing, and worked out how to turn on the external interrupts on the atmega128 I am using for R2. Code: Changing Trigger Mode: By default, the interrupt triggers when the pin is brought low. If we want to change this behavior, we need to poke at the External Interrupt Control Registers, EICRA […]

R2 Project Log – Battery Monitor Circuit

After playing with R2’s circuit, I realized I had left no ADC ports for monitoring my battery!  As it is a LiPo battery, it needs a low-voltage cutoff at 6v, or it will not be chargeable again.  I built a simple circuit with an attiny13 and a potential divider, which will trigger an interrupt on […]