feat: compile option to disable MCU check (#4988)
This commit is contained in:
@@ -55,6 +55,7 @@ option(IMRC_RELEASE "Used to build IMRC released firmware" OFF)
|
|||||||
option(HARDWARE_TRAINER_MULTI "Allow multi trainer" OFF)
|
option(HARDWARE_TRAINER_MULTI "Allow multi trainer" OFF)
|
||||||
option(BOOTLOADER "Include Bootloader" ON)
|
option(BOOTLOADER "Include Bootloader" ON)
|
||||||
option(FWDRIVE "Attach also firmware drive with USB" OFF)
|
option(FWDRIVE "Attach also firmware drive with USB" OFF)
|
||||||
|
option(DISABLE_MCUCHECK "Disable MCU check at start" OFF)
|
||||||
|
|
||||||
if(PCB STREQUAL X9D+ AND PCBREV STREQUAL 2019)
|
if(PCB STREQUAL X9D+ AND PCBREV STREQUAL 2019)
|
||||||
option(USBJ_EX "Enable USB Joystick Extension" OFF)
|
option(USBJ_EX "Enable USB Joystick Extension" OFF)
|
||||||
@@ -374,6 +375,10 @@ if(FWDRIVE)
|
|||||||
add_definitions(-DFWDRIVE)
|
add_definitions(-DFWDRIVE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(DISABLE_MCUCHECK)
|
||||||
|
add_definitions(-DDISABLE_MCUCHECK)
|
||||||
|
endif()
|
||||||
|
|
||||||
set(SRC
|
set(SRC
|
||||||
${SRC}
|
${SRC}
|
||||||
opentx.cpp
|
opentx.cpp
|
||||||
|
|||||||
@@ -1573,7 +1573,9 @@ int main()
|
|||||||
modulePortInit();
|
modulePortInit();
|
||||||
pulsesInit();
|
pulsesInit();
|
||||||
|
|
||||||
|
#if !defined(DISABLE_MCUCHECK)
|
||||||
checkValidMCU();
|
checkValidMCU();
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(PCBHORUS)
|
#if defined(PCBHORUS)
|
||||||
if (!IS_FIRMWARE_COMPATIBLE_WITH_BOARD()) {
|
if (!IS_FIRMWARE_COMPATIBLE_WITH_BOARD()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user