From 404d18cc0cfca09e996d8189b7afa82a1eb638d4 Mon Sep 17 00:00:00 2001 From: Johnathon Slightham Date: Mon, 2 Mar 2026 23:15:24 -0500 Subject: [PATCH] Update DC motor parameters --- main/control/DCMotorActuator.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/main/control/DCMotorActuator.cpp b/main/control/DCMotorActuator.cpp index 1057177..7448edc 100644 --- a/main/control/DCMotorActuator.cpp +++ b/main/control/DCMotorActuator.cpp @@ -13,14 +13,14 @@ #define HIGH_DUTY 1000 #define FWD_CHANNEL LEDC_CHANNEL_1 #define REV_CHANNEL LEDC_CHANNEL_0 -#define DEADZONE 0.5 -#define KP 0.07 +#define DEADZONE 0.1 +#define KP 0.01 #define KI 0 -#define KD 0.065 +#define KD 0.015 #define MIN_PWM_DUTY 675 #define MAX_PWM_DUTY 1024 #define TICKS_PER_ROTATION 14.0 -#define GEAR_RATIO 210 +#define GEAR_RATIO 298 DCMotorActuator::DCMotorActuator() { ledc_timer_config_t ledc_timer = {