AlphaX few bytes of progress
This commit is contained in:
parent
c58a2f5ecb
commit
0d8e4d5222
|
@ -15,6 +15,10 @@
|
|||
#include "custom_engine.h"
|
||||
#include "hellen_meta.h"
|
||||
|
||||
static OutputPin alphaEn;
|
||||
static OutputPin alphaTachPullUp;
|
||||
static OutputPin alphaTempPullUp;
|
||||
|
||||
static void setInjectorPins() {
|
||||
engineConfiguration->injectionPins[0] = H144_LS_1;
|
||||
engineConfiguration->injectionPins[1] = H144_LS_2;
|
||||
|
@ -85,6 +89,13 @@ static void setupDefaultSensorInputs() {
|
|||
engineConfiguration->auxTempSensor2.adcChannel = EFI_ADC_NONE;
|
||||
}
|
||||
|
||||
void boardInitHardware() {
|
||||
alphaEn.initPin("a-EN", H144_OUT_IO3);
|
||||
alphaEn.setValue(1);
|
||||
|
||||
alphaTachPullUp.initPin("a-tach", H144_OUT_IO1);
|
||||
}
|
||||
|
||||
void setBoardConfigOverrides(void) {
|
||||
setHellen144LedPins();
|
||||
setupVbatt();
|
||||
|
|
|
@ -157,6 +157,9 @@ void onBurnRequest() {
|
|||
incrementGlobalConfigurationVersion();
|
||||
}
|
||||
|
||||
// Weak link a stub so that every board doesn't have to implement this function
|
||||
__attribute__((weak)) void boardOnConfigurationChange(engine_configuration_s *previousConfiguration) { }
|
||||
|
||||
/**
|
||||
* this is the top-level method which should be called in case of any changes to engine configuration
|
||||
* online tuning of most values in the maps does not count as configuration change, but 'Burn' command does
|
||||
|
@ -172,6 +175,8 @@ void incrementGlobalConfigurationVersion() {
|
|||
|
||||
applyNewHardwareSettings();
|
||||
|
||||
boardOnConfigurationChange(&activeConfiguration);
|
||||
|
||||
/**
|
||||
* All these callbacks could be implemented as listeners, but these days I am saving RAM
|
||||
*/
|
||||
|
|
|
@ -469,6 +469,9 @@ void startHardware() {
|
|||
#endif /* EFI_CAN_SUPPORT */
|
||||
}
|
||||
|
||||
// Weak link a stub so that every board doesn't have to implement this function
|
||||
__attribute__((weak)) void boardInitHardware() { }
|
||||
|
||||
void initHardware() {
|
||||
#if HAL_USE_PAL && EFI_PROD_CODE
|
||||
efiExtiInit();
|
||||
|
|
Loading…
Reference in New Issue