Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #define WDT 8
- #define LED_BAR 12
- #define DELAY 2100
- void main(void) {
- int i, leds;
- leds = 0;
- i = DELAY;
- while (i > 0)
- {
- leds = i / (DELAY / LED_BAR);
- printf("%d\t%d\n", i, leds);
- i = i - WDT;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement