diff --git a/firmware/hw_layer/HIP9011.cpp b/firmware/hw_layer/HIP9011.cpp index 12f35c68df..fe514144b9 100644 --- a/firmware/hw_layer/HIP9011.cpp +++ b/firmware/hw_layer/HIP9011.cpp @@ -35,6 +35,8 @@ #if EFI_HIP_9011 || defined(__DOXYGEN__) +#define NEW_CODE TRUE + #define HIP_DEBUG FALSE extern OutputPin outputs[IO_PIN_COUNT]; @@ -61,6 +63,8 @@ static bool_t isIntegrating = false; */ static bool_t needToSendSpiCommand = true; +static bool_t isSendingSpiCommand = false; + static scheduling_s startTimer[2]; static scheduling_s endTimer[2]; @@ -220,6 +224,8 @@ static void setGain(float value) { } static void endOfSpiCommunication(SPIDriver *spip) { + spiUnselectI(driver); + isSendingSpiCommand = false; } void initHip9011(void) {