auto-sync

This commit is contained in:
rusEfi 2015-03-22 11:11:12 -05:00
parent 90d4d734f6
commit 00237d083d
7 changed files with 13 additions and 8 deletions

View File

@ -23,14 +23,15 @@ void setSachs(engine_configuration_s *engineConfiguration) {
* We treat the trigger as 1/0 toothed wheel
*/
engineConfiguration->trigger.type = TT_TOOTHED_WHEEL;
engineConfiguration->trigger.customTotalToothCount = 1;
engineConfiguration->trigger.customSkippedToothCount = 0;
engineConfiguration->trigger.customTotalToothCount = 50;
engineConfiguration->trigger.customSkippedToothCount = 2;
engineConfiguration->hasIatSensor = false;
engineConfiguration->hasMapSensor = false;
engineConfiguration->hasBaroSensor = false;
engineConfiguration->hasAfrSensor = false;
engineConfiguration->hasCltSensor = false;
boardConfiguration->useSerialPort = false;
// Frankenstein analog input #1: PA1 adc1
// Frankenstein analog input #2: PA3 adc3 TPS
@ -70,5 +71,8 @@ void setSachs(engine_configuration_s *engineConfiguration) {
boardConfiguration->triggerInputPins[0] = GPIOA_5;
boardConfiguration->triggerInputPins[1] = GPIOC_6;
boardConfiguration->injectionPins[0] = GPIOC_15;
}

View File

@ -32,7 +32,7 @@ void startTsPort(void) {
* This method contains a long delay, that's the reason why this is not done on the main thread
*/
usb_serial_start();
} else {
} else if (boardConfiguration->useSerialPort) {
print("TunerStudio over USART");
mySetPadMode("tunerstudio rx", TS_SERIAL_RX_PORT, TS_SERIAL_RX_PIN, PAL_MODE_ALTERNATE(TS_SERIAL_AF));

View File

@ -494,6 +494,7 @@ static void setTriggerType(int value) {
}
static void setToothedWheel(int total, int skipped) {
scheduleMsg(&logger, "toothed: total=%d/skipped=%d", total, skipped);
setToothedWheelConfiguration(&engine->triggerShape, total, skipped, engineConfiguration);
// initializeTriggerShape(&logger, engineConfiguration, engineConfiguration2);
incrementGlobalConfigurationVersion();

View File

@ -1,5 +1,5 @@
// This file was generated by Version2Header
// Sat Mar 14 21:30:36 EDT 2015
// Sun Mar 22 11:16:21 EDT 2015
#ifndef VCS_VERSION
#define VCS_VERSION "7427"
#define VCS_VERSION "7501"
#endif

View File

@ -1185,7 +1185,8 @@ fileVersion = { 20150314 }
; Tuning->General
dialog = generalSettings, "General"
field = "tunerStudioSerialSpeed", tunerStudioSerialSpeed
field = "tunerStudioSerialSpeed", tunerStudioSerialSpeed
field = "Use PC10/PC11 serial?", useSerialPort
field = "RPM Hard Limit", rpmHardLimit
field = ""
field = "Fuel Algorithm", algorithm

View File

@ -113,7 +113,6 @@ public class TestingUtils {
// todo: improve this logic, compare times
IoUtil.sendCommand("reset_wave_chart");
getWaveChart();
getWaveChart();
// we want to wait for the 2nd chart to see same same RPM across the whole chart
String result = getWaveChart();
FileLog.MAIN.logLine("current chart: " + result);

View File

@ -516,7 +516,7 @@ void testTriggerDecoder(void) {
testTriggerDecoder3("citroen", CITROEN_TU3JP, 0, 0.4833, 0.0, 2.9994);
testTriggerDecoder3("neon NGC", DODGE_NEON_2003, 0, 0.4786, 0.0, CHRYSLER_NGC_GAP);
testTriggerDecoder2("sachs", SACHS, 0, 0.5000, 0.000);
testTriggerDecoder2("sachs", SACHS, 0, 0.4800, 0.000);
testMazda323();