only:uaefi
This commit is contained in:
parent
fef0f99776
commit
ab2e5ac18e
|
@ -4,7 +4,7 @@
|
|||
BOARDCPPSRC = $(BOARD_DIR)/board_configuration.cpp
|
||||
# Set this if you want a default engine type other than normal
|
||||
ifeq ($(VAR_DEF_ENGINE_TYPE),)
|
||||
# VAR_DEF_ENGINE_TYPE = -DDEFAULT_ENGINE_TYPE=engine_type_e::HELLEN_154_HYUNDAI_COUPE_BK2
|
||||
# VAR_DEF_ENGINE_TYPE = -DDEFAULT_ENGINE_TYPE=engine_type_e::
|
||||
endif
|
||||
|
||||
DDEFS += -DEFI_MAIN_RELAY_CONTROL=TRUE
|
||||
|
@ -13,7 +13,7 @@ DDEFS += -DEFI_MAIN_RELAY_CONTROL=TRUE
|
|||
|
||||
# Add them all together
|
||||
DDEFS += -DFIRMWARE_ID=\"uaefi\" $(VAR_DEF_ENGINE_TYPE)
|
||||
#DDEFS += -DEFI_SOFTWARE_KNOCK=TRUE -DSTM32_ADC_USE_ADC3=TRUE
|
||||
DDEFS += -DEFI_SOFTWARE_KNOCK=TRUE -DSTM32_ADC_USE_ADC3=TRUE
|
||||
|
||||
SHORT_BOARD_NAME=uaefi
|
||||
|
||||
|
|
|
@ -28,15 +28,12 @@ static void setupDefaultSensorInputs() {
|
|||
engineConfiguration->vehicleSpeedSensorInputPin = Gpio::MM100_IN_D2;
|
||||
|
||||
engineConfiguration->tps1_1AdcChannel = MM100_IN_TPS_ANALOG;
|
||||
engineConfiguration->tps1_2AdcChannel = MM100_IN_O2S_ANALOG;
|
||||
engineConfiguration->tps1_2AdcChannel = MM100_IN_AUX1_ANALOG;
|
||||
|
||||
setPPSInputs(MM100_IN_PPS_ANALOG, MM100_IN_AUX2_ANALOG);
|
||||
|
||||
engineConfiguration->mafAdcChannel = EFI_ADC_NONE;
|
||||
engineConfiguration->map.sensor.hwChannel = H144_IN_MAP1;
|
||||
|
||||
// engineConfiguration->afr.hwChannel = EFI_ADC_NONE;
|
||||
|
||||
engineConfiguration->clt.adcChannel = MM100_IN_CLT_ANALOG;
|
||||
|
||||
engineConfiguration->iat.adcChannel = MM100_IN_IAT_ANALOG;
|
||||
|
@ -45,7 +42,6 @@ static void setupDefaultSensorInputs() {
|
|||
#include "hellen_leds_100.cpp"
|
||||
|
||||
void setBoardConfigOverrides() {
|
||||
// rev A needs EN pin but newer revisions would potentially not use it
|
||||
setHellenMegaEnPin();
|
||||
setHellenVbatt();
|
||||
|
||||
|
@ -60,13 +56,18 @@ void setBoardConfigOverrides() {
|
|||
engineConfiguration->triggerInputPins[0] = Gpio::MM100_IN_CRANK;
|
||||
engineConfiguration->camInputs[0] = Gpio::MM100_IN_D1;
|
||||
|
||||
//ETB1
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::MM100_OUT_PWM6;
|
||||
engineConfiguration->etbIo[0].controlPin = Gpio::MM100_OUT_PWM3;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::MM100_SPI2_MISO;
|
||||
engineConfiguration->etbIo[0].directionPin1 = Gpio::MM100_OUT_PWM4;
|
||||
// Disable pin
|
||||
engineConfiguration->etbIo[0].disablePin = Gpio::MM100_SPI2_MOSI;
|
||||
engineConfiguration->etbIo[0].disablePin = Gpio::MM100_SPI2_MISO;
|
||||
// PWM pin
|
||||
engineConfiguration->etbIo[1].controlPin = Gpio::MM100_OUT_PWM5;
|
||||
// DIR pin
|
||||
engineConfiguration->etbIo[1].directionPin1 = Gpio::MM100_SPI2_MOSI;
|
||||
// Disable pin
|
||||
engineConfiguration->etbIo[1].disablePin = Gpio::MM100_USB1ID;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -92,19 +93,15 @@ void setBoardDefaultConfiguration() {
|
|||
engineConfiguration->canTxPin = Gpio::MM100_CAN_TX;
|
||||
engineConfiguration->canRxPin = Gpio::MM100_CAN_RX;
|
||||
|
||||
engineConfiguration->fuelPumpPin = Gpio::MM100_OUT_PWM5;
|
||||
// engineConfiguration->fuelPumpPin = Gpio::MM100_OUT_PWM5;
|
||||
// engineConfiguration->idle.solenoidPin = Gpio::H144_LS_6;
|
||||
// engineConfiguration->fanPin = Gpio::H144_OUT_IO12;
|
||||
engineConfiguration->mainRelayPin = Gpio::MM100_IGN8;
|
||||
// engineConfiguration->mainRelayPin = Gpio::MM100_IGN8;
|
||||
// engineConfiguration->malfunctionIndicatorPin = Gpio::H144_OUT_IO7;
|
||||
|
||||
// how come this is not denso 183?!
|
||||
setCustomMap(/*lowValue*/ 11.4, /*mapLowValueVoltage*/ 0.5, /*highValue*/ 170.7, 4.8);
|
||||
|
||||
// engineConfiguration->brakePedalPin = Gpio::H144_IN_CAM;
|
||||
// engineConfiguration->acRelayPin = Gpio::H144_LS_5;
|
||||
// engineConfiguration->tachOutputPin = Gpio::H144_OUT_IO10;
|
||||
// A/C switch on k-line
|
||||
|
||||
// "required" hardware is done - set some reasonable defaults
|
||||
setupDefaultSensorInputs();
|
||||
|
@ -126,16 +123,30 @@ void setBoardDefaultConfiguration() {
|
|||
//hellenWbo();
|
||||
}
|
||||
|
||||
//static Gpio OUTPUTS[] = {
|
||||
//};
|
||||
static Gpio OUTPUTS[] = {
|
||||
Gpio::MM100_INJ6, // B1 injector output 6
|
||||
Gpio::MM100_INJ5, // B2 injector output 5
|
||||
Gpio::MM100_INJ4, // B3 injector output 4
|
||||
Gpio::MM100_INJ3, // B4 injector output 3
|
||||
Gpio::MM100_INJ2, // B5 injector output 2
|
||||
Gpio::MM100_INJ1, // B6 injector output 1
|
||||
Gpio::MM100_INJ7, // B7 Low Side output 1
|
||||
Gpio::MM100_IGN8, // B8 Weak Low Side output 2
|
||||
Gpio::MM100_IGN7, // B9 Weak Low Side output 1
|
||||
Gpio::MM100_OUT_PWM2, // B16 Low Side output 4
|
||||
Gpio::MM100_OUT_PWM1, // B17 Low Side output 3
|
||||
Gpio::MM100_INJ8, // B18 Low Side output 2
|
||||
Gpio::MM100_IGN6, // B10 Coil 6
|
||||
Gpio::MM100_IGN4, // B11 Coil 4
|
||||
};
|
||||
|
||||
//int getBoardMetaOutputsCount() {
|
||||
// return efi::size(OUTPUTS);
|
||||
//}
|
||||
int getBoardMetaOutputsCount() {
|
||||
return efi::size(OUTPUTS);
|
||||
}
|
||||
|
||||
//Gpio* getBoardMetaOutputs() {
|
||||
// return OUTPUTS;
|
||||
//}
|
||||
Gpio* getBoardMetaOutputs() {
|
||||
return OUTPUTS;
|
||||
}
|
||||
|
||||
int getBoardMetaDcOutputsCount() {
|
||||
return 2;
|
||||
|
|
Loading…
Reference in New Issue