auto-sync

This commit is contained in:
rusEfi 2015-12-21 20:02:32 -05:00
parent 41eaede440
commit 2067b4c3c0
13 changed files with 34 additions and 14 deletions

View File

@ -14,6 +14,7 @@
*/
#include "chevrolet_c20_1973.h"
#include "engine_math.h"
EXTERN_ENGINE;
@ -36,6 +37,8 @@ void set1973c20(DECLARE_ENGINE_PARAMETER_F) {
engineConfiguration->trigger.customTotalToothCount = 8;
engineConfiguration->trigger.customSkippedToothCount = 0;
engineConfiguration->rpmHardLimit = 5000;
setAlgorithm(LM_SPEED_DENSITY PASS_ENGINE_PARAMETER);
}

View File

@ -42,6 +42,8 @@
//#define SERIAL_SPEED (8 * 115200)
//#define SERIAL_SPEED (2 * 115200)
//todo: make this configurable via Tuner Studio
//todo: see uartConsoleSerialSpeed
#define SERIAL_SPEED 115200
/**

View File

@ -16,6 +16,7 @@ typedef void (*CommandHandler)(char *);
#include "efifeatures.h"
#include "datalogging.h"
// todo: make this pin configurable
#define GET_CONSOLE_MODE_VALUE() palReadPad(CONSOLE_MODE_SWITCH_PORT, CONSOLE_MODE_SWITCH_PIN)
#define SHOULD_INGORE_FLASH() (palReadPad(CONFIG_RESET_SWITCH_PORT, CONFIG_RESET_SWITCH_PIN) == 0)

View File

@ -48,11 +48,12 @@ private:
};
/**
* this part of the structure is separate just because so far
* these fields are not integrated with Tuner Studio. Step by step :)
* This structure is still separate from Engine simply because this goes into CCM memory and Engine is in main memory
* todo: re-arrange global variables to put something else into CCM so that this can go into main
* so that this could be mergeed into Engine
* todo: move these fields into Engine class, eliminate this class
*/
class engine_configuration2_s {
// todo: move these fields into Engine class, eliminate this class
public:
engine_configuration2_s();

View File

@ -248,6 +248,9 @@ void setDefaultBasePins(DECLARE_ENGINE_PARAMETER_F) {
* * flash version of configuration failed CRC check or appears to be older then FLASH_DATA_VERSION
* * 'rewriteconfig' command
* * 'set_engine_type X' command
*
* This method should only change the state of the configuration data structure but should NOT change the state of
* anything else.
*/
void setDefaultConfiguration(DECLARE_ENGINE_PARAMETER_F) {
#if (! EFI_UNIT_TEST) || defined(__DOXYGEN__)
@ -657,6 +660,8 @@ void setDefaultConfiguration(DECLARE_ENGINE_PARAMETER_F) {
boardConfiguration->isVerboseAlternator = false;
boardConfiguration->tunerStudioSerialSpeed = TS_DEFAULT_SPEED;
engineConfiguration->uartConsoleSerialSpeed = 115200;
engineConfiguration->mapAccelLength = 6;
engineConfiguration->mapAccelEnrichmentThreshold = 5; // kPa

View File

@ -1,4 +1,4 @@
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Tue Dec 08 10:02:06 EST 2015
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon Dec 21 19:26:52 EST 2015
// begin
#include "rusefi_types.h"
typedef struct {
@ -1443,7 +1443,11 @@ typedef struct {
/**
* offset 2228
*/
int unused[197];
uint32_t uartConsoleSerialSpeed;
/**
* offset 2232
*/
int unused[196];
/** total size 3016*/
} engine_configuration_s;
@ -1592,4 +1596,4 @@ typedef struct {
} persistent_config_s;
// end
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Tue Dec 08 10:02:06 EST 2015
// this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon Dec 21 19:26:52 EST 2015

View File

@ -725,7 +725,8 @@
#define fatalErrorPin_offset 2216
#define warninigPin_offset 2220
#define configResetPin_offset 2224
#define unused_offset 2228
#define uartConsoleSerialSpeed_offset 2228
#define unused_offset 2232
#define le_formulas1_offset 3016
#define le_formulas2_offset 3216
#define le_formulas3_offset 3416

View File

@ -106,7 +106,7 @@ static bool hasValidEngineType(engine_configuration_s *engineConfiguration) {
}
void readFromFlash(void) {
efiAssertVoid(getRemainingStack(chThdSelf()) > 256, "read f");
efiAssertVoid(getRemainingStack(chThdSelf()) > 256, "read f");
printMsg(logger, "readFromFlash()");
flashRead(FLASH_ADDR, (char *) &persistentState, PERSISTENT_SIZE);

View File

@ -210,7 +210,7 @@ void applyNewHardwareSettings(void) {
}
void initHardware(Logging *l) {
efiAssertVoid(getRemainingStack(chThdSelf()) > 256, "init h");
efiAssertVoid(getRemainingStack(chThdSelf()) > 256, "init h");
sharedLogger = l;
engine_configuration_s *engineConfiguration = engine->engineConfiguration;
efiAssertVoid(engineConfiguration!=NULL, "engineConfiguration");

View File

@ -625,7 +625,8 @@ baro_corr_table_t baroCorrTable;
brain_pin_e fatalErrorPin;
brain_pin_e warninigPin;
brain_pin_e configResetPin;
int[197] unused;
uint32_t uartConsoleSerialSpeed;;"BPs", 1, 0, 0,1000000, 0
int[196] unused;
end_struct

View File

@ -164,7 +164,7 @@ void applyNewConfiguration(void) {
}
void runRusEfi(void) {
efiAssertVoid(getRemainingStack(chThdSelf()) > 512, "init s");
efiAssertVoid(getRemainingStack(chThdSelf()) > 512, "init s");
msObjectInit(&firmwareErrorMessageStream, errorMessageBuffer, sizeof(errorMessageBuffer), 0);

View File

@ -47,7 +47,7 @@ enable2ndByteCanID = false
; see PAGE_0_SIZE in C source code
; CONFIG_DEFINITION_START
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Tue Dec 08 10:02:06 EST 2015
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon Dec 21 19:26:52 EST 2015
pageSize = 16088
page = 1
@ -520,7 +520,8 @@ page = 1
fatalErrorPin = bits, U32, 2216, [0:6], "PA0", "PA1", "PA2", "PA3", "PA4", "PA5", "PA6", "PA7", "PA8", "PA9", "PA10", "PA11", "PA12", "PA13", "PA14", "PA15", "PB0", "PB1", "PB2", "PB3", "PB4", "PB5", "PB6", "PB7", "PB8", "PB9", "PB10", "PB11", "PB12", "PB13", "PB14", "PB15", "PC0", "PC1", "PC2", "PC3", "PC4", "PC5", "PC6", "PC7", "PC8", "PC9", "PC10", "PC11", "PC12", "PC13", "PC14", "PC15", "PD0", "PD1", "PD2", "PD3", "PD4", "PD5", "PD6", "PD7", "PD8", "PD9", "PD10", "PD11", "PD12", "PD13", "PD14", "PD15", "PE0", "PE1", "PE2", "PE3", "PE4", "PE5", "PE6", "PE7", "PE8", "PE9", "PE10", "PE11", "PE12", "PE13", "PE14", "PE15", "NONE", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
warninigPin = bits, U32, 2220, [0:6], "PA0", "PA1", "PA2", "PA3", "PA4", "PA5", "PA6", "PA7", "PA8", "PA9", "PA10", "PA11", "PA12", "PA13", "PA14", "PA15", "PB0", "PB1", "PB2", "PB3", "PB4", "PB5", "PB6", "PB7", "PB8", "PB9", "PB10", "PB11", "PB12", "PB13", "PB14", "PB15", "PC0", "PC1", "PC2", "PC3", "PC4", "PC5", "PC6", "PC7", "PC8", "PC9", "PC10", "PC11", "PC12", "PC13", "PC14", "PC15", "PD0", "PD1", "PD2", "PD3", "PD4", "PD5", "PD6", "PD7", "PD8", "PD9", "PD10", "PD11", "PD12", "PD13", "PD14", "PD15", "PE0", "PE1", "PE2", "PE3", "PE4", "PE5", "PE6", "PE7", "PE8", "PE9", "PE10", "PE11", "PE12", "PE13", "PE14", "PE15", "NONE", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
configResetPin = bits, U32, 2224, [0:6], "PA0", "PA1", "PA2", "PA3", "PA4", "PA5", "PA6", "PA7", "PA8", "PA9", "PA10", "PA11", "PA12", "PA13", "PA14", "PA15", "PB0", "PB1", "PB2", "PB3", "PB4", "PB5", "PB6", "PB7", "PB8", "PB9", "PB10", "PB11", "PB12", "PB13", "PB14", "PB15", "PC0", "PC1", "PC2", "PC3", "PC4", "PC5", "PC6", "PC7", "PC8", "PC9", "PC10", "PC11", "PC12", "PC13", "PC14", "PC15", "PD0", "PD1", "PD2", "PD3", "PD4", "PD5", "PD6", "PD7", "PD8", "PD9", "PD10", "PD11", "PD12", "PD13", "PD14", "PD15", "PE0", "PE1", "PE2", "PE3", "PE4", "PE5", "PE6", "PE7", "PE8", "PE9", "PE10", "PE11", "PE12", "PE13", "PE14", "PE15", "NONE", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
;skipping unused offset 2228
uartConsoleSerialSpeed = scalar, U32, 2228, "BPs", 1, 0, 0,1000000, 0
;skipping unused offset 2232
le_formulas1 = array, U08, 3016, [200],"char", 1, 0, 0.0, 3.0, 2
le_formulas2 = array, U08, 3216, [200],"char", 1, 0, 0.0, 3.0, 2
le_formulas3 = array, U08, 3416, [200],"char", 1, 0, 0.0, 3.0, 2

View File

@ -1,6 +1,6 @@
package com.rusefi.config;
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Tue Dec 01 20:29:19 EST 2015
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon Dec 21 19:26:52 EST 2015
public class Fields {
public static final Field ENGINETYPE = new Field("ENGINETYPE", 0, FieldType.INT);
public static final Field HEADERMAGICVALUE = new Field("HEADERMAGICVALUE", 4, FieldType.INT);
@ -457,6 +457,7 @@ public class Fields {
public static final Field FATALERRORPIN = new Field("FATALERRORPIN", 2216, FieldType.INT, brain_pin_e);
public static final Field WARNINIGPIN = new Field("WARNINIGPIN", 2220, FieldType.INT, brain_pin_e);
public static final Field CONFIGRESETPIN = new Field("CONFIGRESETPIN", 2224, FieldType.INT, brain_pin_e);
public static final Field UARTCONSOLESERIALSPEED = new Field("UARTCONSOLESERIALSPEED", 2228, FieldType.INT);
public static final Field LE_FORMULAS1 = new Field("LE_FORMULAS1", 3016, FieldType.INT);
public static final Field LE_FORMULAS2 = new Field("LE_FORMULAS2", 3216, FieldType.INT);
public static final Field LE_FORMULAS3 = new Field("LE_FORMULAS3", 3416, FieldType.INT);