start/stop progress

This commit is contained in:
rusefi 2020-03-29 17:21:17 -04:00
parent 51769df47c
commit 06da8fe3fa
3 changed files with 17 additions and 3 deletions

View File

@ -151,6 +151,10 @@ void milBench(void) {
pinbench("0", "500", "500", "16", &enginePins.checkEnginePin, CONFIG(malfunctionIndicatorPin));
}
void starterRelayBench(void) {
pinbench("0", "6000", "100", "1", &enginePins.starterControl, CONFIG(starterControlPin));
}
void fuelPumpBenchExt(const char *durationMs) {
pinbench("0", durationMs, "100", "1", &enginePins.fuelPumpRelay, CONFIG(fuelPumpPin));
}
@ -246,12 +250,15 @@ static void handleCommandX14(uint16_t index) {
case 9:
acRelayBench();
return;
case 10:
case 0xA:
// cmd_write_config
#if EFI_PROD_CODE
writeToFlashNow();
#endif /* EFI_PROD_CODE */
return;
case 0xB:
starterRelayBench();
return;
}
@ -286,6 +293,7 @@ void executeTSCommand(uint16_t subsystem, uint16_t index) {
} else if (subsystem == 0x20 && index == 0x3456) {
// call to pit
setCallFromPitStop(30000);
} else if (subsystem == 0x21) {
} else if (subsystem == 0x30) {
setEngineType(index);
} else if (subsystem == 0x31) {
@ -313,6 +321,7 @@ void initBenchTest(Logging *sharedLogger) {
addConsoleActionS("fanbench2", fanBenchExt);
addConsoleAction("dizzybench", dizzyBench); // this is useful for tach output testing
addConsoleAction("starterbench", starterRelayBench);
addConsoleAction("milbench", milBench);
addConsoleActionSSS("fuelbench", fuelbench);
addConsoleActionSSS("sparkbench", sparkbench);

View File

@ -12,11 +12,14 @@
#include "global.h"
void initBenchTest(Logging *sharedLogger);
bool isRunningBenchTest(void);
void fanBench(void);
void fuelPumpBench(void);
void acRelayBench(void);
void milBench(void);
void initBenchTest(Logging *sharedLogger);
bool isRunningBenchTest(void);
void starterRelayBench(void);
void executeTSCommand(uint16_t subsystem, uint16_t index);

View File

@ -1410,6 +1410,7 @@ cmd_calibrate_pedal_down = "w\x00\x14\x00\x07"
cmd_tle8888_init = "w\x00\x14\x00\x08"
cmd_test_ac_relay = "w\x00\x14\x00\x09"
cmd_write_config = "w\x00\x14\x00\x0A"
cmd_test_starter_relay = "w\x00\x14\x00\x0B"
cmd_test_radiator_fan = "w\x00\x15\x00\x01"
cmd_test_check_engine_light = "w\x00\x16\x00\x01"
@ -2725,6 +2726,7 @@ cmd_set_engine_type_default = "w\x00\x31\x00\x00"
commandButton = "Check Engine", cmd_test_check_engine_light
commandButton = "Idle Air Valve", cmd_test_idle_valve
commandButton = "A/C Relay", cmd_test_ac_relay
commandButton = "Starter Relay", cmd_test_starter_relay
commandButton = "Stop Engine", cmd_stop_engine
commandButton = "Write Config", cmd_write_config
commandButton = "Reset ECU", cmd_reset_controller