diff options
author | Lars-Dominik Braun <lars@6xq.net> | 2014-09-30 16:41:23 +0200 |
---|---|---|
committer | Lars-Dominik Braun <lars@6xq.net> | 2014-09-30 16:41:23 +0200 |
commit | 40a747a13a71c3c95c141173281ca1d82794b679 (patch) | |
tree | 6f9cf0c4813e2a66e17ead5421623e09848d4dc9 | |
parent | 0de25bc37cddc63fbb7f83867a786eeb853aff5a (diff) | |
download | hourglass-40a747a13a71c3c95c141173281ca1d82794b679.tar.gz hourglass-40a747a13a71c3c95c141173281ca1d82794b679.tar.bz2 hourglass-40a747a13a71c3c95c141173281ca1d82794b679.zip |
Fix timer return value
-rw-r--r-- | timer.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -19,7 +19,7 @@ uint32_t time; ISR(TIMER1_COMPA_vect) { ++hits; - time += OCR1A * US_PER_TICK; + time += (uint32_t) OCR1A * (uint32_t) US_PER_TICK; if (hits == maxhits-1) { OCR1A = lastcount; } else if (hits >= maxhits) { |