From 0f9b9b0f848d5a3625d991afcf368e3d0b78ca55 Mon Sep 17 00:00:00 2001 From: zhaohe Date: Sat, 27 Apr 2024 10:35:29 +0800 Subject: [PATCH] update --- iflytop_canbus_protocol.hpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/iflytop_canbus_protocol.hpp b/iflytop_canbus_protocol.hpp index 23e33d0..6cc1add 100644 --- a/iflytop_canbus_protocol.hpp +++ b/iflytop_canbus_protocol.hpp @@ -8,16 +8,16 @@ extern "C" { /** * @brief 消息格式 12bit from,1bit emergency - * + * H L * [1] [4bit] [8bit] [8bit] [4bit/4bit] * , from to frameNum/frameId */ typedef struct { - uint8_t pad; - uint8_t from; - uint8_t to; uint8_t frameNumAndFrameId; + uint8_t to; + uint8_t from; + uint8_t pad; } zcanid_t; typedef struct { @@ -53,7 +53,7 @@ typedef enum { } ProjectID_t; typedef enum { - kerr_noerror = 0, + kerr_noerror = 0, kerr_overtime = 1, // 驱动器错误 @@ -67,7 +67,6 @@ typedef enum { } ErrorCode_t; - static const char *ErrorCodeToString(uint32_t code) { switch (code) { case kerr_noerror: