Hi,
I am new to Arduino though I'd worked with PIC before. I got the MsTimer2 working on the Mega but on the Nano, it doesn't work. Does Nano have timer2. As the matter of fact, where do I find out more about the resources of certain device and how to use them? Supposed in Arduino, lots of features are written up as libs, but I've also seen people writing timers and interrupt using direct keywords just like in MCU??? Please enlighten me in this new subject.
Thanks,
The simple sketch I tried:
#include <MsTimer2.h>
boolean output = HIGH;
void flash() {
digitalWrite(13, output); // pin13 has an LED build on board
output = !output;
}
void setup() {
pinMode(13, OUTPUT);
MsTimer2::set(500, flash); // 500ms period
MsTimer2::start();
}
void loop() {}