fixed a bug... fix in source will be checked in later

what was happening was, the bottommost led would indicate keyboard
startup, but wouldn't turn on after that.  turns out, i had been setting
timer/counter 0 to output on that pin, unnecessarily - because i didn't
understand how to set up timers o_o .  complicated little things.
partial-rewrite
Ben Blazak 2013-05-09 19:54:56 -07:00
parent a3445a539b
commit 1deed9d9ac
1 changed files with 7 additions and 2 deletions

View File

@ -15,7 +15,7 @@
'---------------------------------------------------------------'
* We want:
* `COM0A` = `0b10` : Clear `OC0A` on Compare Match
* `COM0A` = `0b00` : Normal port operation, `OC0A` disconnected
* `COM0B` = `0b00` : Normal port operation, `OC0B` disconnected
* `WGM` = `0b010` : CTC (see section 13.6.2 "Clear Timer on Compare
Match (CTC) Mode")
@ -34,7 +34,8 @@
interrupt
* We also want to set `OCR0A` (Output Compare Register A) to `250`
* We also want to set `OCR0A` (Output Compare Register A) to `250` for the
number of "ticks per millisecond" (see below)
* Since we're using CTC mode with `OCIE0A` enabled, we will be using the
`TIMER0_COMPA_vect` interrupt vector (see
@ -67,6 +68,10 @@
within the range of an 8-bit counter (2^8-1 = 255, and we need 250
ticks).
* Setting `COM0A` and `COM0B` to `0` (or, rather, leaving them that way) is
very important: other things may be operating on those pins (`PB7` and `PD0`
respectively), and we don't want normal port functionality to be overridden.
* Abbreviations:
* `COM`: Compare