From cee1a09445befce8e994a57bdebbdb5a0726ea16 Mon Sep 17 00:00:00 2001 From: Alexander B Date: Sun, 4 Jan 2026 05:09:35 -0500 Subject: [PATCH] Motor Logic --- ESP-IDF_Robot/main/rc.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ESP-IDF_Robot/main/rc.h b/ESP-IDF_Robot/main/rc.h index 402dc30d48..2ad922bf7f 100644 --- a/ESP-IDF_Robot/main/rc.h +++ b/ESP-IDF_Robot/main/rc.h @@ -245,17 +245,17 @@ static void update_motors_pwm (int pwm_motor_1, int pwm_motor_2) { else if (pwm_motor_1 < -2000 && pwm_motor_2 > 1500) { m.motor1_rpm_pcm = 0; - m.motor2_rpm_pcm = pwm_motor_2; // right, forward - m.motor3_rpm_pcm = -pwm_motor_1; // left, reverse + m.motor2_rpm_pcm = 8190; // right, forward + m.motor3_rpm_pcm = 8190; // left, reverse m.motor4_rpm_pcm = 0; } // TURN RIGHT else if (pwm_motor_1 > 1500 && pwm_motor_2 < -2000) { - m.motor1_rpm_pcm = pwm_motor_1; // left, forward + m.motor1_rpm_pcm = 8190; // left, forward m.motor2_rpm_pcm = 0; m.motor3_rpm_pcm = 0; - m.motor4_rpm_pcm = -pwm_motor_2; // right, reverse + m.motor4_rpm_pcm = 8190; // right, reverse }