diff options
| author | EnricoGuccii <partyka.003@proton.me> | 2025-12-22 23:30:13 +0100 |
|---|---|---|
| committer | EnricoGuccii <partyka.003@proton.me> | 2025-12-22 23:30:13 +0100 |
| commit | 967500ab8abefa6700941d589979176677ab0d72 (patch) | |
| tree | 44e818d80accb785b467017dc2642e2af67cdfb7 /src/main.cpp | |
| parent | 86ba591615dde725833b2a024c79f9611326d8eb (diff) | |
yyy
Diffstat (limited to 'src/main.cpp')
| -rw-r--r-- | src/main.cpp | 71 |
1 files changed, 37 insertions, 34 deletions
diff --git a/src/main.cpp b/src/main.cpp index dfd56ca..880856f 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1,34 +1,37 @@ -#include <Arduino.h> -#include "settings.h" -#include "rgb.h" -#include "oled.h" -#include "Buzzer.h" -#include "motors.h" - -#include "animations.h" - -RGB rgb; -BUZZER buzzer; -MOTORS motors; // speed 80 is prefered, because of higher input voltage (5V -> 3.7V after H-bridge), motor is rated for 3V -// in practice, speed below 70 dosn't even work. -OLED oled; - - - - -void setup() -{ - rgb.init(); - buzzer.init(); - motors.init(); - oled.init(); - oled.showMessage("czesc"); - delay(3000); -} - -void loop() -{ - oled.showAnimation(animacja1[0], animacja1FrameCount , animacja1Width, animacja1Height,300); - //oled.showAnimation(animacja1[0], animacja1FrameCount , animacja1Width+ 20, animacja1Height,50); // fajny efekt - oled.showAnimation(animacja2[0], animacja2FrameCount , animacja2Width, animacja2Height,300); -}
\ No newline at end of file +#include "buzzer.h"
+#include "motors.h"
+#include "oled.h"
+#include "rgb.h"
+#include "settings.h"
+#include <Arduino.h>
+
+#include "animations.h"
+
+RGB rgb;
+BUZZER buzzer;
+MOTORS motors; // speed 80 is prefered, because of higher input voltage (5V
+ // -> 3.7V after H-bridge), motor is rated for 3V
+// in practice, speed below 70 dosn't even work.
+OLED oled;
+
+void setup() {
+ rgb.init();
+ buzzer.init();
+ motors.init();
+ oled.init();
+ oled.showMessage("czesc");
+ delay(3000);
+}
+
+void loop() {
+ oled.showAnimation(animacja1[0], animacja1FrameCount, animacja1Width,
+ animacja1Height, 160);
+ oled.showAnimation(animacja1[0], animacja1FrameCount, animacja1Width,
+ animacja1Height, 80);
+ oled.showAnimation(animacja1[0], animacja1FrameCount, animacja1Width + 20,
+ animacja1Height, 50); // fajny efekt
+ oled.showAnimation(animacja2[0], animacja2FrameCount, animacja2Width,
+ animacja2Height, 160);
+ oled.showAnimation(animacja2[0], animacja2FrameCount, animacja2Width,
+ animacja2Height, 80);
+}
|