同步步兵代码,暂时关闭底盘跟随
This commit is contained in:
32
云台/云台-old/CarBody/Visual.h
Normal file
32
云台/云台-old/CarBody/Visual.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef __VISUAL_H
|
||||
#define __VISUAL_H
|
||||
|
||||
extern float Visual_Yaw,Visual_Pitch,Visual_Roll,Visual_Delay;//视觉数据偏航角,视觉数据俯仰角
|
||||
extern uint8_t Visual_ReceiveFlag;//视觉数据接收完成标志位
|
||||
///发送数据
|
||||
typedef struct
|
||||
{
|
||||
float curr_yaw; // 当前云台yaw角度
|
||||
float curr_pitch; // 当前云台pitch角
|
||||
uint8_t state; // 当前状态,自瞄-大符-小符
|
||||
uint8_t mark; // 云台角度标记位
|
||||
uint8_t anti_top; // 是否为反陀螺模式
|
||||
uint8_t enemy_color; // 敌方颜色
|
||||
int delta_x; // 能量机关x轴补偿量
|
||||
int delta_y; // 能量机关y轴补偿量
|
||||
}SendData;
|
||||
|
||||
//接受数据
|
||||
typedef struct
|
||||
{
|
||||
char start_flag; // 帧头标志,字符's'
|
||||
int16_t yaw; // float类型的实际角度(以度为单位)/100*(32768-1)
|
||||
int16_t pitch; // float类型的实际角度(以度为单位)/100*(32768-1)
|
||||
uint16_t shoot_delay; // 反陀螺模式下的发射延迟
|
||||
char end_flag; // 帧尾标识,字符'e'
|
||||
}GetData;
|
||||
|
||||
void Visual_Init(void);//视觉初始化
|
||||
void Visual_SendData(void);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user