chore: remove joystick logging
This commit is contained in:
@@ -8,17 +8,4 @@ void Display::begin() {
|
||||
lcd.backlight();
|
||||
}
|
||||
|
||||
// TODO: Remove this method in the future
|
||||
void Display::drawJoystick(double x, double y, bool pressed) {
|
||||
lcd.clear();
|
||||
|
||||
lcd.setCursor(0, 0);
|
||||
lcd.print("X:");
|
||||
lcd.print(x, 2); // Print X value with 2 decimal places
|
||||
lcd.print(" Y:");
|
||||
lcd.print(y, 2); // Print Y value with 2 decimal places
|
||||
|
||||
lcd.setCursor(0, 1);
|
||||
lcd.print("Pressed: ");
|
||||
lcd.print(pressed ? "Yes" : "No");
|
||||
}
|
||||
|
||||
+1
-10
@@ -17,13 +17,4 @@ void setup() {
|
||||
}
|
||||
|
||||
void loop() {
|
||||
double x = joystick.getX();
|
||||
double y = joystick.getY();
|
||||
bool pressed = joystick.isPressed();
|
||||
|
||||
printf("X: %.2f | Y: %.2f | Pressed: %s\n", x, y, pressed ? "Yes" : "No");
|
||||
display.drawJoystick(x, y, pressed);
|
||||
|
||||
digitalWrite(LED_BUILTIN, pressed ? HIGH : LOW);
|
||||
|
||||
delay(500);}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user