I'm using Timer1 library for generation of pulse. But in my code, at some places i need to change the timer values. Can anyone suggest the ways to do it.
In below code in place of 370000, I need to change the value after getting some inputs in conditional loops. Ex. if (x==1) Timer value should be 370000 else 185000.
#include <TimerOne.h>
int count = 0;
int LED = 13;
void setup() {
pinMode(LED, OUTPUT);
Timer1.initialize(370000);
Serial.begin(9600);
}
void loop() {
Serial.print("Count Value: ");
Serial.println(count++);
}