h-bridge dialog is disabled in TS when it should be enabled

This commit is contained in:
rusefillc 2021-09-26 18:32:15 -04:00
parent 2aa836857e
commit f458279a35
2 changed files with 4 additions and 3 deletions

View File

@ -215,6 +215,7 @@ struct_no_prefix engine_configuration_s
#define MAP_ACCEL_TAPER 8
#define ADC_CHANNEL_NONE 0
#define ETB_FUNCTION_NONE 0
#define DC_FUNCTION_IDLE 3
#define BARO_CORR_SIZE 4

View File

@ -2642,7 +2642,7 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
field = "Force parking every restart", stepperForceParkingEveryRestart, useStepperIdle
panel = idleStepperHw, { useStepperIdle && !useHbridgesToDriveIdleStepper }
; todo: reminder that enable condition has to match in both usages of hbridgeHardware due to TS defect?
panel = hbridgeHardware, { etbFunctions1 != ETB_FUNCTION_NONE || etbFunctions2 = ETB_FUNCTION_NONE || (useStepperIdle && useHbridgesToDriveIdleStepper) }
panel = hbridgeHardware, { etbFunctions1 != @@ETB_FUNCTION_NONE@@ || etbFunctions2 = @@ETB_FUNCTION_NONE@@ || (useStepperIdle && useHbridgesToDriveIdleStepper) }
dialog = idleHwType, "Idle Valve Hardware", border
panel = idleSolenoid, West
@ -3388,7 +3388,7 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
; criteria for the same panel when used in multiple places
; todo: report bug to TS?
; another todo: split panel into two panels so that we can enable/disable h-bridge #1 separately from h-bridge #2
panel = hbridgeHardware, { etbFunctions1 != ETB_FUNCTION_NONE || etbFunctions2 = ETB_FUNCTION_NONE || (useStepperIdle && useHbridgesToDriveIdleStepper) }
panel = hbridgeHardware, { etbFunctions1 != @@ETB_FUNCTION_NONE@@ || etbFunctions2 = @@ETB_FUNCTION_NONE@@ || (useStepperIdle && useHbridgesToDriveIdleStepper) }
dialog = etbAutotune, "PID Autotune"
field = "First step: calibrate TPS and hit 'Burn'"
@ -3404,7 +3404,7 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
dialog = etbDialogRight
panel = etbIdleDialog, { throttlePedalPositionAdcChannel != @@ADC_CHANNEL_NONE@@ }
panel = etbPidDialog, { (throttlePedalPositionAdcChannel != @@ADC_CHANNEL_NONE@@) }
panel = etbPidDialog, { (throttlePedalPositionAdcChannel != @@ADC_CHANNEL_NONE@@) || (etbFunctions1 == @@DC_FUNCTION_IDLE@@) }
panel = etbAutotune
; Neutral position handling not yet implemented!