From 60a23d911838b4efbf962dd94c495657bd4b952a Mon Sep 17 00:00:00 2001 From: zbr Date: Wed, 1 Sep 2021 16:53:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=9B=BA=E4=BB=B6=E5=90=8D=E7=B1=BB=E5=9E=8B?= =?UTF-8?q?=E5=88=A4=E6=96=AD=E8=B0=83=E6=95=B4=EF=BC=8C=E6=A0=B9=E6=8D=AE?= =?UTF-8?q?hwdef=E9=80=89=E6=8B=A9=EF=BC=8C=E5=A6=82=E6=9E=9C=E6=B2=A1?= =?UTF-8?q?=E6=9C=89=E5=88=99=E7=94=A8sysid=5Ftype?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ArduCopter/Parameters.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ArduCopter/Parameters.cpp b/ArduCopter/Parameters.cpp index 3445016f8e..0905cc6fcd 100644 --- a/ArduCopter/Parameters.cpp +++ b/ArduCopter/Parameters.cpp @@ -1678,8 +1678,12 @@ const char* Copter::get_sysid_board_id(void) int32_t nameValue1 =(int32_t) g.sysid_board_name_1st; int32_t nameValue2 = (int32_t)g.sysid_board_name_2nd; // int8_t type = g.sysid_type; - int8_t type = ZR_FRAME_TYPE; - + int8_t type; + if(ZR_FRAME_TYPE != 0){ + type = ZR_FRAME_TYPE; + }else{ + type = g.sysid_type; + } switch (type) { case 0: