but how do i time it so it only runs for 6 seconds?
using millis() for non blocking timing as in Using millis() for timing. A beginners guide, Several things at the same time and look at the BlinkWithoutDelay example in the IDE.
but how do i time it so it only runs for 6 seconds?
using millis() for non blocking timing as in Using millis() for timing. A beginners guide, Several things at the same time and look at the BlinkWithoutDelay example in the IDE.