Mario Mikočević wrote:Try this ->Code: Select all#include <Ticker.h>
Ticker tickerSensorScan;
#define WAITTIME 300
boolean tickerFired;
void flagSensorScan( void ) {
tickerFired = true;
}
void setup() {
tickerSensorScan.attach( WAITTIME, flagSensorScan );
tickerFired = true;
}
void loop() {
if( tickerFired ) {
tickerFired = false;
doSomethingWithSensor();
}
}
Tnx Mario, I have some trouble finding the ticker library, I can see it on Github, but not download... Can you help me there?