From 2a1ab53e6b271feb3ea791cdf3ae822612f59d30 Mon Sep 17 00:00:00 2001 From: bunnie Date: Mon, 31 Jan 2022 12:40:26 +0800 Subject: [PATCH] fix termination condition detection error --- services/com/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/com/src/main.rs b/services/com/src/main.rs index deb3d11ec..9931f69ed 100644 --- a/services/com/src/main.rs +++ b/services/com/src/main.rs @@ -675,7 +675,7 @@ fn xmain() -> ! { loop { com.txrx(ComState::LOOP_TEST.verb); let ack = com.wait_txrx(ComState::LINK_READ.verb, Some(5000)); // should finish with 5 seconds - if (ack & 0xff) != 0x01 { + if (ack & 0xff) != 0x00 { //it will read 0xdd or 0xff if the EC is actually still in reset or held up log::warn!("Wf200 reset took too long, trying to re-establish link sync...{:x}", ack); com.txrx(ComState::LINK_SYNC.verb); ticktimer.sleep_ms(200).unwrap();