更改decode和校验

master
CZ 7 months ago
commit 4ea014e673

Binary file not shown.

@ -81,8 +81,8 @@ namespace Module.Socket.Tool
} }
// 取校验和的低8位 // 取校验和的低8位
byte b1 = (byte)(checksum & 0xFF); //byte b1 = (byte)(checksum & 0xFF);
byte b2 = (byte)(bytes[bytes.Count() - 1] & 0xFF); //byte b2 = (byte)(bytes[bytes.Count() - 1] & 0xFF);
if ((byte)(bytes[bytes.Count() - 1] & 0xFF) == (byte)(checksum & 0xFF)) if ((byte)(bytes[bytes.Count() - 1] & 0xFF) == (byte)(checksum & 0xFF))
{ {
var info = bytes[4]; var info = bytes[4];

Loading…
Cancel
Save