Skip to content

benjamin-henry/ArduinoNano33BleSense_ThreadedTimer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

ArduinoNano33BleSense_ThreadedTimer

First of all, download the following library and unzip it in "C:/Users/[YOUR_USERNAME]/Documents/Arduino/libraries" https://github.com/Aduen/ThreadedTimer.git

Then create an Arduino project, and paste the following code :

#include <threadedtimer.h>

ThreadedTimer t1;

int task1;

//executing in Timer Thread
void hello()
{
  Serial.println("hello");
}

void setup()
{
  Serial.begin(115200);
  delay(200);
  
    //execute hello() function every 1000 milliseconds
  task1 = t1.every(1000, hello);
}

void loop()
{
  delay(5000); //main loop delay does not affect the running Timers
    Serial.println("hello again");
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages