Browse Source

SOH修正指令数据长度修改(1个字节)

BJQX-ZHENGCHAO\Zhengchao 1 year ago
parent
commit
198e3d5875
1 changed files with 1 additions and 1 deletions
  1. 1 1
      code/app/AppTaskUart1.c

+ 1 - 1
code/app/AppTaskUart1.c

@@ -1756,7 +1756,7 @@ uint16 tcpUdsFunc(uint8 *Ptr, uint8 *AnsPtr)
 					case 0x0202:  //soh correction did
 					{
 
-						if(udsDataLen == 2)
+						if(udsDataLen == 1)
 						{
 							float sohCorrectionValue = (float)((float)((DataBuffer[0]<<8 | DataBuffer[1])&0xFFFF)*0.1);
 							if(sohCorrectionValue > 0 && sohCorrectionValue<100)  //有效修正