#ifndef _INTERFACE_UART_H_ #define _INTERFACE_UART_H_ #include "interface_config.h" #include #define ZERO_VALUE 1022//根据遥控器,回0时数据为1022 #define remote_speed un_remote_control_input.bit_data.speed//速度 #define remote_curvature un_remote_control_input.bit_data.curvature//转弯 #define remote_Reserve un_remote_control_input.bit_data.reserve1//保留 #define emergency_stop un_remote_control_input.bit_data.switch_a//DF_SwA #define remote_switch_b un_remote_control_input.bit_data.switch_b//DF_SwB #define remote_switch_c un_remote_control_input.bit_data.switch_c//DF_SwC #define remote_switch_d un_remote_control_input.bit_data.switch_d//DF_SwD #define remote_enable un_remote_control_input.bit_data.enable//手柄使能状态 typedef struct { uint16_t remote_count; //遥控计数器 uint8_t remote_state; //遥控状态 }UartFaultInfo; void uart_Initialize(void); void callback(sdrv_uart_t *ctrl, sdrv_uart_callback_status_e status, void *userData); #endif /* _INTERFACE_H_ */