From 4253801267de1d45ddc5b2150f64cd4935243e20 Mon Sep 17 00:00:00 2001 From: rusefi Date: Sat, 20 Apr 2019 10:19:26 -0400 Subject: [PATCH] USB and TLE8888 not working for F4 or F767 #764 --- firmware/hw_layer/trigger_input.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/firmware/hw_layer/trigger_input.cpp b/firmware/hw_layer/trigger_input.cpp index b62b537b23..838d5395e5 100644 --- a/firmware/hw_layer/trigger_input.cpp +++ b/firmware/hw_layer/trigger_input.cpp @@ -104,6 +104,7 @@ static int turnOnTriggerInputPin(const char *msg, brain_pin_e brainPin, bool is_ scheduleMsg(logger, "turnOnTriggerInputPin(PAL) %s %s", msg, hwPortname(brainPin)); pal_line = PAL_LINE(getHwPort("trg", brainPin), getHwPin("trg", brainPin)); + brain_pin_markUsed(brainPin, msg); palEnableLineEvent(pal_line, PAL_EVENT_MODE_BOTH_EDGES); if (is_shaft) @@ -121,6 +122,7 @@ static void turnOffTriggerInputPin(brain_pin_e brainPin) /* check for on-chip? */ if (brainPin == GPIO_UNASSIGNED) return; + brain_pin_markUnused(brainPin); pal_line = PAL_LINE(getHwPort("trg", brainPin), getHwPin("trg", brainPin)); palDisableLineEvent(pal_line);