0 favorites     0 comments    87 visits

See also...


Keywords

electronics
AVR
logic analyzer
interrupts
soft-uart


Authorizations, license

Visible by: Everyone
All rights reserved

87 visits


Fully interrupt driven soft-uart receiver

Fully interrupt driven soft-uart receiver
By accident I stumbled across my 'system-ticker' interrupt today. As it happens it conveniently ticks at 1MHz! One tick of timer0 is one microsecond. Microsecond timing is exactly what is needed for receiving serial data.

The sampling interrupt (TIM0_COMPA_vect) is now invoked at the right time by setting OCR0A = TCNT0 + FULL_BIT_DELAY.

Comments

Sign-in to write a comment.