auto-sync
This commit is contained in:
parent
36598926fd
commit
53b7ad7a83
|
@ -386,7 +386,8 @@ static void showFuelInfo2(float rpm, float engineLoad, Engine *engine) {
|
|||
scheduleMsg(&logger2, "algo=%s/pump=%s", getEngine_load_mode_e(engineConfiguration->algorithm),
|
||||
boolToString(enginePins.fuelPumpRelay.getLogicValue()));
|
||||
|
||||
scheduleMsg(&logger2, "phase=%f", getInjectionAngle(rpm));
|
||||
scheduleMsg(&logger2, "phase=%f correction=%f", getInjectionAngle(rpm),
|
||||
engineConfiguration->globalFuelCorrection);
|
||||
|
||||
#if EFI_ENGINE_CONTROL
|
||||
scheduleMsg(&logger2, "cranking fuel: %f", getCrankingFuel(engine));
|
||||
|
|
|
@ -47,6 +47,10 @@
|
|||
#include "engine.h"
|
||||
#include "algo.h"
|
||||
|
||||
#if HAL_USE_ADC || defined(__DOXYGEN__)
|
||||
#include "AdcConfiguration.h"
|
||||
#endif
|
||||
|
||||
#if EFI_PROD_CODE
|
||||
#include "pwm_generator.h"
|
||||
#include "adc_inputs.h"
|
||||
|
@ -244,8 +248,16 @@ char * getPinNameByAdcChannel(adc_channel_e hwChannel, char *buffer) {
|
|||
|
||||
static char pinNameBuffer[16];
|
||||
|
||||
#if HAL_USE_ADC || defined(__DOXYGEN__)
|
||||
extern AdcDevice fastAdc;
|
||||
#endif
|
||||
|
||||
static void printAnalogChannelInfoExt(const char *name, adc_channel_e hwChannel, float adcVoltage) {
|
||||
#if HAL_USE_ADC || defined(__DOXYGEN__)
|
||||
if(fastAdc.isHwUsed(hwChannel)) {
|
||||
scheduleMsg(&logger, "fast enabled=%s", boolToString(boardConfiguration->isFastAdcEnabled));
|
||||
}
|
||||
|
||||
float voltage = adcVoltage * engineConfiguration->analogInputDividerCoefficient;
|
||||
scheduleMsg(&logger, "%s ADC%d %s %s rawValue=%f/divided=%fv", name, hwChannel, getAdcMode(hwChannel),
|
||||
getPinNameByAdcChannel(hwChannel, pinNameBuffer), adcVoltage, voltage);
|
||||
|
@ -267,9 +279,13 @@ static void printAnalogInfo(void) {
|
|||
if (engineConfiguration->hasIatSensor) {
|
||||
printAnalogChannelInfo("IAT", engineConfiguration->iatAdcChannel);
|
||||
}
|
||||
printAnalogChannelInfo("MAF", engineConfiguration->mafAdcChannel);
|
||||
if (engineConfiguration->hasMafSensor) {
|
||||
printAnalogChannelInfo("MAF", engineConfiguration->mafAdcChannel);
|
||||
}
|
||||
printAnalogChannelInfo("AFR", engineConfiguration->afr.hwChannel);
|
||||
printAnalogChannelInfo("MAP", engineConfiguration->map.sensor.hwChannel);
|
||||
if (engineConfiguration->hasMapSensor) {
|
||||
printAnalogChannelInfo("MAP", engineConfiguration->map.sensor.hwChannel);
|
||||
}
|
||||
if (engineConfiguration->hasBaroSensor) {
|
||||
printAnalogChannelInfo("BARO", engineConfiguration->baroSensor.hwChannel);
|
||||
}
|
||||
|
@ -286,8 +302,8 @@ static void setShort(const int offset, const int value) {
|
|||
if (isOutOfBounds(offset))
|
||||
return;
|
||||
uint16_t *ptr = (uint16_t *) (&((char *) engine->engineConfiguration)[offset]);
|
||||
*ptr = (uint16_t)value;
|
||||
scheduleMsg(&logger, "setting short @%d to %d", offset, (uint16_t)value);
|
||||
*ptr = (uint16_t) value;
|
||||
scheduleMsg(&logger, "setting short @%d to %d", offset, (uint16_t) value);
|
||||
}
|
||||
|
||||
static void getShort(int offset) {
|
||||
|
|
|
@ -41,6 +41,9 @@ static int addMafPoint(engine_configuration_s *e, int i, float kgHrValue, float
|
|||
return i + 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Hot-film air-mass meter, Type HFM 5
|
||||
*/
|
||||
void setBosch0280218037(engine_configuration_s *e) {
|
||||
int i = 0;
|
||||
i = addMafPoint(e, i, -34.5, 0);
|
||||
|
@ -70,12 +73,16 @@ void setBosch0280218004(engine_configuration_s *e) {
|
|||
void setDensoTODO(engine_configuration_s *e) {
|
||||
int i = 0;
|
||||
|
||||
i = addMafPoint(e, i, 0, 3);
|
||||
i = addMafPoint(e, i, 23.8, 1.83);
|
||||
i = addMafPoint(e, i, 32.5, 1.60);
|
||||
i = addMafPoint(e, i, 40.5, 1.4);
|
||||
i = addMafPoint(e, i, 76.3, 1.04);
|
||||
i = addMafPoint(e, i, 116.3, 0.8);
|
||||
i = addMafPoint(e, i, 76.3, 1.04);
|
||||
i = addMafPoint(e, i, 40.5, 1.4);
|
||||
i = addMafPoint(e, i, 32.5, 1.60);
|
||||
i = addMafPoint(e, i, 23.8, 1.83);
|
||||
i = addMafPoint(e, i, 0, 3);
|
||||
|
||||
fillTheRest(e, i);
|
||||
while (i < MAF_DECODING_COUNT) {
|
||||
e->mafDecoding[i] = 0;
|
||||
e->mafDecodingBins[i] = 10 + i;
|
||||
i++;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -209,6 +209,7 @@ void printConfiguration(engine_configuration_s *engineConfiguration) {
|
|||
|
||||
scheduleMsg(&logger, "ignitionMode: %s/enabled=%s", getIgnition_mode_e(engineConfiguration->ignitionMode),
|
||||
boolToString(engineConfiguration->isIgnitionEnabled));
|
||||
scheduleMsg(&logger, "globalTriggerAngleOffset=%f", engineConfiguration->globalTriggerAngleOffset);
|
||||
scheduleMsg(&logger, "timingMode: %d", /*getTiming_mode_etodo*/(engineConfiguration->timingMode));
|
||||
scheduleMsg(&logger, "fixedModeTiming: %d", (int) engineConfiguration->fixedModeTiming);
|
||||
scheduleMsg(&logger, "ignitionOffset=%f", engineConfiguration->ignitionBaseAngle);
|
||||
|
@ -216,6 +217,21 @@ void printConfiguration(engine_configuration_s *engineConfiguration) {
|
|||
(double) engineConfiguration->injectionAngle,
|
||||
boolToString(engineConfiguration->isInjectionEnabled));
|
||||
|
||||
if (engineConfiguration->useConstantDwellDuringCranking) {
|
||||
scheduleMsg(&logger, "ignitionDwellForCrankingMs=%f", engineConfiguration->ignitionDwellForCrankingMs);
|
||||
} else {
|
||||
scheduleMsg(&logger, "cranking charge charge angle=%f fire at %f", engineConfiguration->crankingChargeAngle,
|
||||
engineConfiguration->crankingTimingAngle);
|
||||
}
|
||||
|
||||
// scheduleMsg(&logger, "analogChartMode: %d", engineConfiguration->analogChartMode);
|
||||
|
||||
scheduleMsg(&logger, "crankingRpm: %d", engineConfiguration->cranking.rpm);
|
||||
|
||||
scheduleMsg(&logger, "analogInputDividerCoefficient: %f", engineConfiguration->analogInputDividerCoefficient);
|
||||
|
||||
printOutputs(engineConfiguration);
|
||||
|
||||
scheduleMsg(&logger, "map_avg=%s/mil=%s/fp=%s/ts=%s/wa=%s/it=%s/fastAdc=%s",
|
||||
boolToString(engineConfiguration->isMapAveragingEnabled), boolToString(engineConfiguration->isMilEnabled),
|
||||
boolToString(engineConfiguration->isFuelPumpEnabled),
|
||||
|
@ -227,22 +243,6 @@ void printConfiguration(engine_configuration_s *engineConfiguration) {
|
|||
boolToString(engineConfiguration->isManualSpinningMode),
|
||||
boolToString(engineConfiguration->isCylinderCleanupEnabled));
|
||||
|
||||
if (engineConfiguration->useConstantDwellDuringCranking) {
|
||||
scheduleMsg(&logger, "ignitionDwellForCrankingMs=%f", engineConfiguration->ignitionDwellForCrankingMs);
|
||||
} else {
|
||||
scheduleMsg(&logger, "crankingChargeAngle=%f", engineConfiguration->crankingChargeAngle);
|
||||
scheduleMsg(&logger, "crankingTimingAngle=%f", engineConfiguration->crankingTimingAngle);
|
||||
}
|
||||
scheduleMsg(&logger, "globalTriggerAngleOffset=%f", engineConfiguration->globalTriggerAngleOffset);
|
||||
|
||||
// scheduleMsg(&logger, "analogChartMode: %d", engineConfiguration->analogChartMode);
|
||||
|
||||
scheduleMsg(&logger, "crankingRpm: %d", engineConfiguration->cranking.rpm);
|
||||
|
||||
scheduleMsg(&logger, "analogInputDividerCoefficient: %f", engineConfiguration->analogInputDividerCoefficient);
|
||||
|
||||
printOutputs(engineConfiguration);
|
||||
|
||||
scheduleMsg(&logger, "clutchUp@%s: %s", hwPortname(engineConfiguration->clutchUpPin), boolToString(engine->clutchUpState));
|
||||
scheduleMsg(&logger, "clutchDown@%s: %s", hwPortname(boardConfiguration->clutchDownPin), boolToString(engine->clutchDownState));
|
||||
|
||||
|
|
|
@ -22,6 +22,7 @@ public enum Sensor {
|
|||
IAT("Intake Air", SensorCategory.SENSOR_INPUTS, "temperature, C", -40, 150),
|
||||
AFR("A/F ratio", SensorCategory.SENSOR_INPUTS, "", 0, 20),
|
||||
MAF("MAF", SensorCategory.SENSOR_INPUTS, "Volts", 4),
|
||||
MAFR("MAFR", SensorCategory.SENSOR_INPUTS, "kg/hr", 4),
|
||||
TPS("throttle", SensorCategory.SENSOR_INPUTS, "%", 100),
|
||||
VSS("Speed", SensorCategory.SENSOR_INPUTS, "kph", 100),
|
||||
|
||||
|
|
|
@ -116,6 +116,7 @@ public class SensorCentral {
|
|||
addDoubleSensor(Sensor.VREF, es);
|
||||
addDoubleSensor(Sensor.VBATT, es);
|
||||
addDoubleSensor(Sensor.MAF, es);
|
||||
addDoubleSensor(Sensor.MAFR, es);
|
||||
addDoubleSensor("period0", Sensor.PERIOD0, es);
|
||||
addDoubleSensor("period1", Sensor.PERIOD0, es);
|
||||
addDoubleSensor("duty0", Sensor.DUTY0, es);
|
||||
|
|
|
@ -23,7 +23,7 @@ import static com.rusefi.ui.storage.PersistentConfiguration.getConfig;
|
|||
* @see WavePanel
|
||||
*/
|
||||
public class Launcher extends FrameHelper {
|
||||
public static final int CONSOLE_VERSION = 20150212;
|
||||
public static final int CONSOLE_VERSION = 20150214;
|
||||
public static final boolean SHOW_STIMULATOR = true;
|
||||
public static final String TAB_INDEX = "main_tab";
|
||||
private final String port;
|
||||
|
|
|
@ -84,7 +84,7 @@ void rusEfiFunctionalTest(void) {
|
|||
|
||||
// todo: reduce code duplication with initEngineContoller
|
||||
|
||||
resetConfigurationExt(NULL, FORD_ASPIRE_1996, engine);
|
||||
resetConfigurationExt(NULL, FORD_ESCORT_GT, engine);
|
||||
prepareShapes(engine);
|
||||
|
||||
initSensors(PASS_ENGINE_PARAMETER_F);
|
||||
|
|
Loading…
Reference in New Issue