From 5f8717855cb2eb1972bd2cbf66d1a1edf8e2cfdd Mon Sep 17 00:00:00 2001 From: bigbearishappy <953308023@qq.com> Date: Fri, 29 Dec 2017 15:13:05 +0800 Subject: [PATCH] update forward and backward control data --- sourcecode/source_code/APP/pid.c | 4 ++-- sourcecode/source_code/APP/pid.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sourcecode/source_code/APP/pid.c b/sourcecode/source_code/APP/pid.c index 422d316..a3fa388 100644 --- a/sourcecode/source_code/APP/pid.c +++ b/sourcecode/source_code/APP/pid.c @@ -79,8 +79,8 @@ int32_t PID_Cal_Speed(pid_s *p, int32_t current,int32_t target,unsigned char whi else if(RIGHT_WHEEL == which_wheel) spd_length_r+= (int32_t)temp; } -#define TEMP1_F 30 -#define TEMP1_B 3 +#define TEMP1_F 20 +#define TEMP1_B 2 if(LEFT_WHEEL == which_wheel){ if(target == 1){ spd_length_l += ADD_VALUE_FB; diff --git a/sourcecode/source_code/APP/pid.h b/sourcecode/source_code/APP/pid.h index db7ed8f..d0001c5 100644 --- a/sourcecode/source_code/APP/pid.h +++ b/sourcecode/source_code/APP/pid.h @@ -7,8 +7,8 @@ #define LEFT_WHEEL 0x4c//'L' 's ascii code is 0x4c #define RIGHT_WHEEL 0x52//'R' 's ascii code is 0x52 -#define ADD_VALUE_LR 0.4 -#define ADD_VALUE_FB 0.1//1 +#define ADD_VALUE_LR 0.3 +#define ADD_VALUE_FB 0.05//1 typedef struct PID {