增加了文档,修改通信协议,更新了平衡底盘的VMC映射和五连杆解算,修复了双板通信数据结构步对齐的错误

This commit is contained in:
NeoZng
2023-04-14 18:17:46 +08:00
parent 681dce3c90
commit 9e364cbaaa
14 changed files with 225 additions and 97 deletions

Binary file not shown.

View File

@@ -7,6 +7,9 @@
> 1. 对`CANCommGet()`进行修改,使得其可以返回数据是否更新的相关信息。
## 重要提醒
如果传输过程中出现多次丢包或长度校验不通过尤其是传输长度较大的时候请开启CAN的Auto Retransmission并尝试修改CANComm实例的发送和接受ID以提高在总线仲裁中的优先级
## 总览和封装说明
@@ -135,3 +138,5 @@ CAN comm的通信协议如下
接收的流程见代码注释。
流程图如下:![未命名文件](../../assets/CANcomm.png)

View File

@@ -82,7 +82,7 @@ void VisionSend(Vision_Send_s *send)
uint8_t send_buff[VISION_SEND_SIZE];
uint16_t tx_len;
// TODO: code to set flag_register
flag_register = 30<<8|0b00000001;
flag_register = 30<<8|0b00000001;
// 将数据转化为seasky协议的数据包
get_protocol_send_data(0x02, flag_register, &send->yaw, 3, send_buff, &tx_len);
USARTSend(vision_usart_instance, send_buff, tx_len, USART_TRANSFER_DMA); // 和视觉通信使用IT,防止和接收使用的DMA冲突

View File

@@ -13,7 +13,7 @@
## 一、串口配置
通信方式是串口,配置为波特率 1152008 位数据位1 位停止位,无硬件流控,无校验位。
通信方式是串口,配置为波特率 9216008 位数据位1 位停止位,无硬件流控,无校验位。
## 二、数据帧说明

View File

@@ -32,7 +32,7 @@ static void RectifyRCjoystick()
* @param[out] rc_ctrl: remote control data struct point
* @retval none
*/
uint16_t aaaaa;
static void sbus_to_rc(const uint8_t *sbus_buf)
{