Skip to content

Commit c37ade9

Browse files
committed
Correct NO_TIMER index value for SAMD21.
We check validity by ensuring it's lower than the total number of timers. 0 is a terrible number for the NO_TIMER value because its valid even though it shouldn't be. Fixes adafruit/Adafruit_CircuitPython_SimpleIO#29
1 parent b64d568 commit c37ade9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ports/atmel-samd/samd21_pins.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
.wave_output = p_wave_output \
5858
}
5959

60-
#define NO_TIMER TCC(0, 0)
60+
#define NO_TIMER TCC(0xff, 0)
6161

6262
#define TOUCH(y_line) \
6363
.has_touch = true, \

0 commit comments

Comments
 (0)