Hi, I have seen that depending on the program, there are times where it is used the millis function while in others the delay one is chosen. What is the difference between both, and which one is the best?
The principal difference between the two functions is that the Delay() one is a blocking function. It means that if you call it, the program will be stopped until it the delay action has finished. So, it is usually better to use the millis() function as the call is very similar and it does not block the entire program.
For more information about the theme, we have an specific blog where we explain in more depth both functions, their differences and how can they be implemented. You can check it on the following link.
Thanks for asking, we hope to have been helpful.
About This Community
|Asked: 10/2/20, 8:23 AM|
|Seen: 323 times|
|Last updated: 10/2/20, 12:03 PM|