接受延时
This commit is contained in:
parent
555317ea3b
commit
6035580f27
@ -5,6 +5,7 @@
|
||||
/* Includes ----------------------------------------------------------------- */
|
||||
#include "module/balance_chassis.h"
|
||||
#include "bsp/can.h"
|
||||
#include "bsp/time.h"
|
||||
#include "component/user_math.h"
|
||||
#include "device/motor_lk.h"
|
||||
#include "module/config.h"
|
||||
@ -83,7 +84,7 @@ static int8_t Chassis_ProcessCANCommands(Chassis_t *chassis) {
|
||||
float right_out = (float)((int16_t)(rx_msg.data[4] | (rx_msg.data[5] << 8))) / 2048.0f;
|
||||
MOTOR_LK_SetOutput(&chassis->param.wheel_param[1], right_out);
|
||||
}
|
||||
|
||||
BSP_TIME_Delay_us(400); // 确保CAN总线有足够时间处理消息
|
||||
return DEVICE_OK;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user