Go Down

Topic: [Library] Blink's without delay (Read 1 time) previous topic - next topic

wizarcl

Hi people,
i create a library to blink a led or other devices without delay... I'm now creating a library with various timers wich is i used in plc's...
Pls, test and tell me what you think.
What i can improve?

Tks...

http://code.google.com/p/arduino-blink-whitoutdelay-library/downloads/list

Ps. Sorry for my bad english.

robtillaart

Quote
What i can improve?

- A more elaborated description how to use it
- write a playground article for example.
- use zip for compression (as not everyone has rar)
Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)


robtillaart


- some sample code
- information if it is usable for older versions of Arduino e.g. 0.22
Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

sosoft

Nice, but what about millis buffer owerflow after 50 days?
Asking because I try it with micros and there is only 70 minutes to owerflow...

robtillaart

Quote
Nice, but what about millis buffer owerflow after 50 days?

if handled carefully by using subtractions one can circumvent most overflow failures.

give this code a (75 minute) try and you will see it works as expected (add setup and loop of course)
Code: [Select]

uint32_t now = micros();
if (now - lastDisplay >= 1000000UL)
{
   lastDisplay = now;
   lcd.print("blablabla");
}
Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

Go Up