Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int RegA = 99;
- int RegB = 1;
- void setup()
- {
- Serial.begin(9600);
- }
- //-----------------------
- void loop()
- {
- RegB ++;
- if (RegB == 2)
- {
- Mostra_SetSeg();
- }
- RegA --;
- if (RegA <= 0)
- {
- RegA = 100;
- RegB = 0;
- }
- delay(50);
- }
- //-----------------------
- void Mostra_SetSeg()
- {
- //define ports para 7 seg
- RegB = 0;
- Serial.println(RegA);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement