Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void setup()
- {
- Serial.begin( 115200 );
- }
- void loop()
- {
- uint32_t t1 = millis();
- static uint32_t t2 = t1;
- static uint32_t secondes = 0;
- if ( t1 - t2 >= 1000 )
- {
- t2 = t1;
- ++secondes;
- Serial.println( secondes );
- }
- }
Add Comment
Please, Sign In to add comment