Reseting timer counter


hi all,

am trying reset counter turn off backlight of lcd. use bit of code start in loop
code: [select]
backlightstart = millis();
  if (backlightstart - previoustime >= backlightoff)
  {
    previoustime = backlightstart;
    lcd.nobacklight();
  }


it works too. how reset timer here when exiting function example ?

it tried backlightstart = millis() , previoustime = 0 neither worked.

not sure mean, updating previoustime backlightstart (or millis) keep backlight on.
leo..


Arduino Forum > Using Arduino > Project Guidance > Reseting timer counter


arduino

Comments

Popular posts from this blog

Flip address is out of range arduino uno r3

Arduino Uno not uploading

Indesign and MathType fonts