Advertisement
kris83

Podswietlenie

Jul 5th, 2021
21
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. void Podswietlenie() {
  2. for (int fadeValue = 0 ; fadeValue <= 255; fadeValue += 5) {
  3. analogWrite(Podswietlenie_PWM, fadeValue);
  4. delay(30);
  5. }
  6. }
  7.  
  8. void Migacz_Lewy_OUT() {
  9. if (aktualnyCzas - zapamietanyCzas_Migacz_Lewy >= 500UL) {
  10. zapamietanyCzas_Migacz_Lewy = aktualnyCzas;
  11. stan_Migacz_Lewy = !stan_Migacz_Lewy;
  12. digitalWrite(Wyjscie_Migacz_Lewy, stan_Migacz_Lewy);
  13. }
  14. }
  15.  
  16. void Migacz_Prawy_OUT() {
  17. if (aktualnyCzas - zapamietanyCzas_Migacz_Prawy >= 500UL) {
  18. zapamietanyCzas_Migacz_Prawy = aktualnyCzas;
  19. stan_Migacz_Prawy = !stan_Migacz_Prawy;
  20. digitalWrite(Wyjscie_Migacz_Prawy, stan_Migacz_Prawy);
  21. }
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement