diff --git a/src/donut_3lb_config.h b/src/donut_3lb_config.h index 97b45b0..e4f072b 100644 --- a/src/donut_3lb_config.h +++ b/src/donut_3lb_config.h @@ -29,7 +29,7 @@ #define ACCEL_MOUNT_RADIUS_CM 0 // this being 0 prevents accel_offset from going negative in 3lb mode // this value will need to be tuned to a good speed - Cai -#define HEADING_CONTROL_SENSITIVITY 0.01 // tunes how fast the heading led moves left or right +#define HEADING_CONTROL_SENSITIVITY 0.05 // tunes how fast the heading led moves left or right #define ACCEL_1_X_OFFSET -7 #define ACCEL_1_Y_OFFSET -5 @@ -38,17 +38,17 @@ #define ACCEL_2_Y_OFFSET -5 -#define THROTTLE_PC_P 1 // was 0.5 for working translation test with 1lb on 4/29/26 - Cai +#define THROTTLE_PC_P 1.5 // was 0.5 for working translation test with 1lb on 4/29/26 - Cai // CAN_ADJUST_ACCEL_MOUNT_RADIUS is defined here so you can use the // left_stick_x to adjust the get_rpm_2accel RPM reading by a constant factor #define CAN_ADJUST_ACCEL_MOUNT_RADIUS -#define ACCEL_OFFSET_SENSITIVITY 0.0001 +#define ACCEL_OFFSET_SENSITIVITY 0.005 #define MOTOR_ON_PERCENT_DURATION 0.5 // This might technically be a half of a half - Cai (I still have no idea what this comment means - also Cai) #define MIN_TRANSLATION_RPM 400 -#define LED_OFFSET_PERCENT 0.25 +#define LED_OFFSET_PERCENT 0.5 #define MIN_LED_PERCENT_DURATION 0.25 #define MAX_LED_PERCENT_DURATION 0.5 @@ -56,7 +56,7 @@ // the throttle sent to each motor can be during a half-rotation // 1 = very different // 0 = can't differ at all -#define MELTY_MAX_TRANSLATION_AGGRESSION 0.75 +#define MELTY_MAX_TRANSLATION_AGGRESSION 0.65 #define MELTY_MAX_THROTTLE 1 #define TANK_DRIVE_MAX_THROTTLE 0.125 diff --git a/src/donut_accel.c b/src/donut_accel.c index 2f3073c..1f4ea22 100644 --- a/src/donut_accel.c +++ b/src/donut_accel.c @@ -110,11 +110,11 @@ double get_rpm_2accel(double right_x_percent, double accel_offset_cm) { // Position vectors of the accelerometers (in cm) - Accel1Position.x = 1.0 * 1.0/sqrtf(2.0); - Accel1Position.y = 1.0 * 1.0/sqrtf(2.0); + Accel1Position.x = 1.025 * 1.0/sqrtf(2.0); + Accel1Position.y = 1.025 * 1.0/sqrtf(2.0); - Accel2Position.x = -1.0 * 1.0/sqrtf(2.0); - Accel2Position.y = -1.0 * 1.0/sqrtf(2.0); + Accel2Position.x = -1.025 * 1.0/sqrtf(2.0); + Accel2Position.y = -1.025 * 1.0/sqrtf(2.0); // omega = sqrt [ ||(a1 - a2)|| / ||(r2 - r1)|| ]