Ok, i got greedy. I have now added hours to the routine.
However, i have done a test, setting the delay at 8hrs 45min 32 seconds
and it triggered at 8hrs 44min 06 seconds.
Two things really, is the the type of result expected. I know its a small margin of error, but i thought 1000ms is a 1000ms. Alternatively is there an error in the code that someone can see?
I thought it would be a little more accurate than that. If i set the delay at 32seconds then it triggers at 32seconds.Code:If HoursDelay > 0 then For Hours = 1 to HoursDelay For Minutes = 1 to 60 For Seconds = 1 to 60 If SW2 = 1 Then Goto main Toggle Red ' flashing light for reference Pause(1000) Next Seconds Next Minutes Next Hours EndIF If MinutesDelay > 0 then For Minutes = 1 to Minutesdelay For Seconds = 1 to 60 If SW2 = 1 Then Goto main Toggle Red ' flashing light for reference Pause(1000) Next Seconds Next Minutes EndIF If SecondsDelay > 0 then For Seconds = 1 to SecondsDelay If SW2 = 1 Then goto main Toggle Red ' flashing light for reference pause(1000) Next Seconds EndIF
There are only so many lengthy test you can do, waiting 8hrs for an event to trigger is a long time !!
Cheers,




Bookmarks