From 044840def395013eab45a7eabf929651b30a308a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E7=AB=8B=E5=B8=AE?= <3294713004@qq.com> Date: Sat, 22 Feb 2025 01:52:56 +0800 Subject: [PATCH] =?UTF-8?q?Fix:=20=E4=BF=AE=E5=A4=8D=E4=B8=B2=E5=8F=A3?= =?UTF-8?q?=E5=9C=A8=E5=8F=AA=E6=8E=A5=E6=94=B6=20"\n"=20=E6=97=B6?= =?UTF-8?q?=E4=B8=8D=E4=BC=9A=E8=87=AA=E5=8A=A8=E6=8D=A2=E8=A1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/modules/mixly-modules/common/serial.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/modules/mixly-modules/common/serial.js b/common/modules/mixly-modules/common/serial.js index bd3a86a8..cb56b7b8 100644 --- a/common/modules/mixly-modules/common/serial.js +++ b/common/modules/mixly-modules/common/serial.js @@ -145,8 +145,8 @@ class Serial { // 如果当前字节是 "_" this.#specialLength_ = 2; this.#special_.push(String.fromCharCode(byte)); - } else if (byte !== 0x0A) { - // 如果当前字节是 "\n" + } else if (byte !== 0x0D) { + // 如果当前字节不是 "\r" if (this.#specialLength_) { this.#specialLength_--; this.#special_.push(String.fromCharCode(byte));