Software › Timer0 blink (interrupt-driven)
Timer0 blink (interrupt-driven)
firmware Open · freely redistributable
An original public-domain ATtiny85 program. It configures Timer0 in CTC mode with a /1024 prescaler and enables the compare-match A interrupt (OCIE0A); the main loop does nothing but the COMPA interrupt service routine toggles the onboard LED (PB1) on every compare match. Exercises the ATtiny85 interrupt vector table and avr8js's timer + interrupt delivery. (The ATtiny85's other timer, the PLL-clocked async Timer1, is not modelled by avr8js, so the well-supported Timer0 is used.)
Format: Compiled ATtiny85 flash image (16-bit words, base64) · By: emulators.org · Licence: Public domain