From 707d65cac882901a53f52d73837071e23c7d07b7 Mon Sep 17 00:00:00 2001 From: Josh Stewart Date: Sun, 26 Feb 2017 16:33:03 +1100 Subject: [PATCH] Shuffle around memory to make upgrades simpler --- reference/speeduino.ini | 33 +++++++++++++++++---------------- speeduino/globals.h | 7 ++++++- 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/reference/speeduino.ini b/reference/speeduino.ini index 5afb0cb..c323fac 100644 --- a/reference/speeduino.ini +++ b/reference/speeduino.ini @@ -200,25 +200,26 @@ page = 2 flexFreqLow = scalar, U08, 41, "Hz", 1.0, 0.0, 0.0, 250.0, 0 flexFreqHigh = scalar, U08, 42, "Hz", 1.0, 0.0, 0.0, 250.0, 0 - tpsMin = scalar, U08, 43, "ADC", 1.0, 0.0, 0.0, 255.0, 0 - tpsMax = scalar, U08, 44, "ADC", 1.0, 0.0, 0.0, 255.0, 0 - mapMin = scalar, U08, 45, "kpa", 1.0, 0.0, 0.0, 255.0, 0 - mapMax = scalar, U16, 46, "kpa", 1.0, 0.0, 0.0, 25500, 0 - fpPrime = scalar, U08, 48, "s", 1.0, 0.0, 0.0, 255.0, 0 - stoich = scalar, U08, 49, ":1", 0.1, 0.0, 0.0, 25.5, 1 - oddfire2 = scalar, U16, 50, "deg", 1.0, 0.0, 0.0, 720, 0 ; * ( 2 byte) - oddfire3 = scalar, U16, 52, "deg", 1.0, 0.0, 0.0, 720, 0 ; * ( 2 byte) - oddfire4 = scalar, U16, 54, "deg", 1.0, 0.0, 0.0, 720, 0 ; * ( 2 byte) + boostMaxDuty = scalar, U08, 43, "%", 1.0, 0.0, 0.0, 100.0, 0 + tpsMin = scalar, U08, 44, "ADC", 1.0, 0.0, 0.0, 255.0, 0 + tpsMax = scalar, U08, 45, "ADC", 1.0, 0.0, 0.0, 255.0, 0 + mapMin = scalar, U08, 46, "kpa", 1.0, 0.0, 0.0, 255.0, 0 + mapMax = scalar, U16, 47, "kpa", 1.0, 0.0, 0.0, 25500, 0 + fpPrime = scalar, U08, 49, "s", 1.0, 0.0, 0.0, 255.0, 0 + stoich = scalar, U08, 50, ":1", 0.1, 0.0, 0.0, 25.5, 1 + oddfire2 = scalar, U16, 51, "deg", 1.0, 0.0, 0.0, 720, 0 ; * ( 2 byte) + oddfire3 = scalar, U16, 53, "deg", 1.0, 0.0, 0.0, 720, 0 ; * ( 2 byte) + oddfire4 = scalar, U16, 55, "deg", 1.0, 0.0, 0.0, 720, 0 ; * ( 2 byte) - flexFuelLow = scalar, U08, 56, "%", 1.0, 0.0, 0.0, 250.0, 0 - flexFuelHigh = scalar, U08, 57, "%", 1.0, 0.0, 0.0, 250.0, 0 - flexAdvLow = scalar, U08, 58, "Deg", 1.0, 0.0, 0.0, 250.0, 0 - flexAdvHigh = scalar, U08, 59, "Deg", 1.0, 0.0, 0.0, 250.0, 0 + flexFuelLow = scalar, U08, 57, "%", 1.0, 0.0, 0.0, 250.0, 0 + flexFuelHigh = scalar, U08, 58, "%", 1.0, 0.0, 0.0, 250.0, 0 + flexAdvLow = scalar, U08, 59, "Deg", 1.0, 0.0, 0.0, 250.0, 0 + flexAdvHigh = scalar, U08, 40, "Deg", 1.0, 0.0, 0.0, 250.0, 0 - iacCLminDuty = scalar, U08, 60, "%", 1.0, 0.0, 0.0, 100.0, 0 ; Minimum and maximum duty cycles when using closed loop idle - iacCLmaxDuty = scalar, U08, 61, "%", 1.0, 0.0, 0.0, 100.0, 0 + iacCLminDuty = scalar, U08, 61, "%", 1.0, 0.0, 0.0, 100.0, 0 ; Minimum and maximum duty cycles when using closed loop idle + iacCLmaxDuty = scalar, U08, 62, "%", 1.0, 0.0, 0.0, 100.0, 0 boostMinDuty = scalar, U08, 62, "%", 1.0, 0.0, 0.0, 100.0, 0 ; Minimum and maximum duty cycles for boost control - boostMaxDuty = scalar, U08, 63, "%", 1.0, 0.0, 0.0, 100.0, 0 + ;-------------------------------------------------- diff --git a/speeduino/globals.h b/speeduino/globals.h index dd9894a..7b58dab 100644 --- a/speeduino/globals.h +++ b/speeduino/globals.h @@ -139,6 +139,9 @@ volatile byte ign5_pin_mask; volatile byte *tach_pin_port; volatile byte tach_pin_mask; +volatile byte *triggerPri_pin_port; +volatile byte triggerPri_pin_mask; + //The status struct contains the current values for all 'live' variables //In current version this is 64 bytes struct statuses { @@ -279,6 +282,8 @@ struct config1 { byte dutyLim; byte flexFreqLow; //Lowest valid frequency reading from the flex sensor byte flexFreqHigh; //Highest valid frequency reading from the flex sensor + + byte boostMaxDuty; byte tpsMin; byte tpsMax; byte mapMin; @@ -296,7 +301,7 @@ struct config1 { byte iacCLminDuty; byte iacCLmaxDuty; byte boostMinDuty; - byte boostMaxDuty; + };