From e87012cc9c52fb4fb6dfb837c690b3d505c4628c Mon Sep 17 00:00:00 2001 From: Empire Phoenix Date: Sat, 8 Jun 2024 00:27:12 +0200 Subject: [PATCH] keep fault alive actually :) --- rust/src/plant_hal.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rust/src/plant_hal.rs b/rust/src/plant_hal.rs index 39b0e3e..8a318f8 100644 --- a/rust/src/plant_hal.rs +++ b/rust/src/plant_hal.rs @@ -367,7 +367,9 @@ impl PlantCtrlBoardInteraction for PlantCtrlBoard<'_> { } fn general_fault(&mut self, enable: bool) { + unsafe { gpio_hold_dis(self.general_fault.pin()) }; self.general_fault.set_state(enable.into()).unwrap(); + unsafe { gpio_hold_en(self.general_fault.pin()) }; } fn wifi_ap(&mut self) -> Result<()> {