better constant name

This commit is contained in:
rusefi 2017-08-06 19:43:01 -04:00
parent c0750fcf2e
commit 3f42eddd64
8 changed files with 17 additions and 14 deletions

View File

@ -310,7 +310,7 @@ static void printSensors(Logging *log, bool fileFormat) {
// debugFloat(&logger, "tch", getTCharge1(tps), 2);
for (int i = 0;i<FSIO_ADC_COUNT;i++) {
for (int i = 0;i<FSIO_ANALOG_INPUT_COUNT;i++) {
if (engineConfiguration->fsioAdc[i] != EFI_ADC_NONE) {
strcpy(buf, "adcX");
buf[3] = '0' + i;

View File

@ -258,7 +258,7 @@ static void setDefaultFsioParameters(engine_configuration_s *engineConfiguration
boardConfiguration->fsioDigitalInputs[i] = GPIO_UNASSIGNED;
engineConfiguration->fsioInputModes[i] = PI_DEFAULT;
}
for (int i = 0; i < FSIO_ADC_COUNT ; i++) {
for (int i = 0; i < FSIO_ANALOG_INPUT_COUNT ; i++) {
engineConfiguration->fsioAdc[i] = EFI_ADC_NONE;
}
}

View File

@ -1,4 +1,4 @@
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sat Aug 05 16:55:15 EDT 2017
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sun Aug 06 19:42:16 EDT 2017
// begin
#ifndef ENGINE_CONFIGURATION_GENERATED_H_
#define ENGINE_CONFIGURATION_GENERATED_H_
@ -646,6 +646,7 @@ typedef struct {
*/
spi_device_e max31855spiDevice;
/**
* todo: rename to fsioOutputPins
* offset 444
*/
brain_pin_e fsioPins[FSIO_COMMAND_COUNT];
@ -797,6 +798,7 @@ typedef struct {
*/
pin_input_mode_e clutchUpPinMode;
/**
* todo:not finshed
* These input pins allow us to pull toggle buttons state
* offset 796
*/
@ -1702,9 +1704,10 @@ typedef struct {
*/
pin_output_mode_e dizzySparkOutputPinMode;
/**
* todo: rename to fsioAnalogInputs
* offset 2376
*/
adc_channel_e fsioAdc[FSIO_ADC_COUNT];
adc_channel_e fsioAdc[FSIO_ANALOG_INPUT_COUNT];
/**
* Fixed timing, useful for TDC testing
* offset 2392
@ -2142,4 +2145,4 @@ typedef struct {
#endif
// end
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sat Aug 05 16:55:15 EDT 2017
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sun Aug 06 19:42:16 EDT 2017

View File

@ -15,7 +15,7 @@
#define ignitionPin12logic
#define LE_COMMAND_LENGTH 200
#define BLOCKING_FACTOR 400
#define FSIO_ADC_COUNT 4
#define FSIO_ANALOG_INPUT_COUNT 4
#define TS_OUTPUT_SIZE 356
#define TS_FILE_VERSION 20161225
#define WARMUP_TARGET_AFR_SIZE 4

View File

@ -354,7 +354,7 @@ static void printAnalogInfo(void) {
if (hasMafSensor()) {
printAnalogChannelInfo("MAF", engineConfiguration->mafAdcChannel);
}
for (int i = 0; i < FSIO_ADC_COUNT ; i++) {
for (int i = 0; i < FSIO_ANALOG_INPUT_COUNT ; i++) {
adc_channel_e ch = engineConfiguration->fsioAdc[i];
if (ch != EFI_ADC_NONE) {
printAnalogChannelInfo("fsio", ch);

View File

@ -605,7 +605,7 @@ static void configureInputs(void) {
addChannel("AFR", engineConfiguration->afr.hwChannel, ADC_SLOW);
addChannel("AC", engineConfiguration->acSwitchAdc, ADC_SLOW);
for (int i = 0; i < FSIO_ADC_COUNT ; i++) {
for (int i = 0; i < FSIO_ANALOG_INPUT_COUNT ; i++) {
addChannel("FSIOadc", engineConfiguration->fsioAdc[i], ADC_SLOW);
}
}

View File

@ -33,7 +33,7 @@ struct_no_prefix engine_configuration_s
! see 'blockingFactor' in rusefi.ini
#define BLOCKING_FACTOR 400
#define FSIO_ADC_COUNT 4
#define FSIO_ANALOG_INPUT_COUNT 4
! this is here so that rusEfi console can access it, too
#define TS_OUTPUT_SIZE 356
@ -523,7 +523,7 @@ bit is_enabled_spi_2
spi_device_e max31855spiDevice;
brain_pin_e[FSIO_COMMAND_COUNT iterate] fsioPins;
brain_pin_e[FSIO_COMMAND_COUNT iterate] fsioPins;todo: rename to fsioOutputPins
pin_output_mode_e[FSIO_COMMAND_COUNT iterate] gpioPinModes;
custom uart_device_e 4 bits,U32, @OFFSET@, [0:1], "Off", "UART1", "UART2", "UART3"
@ -580,7 +580,7 @@ brain_input_pin_e vehicleSpeedSensorInputPin;
brain_pin_e clutchUpPin;Some vehicles have a switch to indicate that clutch pedal is all the way up
pin_input_mode_e clutchUpPinMode;
brain_pin_e[FSIO_COMMAND_COUNT iterate] fsioDigitalInputs;These input pins allow us to pull toggle buttons state;
brain_pin_e[FSIO_COMMAND_COUNT iterate] fsioDigitalInputs;todo:not finshed\nThese input pins allow us to pull toggle buttons state;
brain_input_pin_e frequencyReportingMapInputPin;
@ -759,7 +759,7 @@ float[MAP_ACCEL_TAPER] mapAccelTaperMult;;"mult", 1, 0, 0.0, 300,
brain_pin_e dizzySparkOutputPin;+This implementation makes a pulse every time one of the coils is charged. See also tachOutputPin
pin_output_mode_e dizzySparkOutputPinMode;
adc_channel_e[FSIO_ADC_COUNT iterate] fsioAdc;
adc_channel_e[FSIO_ANALOG_INPUT_COUNT iterate] fsioAdc;todo: rename to fsioAnalogInputs
float fixedTiming;Fixed timing, useful for TDC testing;"deg", 1, 0, -720, 720, 2
float mapLowValueVoltage;MAP voltage for low point;"v", 1, 0, 0.0, 10, 2
float mapHighValueVoltage;MAP voltage for low point;"v", 1, 0, 0.0, 10, 2

View File

@ -1,10 +1,10 @@
package com.rusefi.config;
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Wed Aug 02 07:34:07 EDT 2017
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sun Aug 06 19:42:16 EDT 2017
public class Fields {
public static final int LE_COMMAND_LENGTH = 200;
public static final int BLOCKING_FACTOR = 400;
public static final int FSIO_ADC_COUNT = 4;
public static final int FSIO_ANALOG_INPUT_COUNT = 4;
public static final int TS_OUTPUT_SIZE = 356;
public static final int TS_FILE_VERSION = 20161225;
public static final int WARMUP_TARGET_AFR_SIZE = 4;