diff --git a/firmware/config/engines/ford_1995_inline_6.cpp b/firmware/config/engines/ford_1995_inline_6.cpp index 05c749c8d7..44b5ddf35f 100644 --- a/firmware/config/engines/ford_1995_inline_6.cpp +++ b/firmware/config/engines/ford_1995_inline_6.cpp @@ -92,6 +92,4 @@ void setFordInline6(DECLARE_CONFIG_PARAMETER_SIGNATURE) { engineConfiguration->triggerInputPins[0] = GPIOA_8; engineConfiguration->triggerInputPins[1] = GPIOA_5; - engineConfiguration->logicAnalyzerPins[0] = GPIOC_6; - engineConfiguration->logicAnalyzerPins[1] = GPIOE_5; } diff --git a/firmware/hw_layer/digital_input/digital_input_icu.cpp b/firmware/hw_layer/digital_input/digital_input_icu.cpp index 0825fad6d0..59fdbce43f 100644 --- a/firmware/hw_layer/digital_input/digital_input_icu.cpp +++ b/firmware/hw_layer/digital_input/digital_input_icu.cpp @@ -205,9 +205,8 @@ ICUDriver * getInputCaptureDriver(const char *msg, brain_pin_e hwPin) { return nullptr; } -static void turnOnCapturePin(const char *msg, brain_pin_e brainPin) { - ICUDriver *driver = getInputCaptureDriver(msg, brainPin); - if (driver != NULL) { +static void turnOnCapturePin(const char *msg, ICUDriver* driver, brain_pin_e brainPin) { + if (driver) { iomode_t mode = (iomode_t) PAL_MODE_ALTERNATE(getAlternateFunctions(driver)); efiSetPadMode(msg, brainPin, mode); } @@ -270,7 +269,7 @@ static void startInputDriver(const char *msg, /*nullable*/digital_input_s *hw) { digital_input_s* startDigitalCapture(const char *msg, brain_pin_e brainPin) { ICUDriver *driver = getInputCaptureDriver(msg, brainPin); if (!driver) { - warning(CUSTOM_ERR_INVALID_INPUT_ICU_PIN, "w_not input pin"); + firmwareError(CUSTOM_ERR_INVALID_INPUT_ICU_PIN, "Invalid %s input pin: %s", msg, hwPortname(brainPin)); return nullptr; } @@ -280,7 +279,7 @@ digital_input_s* startDigitalCapture(const char *msg, brain_pin_e brainPin) { hw->started = false; hw->brainPin = brainPin; hw->driver = driver; - turnOnCapturePin(msg, brainPin); + turnOnCapturePin(msg, driver, brainPin); startInputDriver(msg, hw); return hw; diff --git a/firmware/hw_layer/vehicle_speed.cpp b/firmware/hw_layer/vehicle_speed.cpp index fc92a3002f..32672e4924 100644 --- a/firmware/hw_layer/vehicle_speed.cpp +++ b/firmware/hw_layer/vehicle_speed.cpp @@ -93,7 +93,9 @@ void startVSSPins(void) { #elif HAL_USE_ICU digital_input_s* vehicleSpeedInput = startDigitalCapture("VSS", CONFIG(vehicleSpeedSensorInputPin)); - vehicleSpeedInput->widthListeners.registerCallback((VoidInt) vsAnaWidthCallback, nullptr); + if (vehicleSpeedInput) { + vehicleSpeedInput->widthListeners.registerCallback((VoidInt) vsAnaWidthCallback, nullptr); + } #else #error "HAL_USE_ICU or HAL_VSS_USE_PAL should be enabled to use EFI_VEHICLE_SPEED" #endif /* HAL_VSS_USE_PAL, HAL_USE_ICU */