The main thing about millis() is it is
NON-waiting
in a linear way
linear way would be
execute command 1
wait (and do nothing else than waiting)
execute command 2
non-blocking timing is
completely different!
non-blocking timing is based on
looping.
The train will arrive at 6:15 pm
you are early at the railway-station and arrive at 6:05 pm
You start reading the newspaper
you take a look onto your watch. Watch shows 6:07 pm (not yet time for the train to arrive)
you look up your WhatsAppMessages
you take a look onto your watch. watch shows 6:08 pm (not yet time for the train to arrive)
you by some sweets from an sweet-automat
you take a look onto your watch. watch shows 6:09 pm (not yet time for the train to arrive)
...
You do a repeated look onto your watch if the right time is here
That is the basic principle of non-blocking timing
If you would take the effort of reading the tutorial you would surely grasp it
But I'm unable to click your mouse. This is something you must do yourself
best regards Stefan