trigger signal debug pins - logic level output #2959
This commit is contained in:
parent
7b6f7c9d75
commit
5914ea6bd5
|
@ -7,11 +7,13 @@
|
|||
*/
|
||||
|
||||
#include "global.h"
|
||||
#include "engine_configuration.h"
|
||||
#include "engine_math.h"
|
||||
|
||||
#if !EFI_UNIT_TEST
|
||||
#include "os_access.h"
|
||||
#include "settings.h"
|
||||
#include "eficonsole.h"
|
||||
#include "engine_configuration.h"
|
||||
#include "adc_inputs.h"
|
||||
#include "engine_controller.h"
|
||||
#include "thermistors.h"
|
||||
|
@ -22,7 +24,6 @@
|
|||
#include "console_io.h"
|
||||
#include "engine.h"
|
||||
#include "efi_gpio.h"
|
||||
#include "engine_math.h"
|
||||
#include "idle_thread.h"
|
||||
#include "allsensors.h"
|
||||
#include "alternator_controller.h"
|
||||
|
@ -183,22 +184,6 @@ static void setTimingMode(int value) {
|
|||
incrementGlobalConfigurationVersion(PASS_ENGINE_PARAMETER_SIGNATURE);
|
||||
}
|
||||
|
||||
void setEngineType(int value DECLARE_ENGINE_PARAMETER_SUFFIX) {
|
||||
{
|
||||
chibios_rt::CriticalSectionLocker csl;
|
||||
|
||||
engineConfiguration->engineType = (engine_type_e)value;
|
||||
resetConfigurationExt((engine_type_e)value PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
engine->resetEngineSnifferIfInTestMode();
|
||||
|
||||
#if EFI_INTERNAL_FLASH
|
||||
writeToFlashNow();
|
||||
#endif /* EFI_INTERNAL_FLASH */
|
||||
}
|
||||
incrementGlobalConfigurationVersion(PASS_ENGINE_PARAMETER_SIGNATURE);
|
||||
doPrintConfiguration();
|
||||
}
|
||||
|
||||
static void setIdleSolenoidFrequency(int value) {
|
||||
engineConfiguration->idle.solenoidFrequency = value;
|
||||
incrementGlobalConfigurationVersion(PASS_ENGINE_PARAMETER_SIGNATURE);
|
||||
|
@ -1372,3 +1357,23 @@ const char* getConfigurationName(engine_type_e engineType) {
|
|||
return getEngine_type_e(engineType);
|
||||
}
|
||||
}
|
||||
|
||||
void setEngineType(int value DECLARE_ENGINE_PARAMETER_SUFFIX) {
|
||||
{
|
||||
#if EFI_PROD_CODE
|
||||
chibios_rt::CriticalSectionLocker csl;
|
||||
#endif /* EFI_PROD_CODE */
|
||||
|
||||
engineConfiguration->engineType = (engine_type_e)value;
|
||||
resetConfigurationExt((engine_type_e)value PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
engine->resetEngineSnifferIfInTestMode();
|
||||
|
||||
#if EFI_INTERNAL_FLASH
|
||||
writeToFlashNow();
|
||||
#endif /* EFI_INTERNAL_FLASH */
|
||||
}
|
||||
incrementGlobalConfigurationVersion(PASS_ENGINE_PARAMETER_SIGNATURE);
|
||||
#if ! EFI_UNIT_TEST
|
||||
doPrintConfiguration();
|
||||
#endif /* EFI_UNIT_TEST */
|
||||
}
|
||||
|
|
|
@ -6,9 +6,11 @@
|
|||
*/
|
||||
|
||||
#include "engine_test_helper.h"
|
||||
#include "settings.h"
|
||||
|
||||
TEST(misc, changeEngineType) {
|
||||
WITH_ENGINE_TEST_HELPER (FORD_ASPIRE_1996);
|
||||
|
||||
setEngineType((int)CITROEN_TU3JP PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue