Advertisement
ferthur

loop delay to millis

May 25th, 2020
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.43 KB | None | 0 0
  1. void wigWag2(uint32_t c1r, uint32_t c1g, uint32_t c1b, uint32_t c2r, uint32_t c2g, uint32_t c2b) {
  2.     for(int i = 0; i < 5; i++) {
  3.         twoColors(c1r, c1g, c1b, c2r, c2g, c2b);
  4.         delay(200);
  5.         twoColors(c2r, c2g, c2b, c1r, c1g, c1b);
  6.         delay(200);
  7.     }
  8.     for(int i = 0; i < 5; i++) {
  9.         clearStrip();
  10.         delay(25);
  11.         twoColors(c2r, c2g, c2b, c1r, c1g, c1b);
  12.         delay(25);
  13.     }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement