idle bench test from TS

This commit is contained in:
rusefi 2019-01-13 19:41:39 -05:00
parent b3c2bf7a1d
commit acc4b2f384
6 changed files with 19 additions and 8 deletions

View File

@ -774,7 +774,7 @@ int tunerStudioHandleCrcCommand(ts_channel_s *tsChannel, char *data, int incomin
}
#if EFI_PROD_CODE || defined(__DOXYGEN__)
runIoTest(subsystem, index);
runBenchTest(subsystem, index);
#endif /* EFI_PROD_CODE */
sendOkResponse(tsChannel, TS_CRC);
} else {

View File

@ -429,6 +429,9 @@ void onConfigurationChangeIdleCallback(engine_configuration_s *previousConfigura
idleSolenoid.setFrequency(CONFIGB(idle).solenoidFrequency);
}
/**
* Idle test would activate the solenoid for three seconds
*/
void startIdleBench(void) {
timeToStopIdleTest = getTimeNowUs() + MS2US(3000); // 3 seconds
scheduleMsg(logger, "idle valve bench test");

View File

@ -33,6 +33,7 @@
#include "pin_repository.h"
#include "efiGpio.h"
#include "settings.h"
#include "idle_thread.h"
EXTERN_ENGINE
;
@ -161,6 +162,9 @@ void fanBench(void) {
fanBenchExt("3000");
}
/**
* we are blinking for 16 seconds so that one can click the button and walk around to see the light blinking
*/
void milBench(void) {
pinbench("0", "500", "500", "16", &enginePins.checkEnginePin, CONFIGB(malfunctionIndicatorPin));
}
@ -240,7 +244,7 @@ void OutputPin::unregisterOutput(brain_pin_e oldPin, brain_pin_e newPin) {
}
}
void runIoTest(int subsystem, int index) {
void runBenchTest(int subsystem, int index) {
scheduleMsg(logger, "IO test subsystem=%d index=%d", subsystem, index);
if (subsystem == 0x12) {
@ -248,12 +252,16 @@ void runIoTest(int subsystem, int index) {
} else if (subsystem == 0x13) {
doRunFuel(index, "300", "4", "400", "3");
} else if (subsystem == 0x14) {
// cmd_test_fuel_pump
fuelPumpBench();
} else if (subsystem == 0x15) {
fanBench();
} else if (subsystem == 0x16) {
// cmd_test_check_engine_light
milBench();
} else if (subsystem == 0x17) {
// cmd_test_idle_valve
startIdleBench();
} else if (subsystem == 0x20 && index == 0x3456) {
// call to pit
setCallFromPitStop(30000);

View File

@ -20,6 +20,6 @@ void milBench(void);
void initInjectorCentral(Logging *sharedLogger);
bool isRunningBenchTest(void);
void runIoTest(int subsystem, int index);
void runBenchTest(int subsystem, int index);
#endif /* INJECTOR_CENTRAL_H_ */

View File

@ -63,7 +63,7 @@ enable2ndByteCanID = false
; see PAGE_0_SIZE in C source code
; CONFIG_DEFINITION_START
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Thu Jan 10 17:03:36 EST 2019
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sun Jan 13 19:36:29 EST 2019
pageSize = 20000
page = 1
@ -1982,7 +1982,7 @@ menuDialog = main
subMenu = monitoringSettings, "rusEfi Console Settings"
subMenu = std_separator
subMenu = connection, "Connection"
subMenu = ioTest, "I-O Test"
subMenu = ioTest, "Bench Test"
subMenu = allPins, "Full pinout"
[ControllerCommands]
@ -3071,7 +3071,7 @@ cmd_stop_engine = "w\x00\x99\x00\x00"
commandButton = "Stop Engine", cmd_stop_engine
; bench test
dialog = ioTest, "I-O Test", border
dialog = ioTest, "Bench Test", border
panel = testSpark, West
panel = testInjectors, Center
panel = testMisc, East

View File

@ -1126,7 +1126,7 @@ menuDialog = main
subMenu = monitoringSettings, "rusEfi Console Settings"
subMenu = std_separator
subMenu = connection, "Connection"
subMenu = ioTest, "I-O Test"
subMenu = ioTest, "Bench Test"
subMenu = allPins, "Full pinout"
[ControllerCommands]
@ -2215,7 +2215,7 @@ cmd_stop_engine = "w\x00\x99\x00\x00"
commandButton = "Stop Engine", cmd_stop_engine
; bench test
dialog = ioTest, "I-O Test", border
dialog = ioTest, "Bench Test", border
panel = testSpark, West
panel = testInjectors, Center
panel = testMisc, East