summaryrefslogtreecommitdiff
path: root/src/servo_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/servo_test.cpp')
-rw-r--r--src/servo_test.cpp27
1 files changed, 0 insertions, 27 deletions
diff --git a/src/servo_test.cpp b/src/servo_test.cpp
deleted file mode 100644
index c5e8e6e..0000000
--- a/src/servo_test.cpp
+++ /dev/null
@@ -1,27 +0,0 @@
-#include <stdio.h>
-#include <inttypes.h>
-#include "pico/stdio.h"
-#include "pwm.hpp"
-
-#define MOSFET_PIN 1
-
-PWM pwm;
-
-int main() {
- stdio_init_all();
- // Initialize MOSFET
- gpio_init(MOSFET_PIN);
- gpio_set_dir(MOSFET_PIN, GPIO_OUT);
- gpio_put(MOSFET_PIN, 1);
- pwm.init();
- uint8_t duty_cycle = 13;
- while (1) {
- getchar();
- if (duty_cycle == 2) {
- duty_cycle = 13;
- }
- pwm.set_duty_cycle(duty_cycle);
- printf("Currenty Duty Cycle: %" PRIu8 "\n", duty_cycle);
- duty_cycle--;
- }
-}