基础稳定版本

main
Zeng wei (曾威) 2 years ago
parent a7b735786a
commit d5dae3ec68

@ -24,7 +24,7 @@ void PID_Init()
if (pid.Kp < 1e-7) { pid.Kp = 40; } if (pid.Kp < 1e-7) { pid.Kp = 40; }
if (pid.Ki < 1e-7) { pid.Ki = 0.001; } if (pid.Ki < 1e-7) { pid.Ki = 0.001; }
if (pid.Kd < 1e-7) { pid.Kd = 340; } if (pid.Kd < 1e-7) { pid.Kd = 340; }
if (pid.tem_threshold < 0.0001) { pid.tem_threshold = 0.5; } if (pid.tem_threshold < 0.0001) { pid.tem_threshold = 0.2; }
pid.t = 500; // PID calc period pid.t = 500; // PID calc period
// pid.Ti=5000000;// integral time // pid.Ti=5000000;// integral time
@ -44,7 +44,7 @@ void send_speed_signal(int speed) {
RS485_3_Init(9600); RS485_3_Init(9600);
// delay_xms(100); // delay_xms(100);
RS485_3_Send_Data(rs485speed, 8); RS485_3_Send_Data(rs485speed, 8);
// delay_xms(100); delay_xms(30);
RS485_1_Init(9600); RS485_1_Init(9600);
} }

File diff suppressed because it is too large Load Diff

@ -33,7 +33,7 @@ void Host_Computer_Communication(void);
// 60seconds delay // 60seconds delay
#define SYNC_ENVIRONMENT_DATA_REQUEST_PERIOD pdMS_TO_TICKS(60000) #define SYNC_ENVIRONMENT_DATA_REQUEST_PERIOD pdMS_TO_TICKS(60000)
// 2seconds delay // 1seconds delay
#define MAIN_TASK_PERIOD pdMS_TO_TICKS(1000) #define MAIN_TASK_PERIOD pdMS_TO_TICKS(1000)

Loading…
Cancel
Save