Having issue with ldrPin1 (A0) resets timer and starts new time. Need to have total recorded time from the initial start. Need help with a solution to put ldrPin1 in some sort of delay or sleep state so it will not reset the timer on the second pass. I have uploaded a video on yt, can be seen at: Arduino LDR timer issues.
I uploaded the video for those who need visual reference like myself. The code is below hopefully someone can help me finish this project. Thank you in advance
You need to write out all the states, something like:
before LDR1
after LDR1 before LDR2
after LDR2 before LDR2 return
after LDR2 return before LDR1 return
after LDR1 return (same as first state).
Each transition should record its time and compare with previous transition to get timings and to check
the states haven't got confused - at each point you expect a particular LDR next - check that is what happens,
and that the delay since the last change is sensible. Try to resync states if something different happens, but
log the problem with a Serial print too.
Ok I posted the video on you tube, I have found that through visualization things become more clear. I hope I get some answers on how to solve this issue. The video can be seen at
Again thanks in advance for all the help and advice...