From 12c38f155b1528cc6ff94e9bf6377ba5a4479c61 Mon Sep 17 00:00:00 2001 From: "Dirk O. Kaar" Date: Mon, 9 Sep 2019 14:32:40 +0200 Subject: [PATCH] Test case same as ESP8266 --- .../examples/TickerParameter/TickerParameter.ino | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/libraries/Ticker/examples/TickerParameter/TickerParameter.ino b/libraries/Ticker/examples/TickerParameter/TickerParameter.ino index 99c69c62567..a6c7d9d2348 100644 --- a/libraries/Ticker/examples/TickerParameter/TickerParameter.ino +++ b/libraries/Ticker/examples/TickerParameter/TickerParameter.ino @@ -24,15 +24,19 @@ void setPin(int state) { digitalWrite(LED_BUILTIN, state); } +void setPinChar(char state) { + digitalWrite(LED_BUILTIN, state); +} + void setup() { pinMode(LED_BUILTIN, OUTPUT); - digitalWrite(1, LOW); // every 25 ms, call setPin(0) tickerSetLow.attach_ms(25, setPin, 0); - // every 26 ms, call setPin(1) - tickerSetHigh.attach_ms(26, setPin, 1); + // every 26 ms, call setPinChar(1) + tickerSetHigh.attach_ms(26, setPinChar, (char)1); + } void loop() {