From 1162e5e75bfe2208e5f2af59427a8e4f9440acaf Mon Sep 17 00:00:00 2001 From: rusefillc Date: Sat, 20 Mar 2021 12:47:02 -0400 Subject: [PATCH] time_since_boot should be used in MAIN_RELAY_LOGIC #2258 safer implementation for now --- firmware/controllers/system_fsio.h | 13 +++++++++---- firmware/controllers/system_fsio.txt | 3 ++- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/firmware/controllers/system_fsio.h b/firmware/controllers/system_fsio.h index 280a15fecf..d73f83c650 100644 --- a/firmware/controllers/system_fsio.h +++ b/firmware/controllers/system_fsio.h @@ -1,6 +1,6 @@ // this https://en.wikipedia.org/wiki/Reverse_Polish_notation is generated automatically // from controllers/system_fsio.txt -// on 2021-01-11_14_17_13_143 +// on 2021-03-20_12_45_43_719 // // // in this file we define system FSIO expressions @@ -33,11 +33,16 @@ // Human-readable: (rpm > fsio_setting(2)) | ((coolant > fsio_setting(3)) | (vbatt < fsio_setting(4))) #define COMBINED_WARNING_LIGHT "rpm 2 fsio_setting > coolant 3 fsio_setting > vbatt 4 fsio_setting < | |" -//needed by EFI_MAIN_RELAY_CONTROL +//needed by EFI_MAIN_RELAY_CONTROL which is currently FALSE for most of the boards +// todo: make '5' a setting? +// todo: always have 'EFI_MAIN_RELAY_CONTROL'? +// at the moment microRusEFI would not be happy with vbatt > 5 since microRusEFI senses main relay output +// todo https://github.com/rusefi/rusefi/issues/2258 //MAIN_RELAY_LOGIC=(time_since_boot >= 0 & time_since_boot < 2) | (vbatt > 5) | in_shutdown +//MAIN_RELAY_LOGIC=(!in_mr_bench) & ((vbatt > 5) | in_shutdown) -// Human-readable: (!in_mr_bench) & ((vbatt > 5) | in_shutdown) -#define MAIN_RELAY_LOGIC "in_mr_bench ! vbatt 5 > in_shutdown | &" +// Human-readable: (!in_mr_bench) & (vbatt > 5) +#define MAIN_RELAY_LOGIC "in_mr_bench ! vbatt 5 > &" // could be used for simple variable intake geometry setups or warning light or starter block // Human-readable: rpm > fsio_setting(1) diff --git a/firmware/controllers/system_fsio.txt b/firmware/controllers/system_fsio.txt index 5e961caa11..128001069b 100644 --- a/firmware/controllers/system_fsio.txt +++ b/firmware/controllers/system_fsio.txt @@ -30,7 +30,8 @@ COMBINED_WARNING_LIGHT=(rpm > fsio_setting(2)) | ((coolant > fsio_setting(3)) | # at the moment microRusEFI would not be happy with vbatt > 5 since microRusEFI senses main relay output # todo https://github.com/rusefi/rusefi/issues/2258 #MAIN_RELAY_LOGIC=(time_since_boot >= 0 & time_since_boot < 2) | (vbatt > 5) | in_shutdown -MAIN_RELAY_LOGIC=(!in_mr_bench) & ((vbatt > 5) | in_shutdown) +#MAIN_RELAY_LOGIC=(!in_mr_bench) & ((vbatt > 5) | in_shutdown) +MAIN_RELAY_LOGIC=(!in_mr_bench) & (vbatt > 5) # could be used for simple variable intake geometry setups or warning light or starter block RPM_ABOVE_USER_SETTING_1=rpm > fsio_setting(1)