Go to the source code of this file.
Definition in file blockDetailsLookup.h.
#define CHTTransferTableLocationID 301 |
Definition at line 88 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define coreSettingsALocationID 2003 |
Definition at line 138 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define dwellDesiredVersusVoltageTable2LocationID 401 |
Definition at line 99 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define dwellDesiredVersusVoltageTableLocationID 400 |
Definition at line 98 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define dwellMaxVersusRPMTable2LocationID 413 |
Definition at line 111 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define dwellMaxVersusRPMTableLocationID 412 |
Definition at line 110 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define engineSettingsLocationID 2000 |
Definition at line 135 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define engineTempEnrichmentTableFixed2LocationID 407 |
Definition at line 105 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define engineTempEnrichmentTableFixedLocationID 406 |
Definition at line 104 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define engineTempEnrichmentTablePercent2LocationID 411 |
Definition at line 109 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define engineTempEnrichmentTablePercentLocationID 410 |
Definition at line 108 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define EXTERN extern |
Definition at line 47 of file blockDetailsLookup.h.
#define fillerA2LocationID 1001 |
Definition at line 124 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerALocationID 1000 |
Definition at line 123 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerB2LocationID 1003 |
Definition at line 126 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerBLocationID 1002 |
Definition at line 125 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerC2LocationID 1005 |
Definition at line 128 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerCLocationID 1004 |
Definition at line 127 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerD2LocationID 1007 |
Definition at line 130 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define fillerDLocationID 1006 |
Definition at line 129 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define FixedConfig1LocationID 200 |
Definition at line 84 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define FixedConfig2LocationID 201 |
Definition at line 85 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define IATTransferTableLocationID 300 |
Definition at line 87 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define IgnitionAdvanceTableMain2LocationID 9 |
Definition at line 67 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define IgnitionAdvanceTableMainLocationID 8 |
Definition at line 66 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define IgnitionAdvanceTableSecondary2LocationID 11 |
Definition at line 69 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define IgnitionAdvanceTableSecondaryLocationID 10 |
Definition at line 68 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define InjectionAdvanceTableMain2LocationID 13 |
Definition at line 71 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define InjectionAdvanceTableMainLocationID 12 |
Definition at line 70 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define InjectionAdvanceTableSecondary2LocationID 15 |
Definition at line 73 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define InjectionAdvanceTableSecondaryLocationID 14 |
Definition at line 72 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define injectorDeadTimeTable2LocationID 403 |
Definition at line 101 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define injectorDeadTimeTableLocationID 402 |
Definition at line 100 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define LambdaTable2LocationID 7 |
Definition at line 64 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define LambdaTableLocationID 6 |
Definition at line 63 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define MAFTransferTableLocationID 302 |
Definition at line 89 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define perCylinderFuelTrims2LocationID 901 |
Definition at line 116 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define perCylinderFuelTrimsLocationID 900 |
Definition at line 115 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define postStartEnrichmentTable2LocationID 405 |
Definition at line 103 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define postStartEnrichmentTableLocationID 404 |
Definition at line 102 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define primingVolumeTable2LocationID 409 |
Definition at line 107 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define primingVolumeTableLocationID 408 |
Definition at line 106 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define sensorPresetsLocationID 3001 |
Definition at line 142 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define sensorRangesLocationID 3000 |
Definition at line 141 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define sensorSettingsLocationID 3002 |
Definition at line 143 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define serialSettingsLocationID 2001 |
Definition at line 136 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesA2LocationID 101 |
Definition at line 76 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesALocationID 100 |
Definition at line 75 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesB2LocationID 103 |
Definition at line 78 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesBLocationID 102 |
Definition at line 77 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesC2LocationID 105 |
Definition at line 80 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesCLocationID 104 |
Definition at line 79 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesD2LocationID 107 |
Definition at line 82 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define SmallTablesDLocationID 106 |
Definition at line 81 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define tachoSettingsLocationID 2002 |
Definition at line 137 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define TestTransferTableLocationID 303 |
Definition at line 90 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define userTextField2LocationID 3003 |
Definition at line 144 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define userTextFieldLocationID 2004 |
Definition at line 139 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define VETableMain2LocationID 1 |
Definition at line 58 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define VETableMainLocationID 0 |
Definition at line 57 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define VETableSecondary2LocationID 3 |
Definition at line 60 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define VETableSecondaryLocationID 2 |
Definition at line 59 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define VETableTertiary2LocationID 5 |
Definition at line 62 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
#define VETableTertiaryLocationID 4 |
Definition at line 61 of file blockDetailsLookup.h.
Referenced by lookupBlockDetails().
EXTERN unsigned short lookupBlockDetails | ( | unsigned short | locationID, | |
blockDetails * | details | |||
) |
Lookup memory block details.
Flash only blocks leave the ram address and page values set to zero. ID's that don't exist leave all set to zero. Error handling is to be done externally based on that.
locationID | is the ID of the memory location for which details are required. | |
details | is a pointer to the blockDetails struct to populate with the details. |
Definition at line 63 of file blockDetailsLookup.c.
References CHTTransferTableLocation, CHTTransferTableLocationID, fixedConfig1::coreSettingsA, coreSettingsALocationID, dwellDesiredVersusVoltageTable2Location, dwellDesiredVersusVoltageTable2LocationID, dwellDesiredVersusVoltageTableLocation, dwellDesiredVersusVoltageTableLocationID, dwellMaxVersusRPMTable2Location, dwellMaxVersusRPMTable2LocationID, dwellMaxVersusRPMTableLocation, dwellMaxVersusRPMTableLocationID, ENGINE_SETTINGS_SIZE, fixedConfig1::engineSettings, engineSettingsLocationID, engineTempEnrichmentTableFixed2Location, engineTempEnrichmentTableFixed2LocationID, engineTempEnrichmentTableFixedLocation, engineTempEnrichmentTableFixedLocationID, engineTempEnrichmentTablePercent2Location, engineTempEnrichmentTablePercent2LocationID, engineTempEnrichmentTablePercentLocation, engineTempEnrichmentTablePercentLocationID, fillerA2Location, fillerA2LocationID, fillerALocation, fillerALocationID, fillerB2Location, fillerB2LocationID, fillerBLocation, fillerBLocationID, fillerC2Location, fillerC2LocationID, fillerCLocation, fillerCLocationID, fillerD2Location, fillerD2LocationID, fillerDLocation, fillerDLocationID, FixedConfig1LocationID, FixedConfig2LocationID, fixedConfigs1, fixedConfigs2, blockDetails::FlashAddress, blockDetails::FlashPage, FUELTABLES_PPAGE, IATTransferTableLocation, IATTransferTableLocationID, IgnitionAdvanceTableMain2LocationID, IgnitionAdvanceTableMainFlash2Location, IgnitionAdvanceTableMainFlashLocation, IgnitionAdvanceTableMainLocationID, IgnitionAdvanceTableSecondary2LocationID, IgnitionAdvanceTableSecondaryFlash2Location, IgnitionAdvanceTableSecondaryFlashLocation, IgnitionAdvanceTableSecondaryLocationID, InjectionAdvanceTableMain2LocationID, InjectionAdvanceTableMainFlash2Location, InjectionAdvanceTableMainFlashLocation, InjectionAdvanceTableMainLocationID, InjectionAdvanceTableSecondary2LocationID, InjectionAdvanceTableSecondaryFlash2Location, InjectionAdvanceTableSecondaryFlashLocation, InjectionAdvanceTableSecondaryLocationID, injectorDeadTimeTable2Location, injectorDeadTimeTable2LocationID, injectorDeadTimeTableLocation, injectorDeadTimeTableLocationID, LambdaTable2LocationID, LambdaTableFlash2Location, LambdaTableFlashLocation, LambdaTableLocationID, locationIDNotFound, LOOKUP_PPAGE, MAFTransferTableLocation, MAFTransferTableLocationID, MAINTABLE_SIZE, perCylinderFuelTrims2Location, perCylinderFuelTrims2LocationID, perCylinderFuelTrimsLocation, perCylinderFuelTrimsLocationID, postStartEnrichmentTable2Location, postStartEnrichmentTable2LocationID, postStartEnrichmentTableLocation, postStartEnrichmentTableLocationID, PPAGE, primingVolumeTable2Location, primingVolumeTable2LocationID, primingVolumeTableLocation, primingVolumeTableLocationID, blockDetails::RAMAddress, blockDetails::RAMPage, RPAGE_FUEL_ONE, RPAGE_FUEL_TWO, RPAGE_TIME_ONE, RPAGE_TIME_TWO, RPAGE_TUNE_ONE, RPAGE_TUNE_TWO, SENSOR_PRESETS_SIZE, SENSOR_RANGES_SIZE, SENSOR_SETTINGS_SIZE, fixedConfig2::sensorPresets, sensorPresetsLocationID, fixedConfig2::sensorRanges, sensorRangesLocationID, fixedConfig2::sensorSettings, sensorSettingsLocationID, SERIAL_SETTINGS_SIZE, fixedConfig1::serialSettings, serialSettingsLocationID, blockDetails::size, SmallTablesA2LocationID, SmallTablesAFlash2Location, SmallTablesAFlashLocation, SmallTablesALocationID, SmallTablesB2LocationID, SmallTablesBFlash2Location, SmallTablesBFlashLocation, SmallTablesBLocationID, SmallTablesC2LocationID, SmallTablesCFlash2Location, SmallTablesCFlashLocation, SmallTablesCLocationID, SmallTablesD2LocationID, SmallTablesDFlash2Location, SmallTablesDFlashLocation, SmallTablesDLocationID, TACHO_SETTINGS_SIZE, fixedConfig1::tachoSettings, tachoSettingsLocationID, TestTransferTableLocation, TestTransferTableLocationID, TIMETABLES_PPAGE, TransferTableSize, TUNETABLES_PPAGE, TWODTABLEUS_SIZE, fixedConfig1::userTextField, fixedConfig2::userTextField2, userTextField2LocationID, userTextFieldArrayLength1, userTextFieldArrayLength2, userTextFieldLocationID, VETableMain2LocationID, VETableMainFlash2Location, VETableMainFlashLocation, VETableMainLocationID, VETableSecondary2LocationID, VETableSecondaryFlash2Location, VETableSecondaryFlashLocation, VETableSecondaryLocationID, VETableTertiary2LocationID, VETableTertiaryFlash2Location, VETableTertiaryFlashLocation, and VETableTertiaryLocationID.
Referenced by decodePacketAndRespond().
00063 { 00064 /* Initialise the four values needed for operations on memory at 0 for error checking */ 00065 details->RAMPage = 0; 00066 details->FlashPage = 0; 00067 details->RAMAddress = 0; 00068 details->FlashAddress = 0; 00069 00070 /* Initialise the block size to 1024 to save code space and increase readability */ 00071 details->size = MAINTABLE_SIZE; 00072 00073 /* Look up the locations and set non default sizes */ 00074 switch (locationID) { 00075 /* flash only fixed conf full blocks */ 00076 case FixedConfig1LocationID: 00077 details->FlashPage = PPAGE; 00078 details->FlashAddress = (void*)&fixedConfigs1; 00079 break; 00080 case FixedConfig2LocationID: 00081 details->FlashPage = PPAGE; 00082 details->FlashAddress = (void*)&fixedConfigs2; 00083 break; 00084 00085 /* lookup tables */ 00086 case IATTransferTableLocationID: 00087 details->size = TransferTableSize; 00088 details->FlashPage = LOOKUP_PPAGE; 00089 details->FlashAddress = IATTransferTableLocation; 00090 break; 00091 case CHTTransferTableLocationID: 00092 details->size = TransferTableSize; 00093 details->FlashPage = LOOKUP_PPAGE; 00094 details->FlashAddress = CHTTransferTableLocation; 00095 break; 00096 case MAFTransferTableLocationID: 00097 details->size = TransferTableSize; 00098 details->FlashPage = LOOKUP_PPAGE; 00099 details->FlashAddress = MAFTransferTableLocation; 00100 break; 00101 case TestTransferTableLocationID: 00102 details->size = TransferTableSize; 00103 details->FlashPage = LOOKUP_PPAGE; 00104 details->FlashAddress = TestTransferTableLocation; 00105 break; 00106 00107 /* fuel tables */ 00108 case VETableMainLocationID: 00109 details->RAMPage = RPAGE_FUEL_ONE; 00110 details->FlashPage = FUELTABLES_PPAGE; 00111 details->RAMAddress = (void*)&TablesA; 00112 details->FlashAddress = VETableMainFlashLocation; 00113 break; 00114 case VETableMain2LocationID: 00115 details->RAMPage = RPAGE_FUEL_TWO; 00116 details->FlashPage = FUELTABLES_PPAGE; 00117 details->RAMAddress = (void*)&TablesA; 00118 details->FlashAddress = VETableMainFlash2Location; 00119 break; 00120 case VETableSecondaryLocationID: 00121 details->RAMPage = RPAGE_FUEL_ONE; 00122 details->FlashPage = FUELTABLES_PPAGE; 00123 details->RAMAddress = (void*)&TablesB; 00124 details->FlashAddress = VETableSecondaryFlashLocation; 00125 break; 00126 case VETableSecondary2LocationID: 00127 details->RAMPage = RPAGE_FUEL_TWO; 00128 details->FlashPage = FUELTABLES_PPAGE; 00129 details->RAMAddress = (void*)&TablesB; 00130 details->FlashAddress = VETableSecondaryFlash2Location; 00131 break; 00132 case VETableTertiaryLocationID: 00133 details->RAMPage = RPAGE_FUEL_ONE; 00134 details->FlashPage = FUELTABLES_PPAGE; 00135 details->RAMAddress = (void*)&TablesC; 00136 details->FlashAddress = VETableTertiaryFlashLocation; 00137 break; 00138 case VETableTertiary2LocationID: 00139 details->RAMPage = RPAGE_FUEL_TWO; 00140 details->FlashPage = FUELTABLES_PPAGE; 00141 details->RAMAddress = (void*)&TablesC; 00142 details->FlashAddress = VETableTertiaryFlash2Location; 00143 break; 00144 case LambdaTableLocationID: 00145 details->RAMPage = RPAGE_FUEL_ONE; 00146 details->FlashPage = FUELTABLES_PPAGE; 00147 details->RAMAddress = (void*)&TablesD; 00148 details->FlashAddress = LambdaTableFlashLocation; 00149 break; 00150 case LambdaTable2LocationID: 00151 details->RAMPage = RPAGE_FUEL_TWO; 00152 details->FlashPage = FUELTABLES_PPAGE; 00153 details->RAMAddress = (void*)&TablesD; 00154 details->FlashAddress = LambdaTableFlash2Location; 00155 break; 00156 00157 /* timing tables */ 00158 case IgnitionAdvanceTableMainLocationID: 00159 details->RAMPage = RPAGE_TIME_ONE; 00160 details->FlashPage = TIMETABLES_PPAGE; 00161 details->RAMAddress = (void*)&TablesA; 00162 details->FlashAddress = IgnitionAdvanceTableMainFlashLocation; 00163 break; 00164 case IgnitionAdvanceTableMain2LocationID: 00165 details->RAMPage = RPAGE_TIME_TWO; 00166 details->FlashPage = TIMETABLES_PPAGE; 00167 details->RAMAddress = (void*)&TablesA; 00168 details->FlashAddress = IgnitionAdvanceTableMainFlash2Location; 00169 break; 00170 case IgnitionAdvanceTableSecondaryLocationID: 00171 details->RAMPage = RPAGE_TIME_ONE; 00172 details->FlashPage = TIMETABLES_PPAGE; 00173 details->RAMAddress = (void*)&TablesB; 00174 details->FlashAddress = IgnitionAdvanceTableSecondaryFlashLocation; 00175 break; 00176 case IgnitionAdvanceTableSecondary2LocationID: 00177 details->RAMPage = RPAGE_TIME_TWO; 00178 details->FlashPage = TIMETABLES_PPAGE; 00179 details->RAMAddress = (void*)&TablesB; 00180 details->FlashAddress = IgnitionAdvanceTableSecondaryFlash2Location; 00181 break; 00182 case InjectionAdvanceTableMainLocationID: 00183 details->RAMPage = RPAGE_TIME_ONE; 00184 details->FlashPage = TIMETABLES_PPAGE; 00185 details->RAMAddress = (void*)&TablesC; 00186 details->FlashAddress = InjectionAdvanceTableMainFlashLocation; 00187 break; 00188 case InjectionAdvanceTableMain2LocationID: 00189 details->RAMPage = RPAGE_TIME_TWO; 00190 details->FlashPage = TIMETABLES_PPAGE; 00191 details->RAMAddress = (void*)&TablesC; 00192 details->FlashAddress = InjectionAdvanceTableMainFlash2Location; 00193 break; 00194 case InjectionAdvanceTableSecondaryLocationID: 00195 details->RAMPage = RPAGE_TIME_ONE; 00196 details->FlashPage = TIMETABLES_PPAGE; 00197 details->RAMAddress = (void*)&TablesD; 00198 details->FlashAddress = InjectionAdvanceTableSecondaryFlashLocation; 00199 break; 00200 case InjectionAdvanceTableSecondary2LocationID: 00201 details->RAMPage = RPAGE_TIME_TWO; 00202 details->FlashPage = TIMETABLES_PPAGE; 00203 details->RAMAddress = (void*)&TablesD; 00204 details->FlashAddress = InjectionAdvanceTableSecondaryFlash2Location; 00205 break; 00206 00207 /* small table full blocks */ 00208 case SmallTablesALocationID: 00209 details->RAMPage = RPAGE_TUNE_ONE; 00210 details->FlashPage = TUNETABLES_PPAGE; 00211 details->RAMAddress = (void*)&TablesA; 00212 details->FlashAddress = SmallTablesAFlashLocation; 00213 break; 00214 case SmallTablesA2LocationID: 00215 details->RAMPage = RPAGE_TUNE_TWO; 00216 details->FlashPage = TUNETABLES_PPAGE; 00217 details->RAMAddress = (void*)&TablesA; 00218 details->FlashAddress = SmallTablesAFlash2Location; 00219 break; 00220 case SmallTablesBLocationID: 00221 details->RAMPage = RPAGE_TUNE_ONE; 00222 details->FlashPage = TUNETABLES_PPAGE; 00223 details->RAMAddress = (void*)&TablesB; 00224 details->FlashAddress = SmallTablesBFlashLocation; 00225 break; 00226 case SmallTablesB2LocationID: 00227 details->RAMPage = RPAGE_TUNE_TWO; 00228 details->FlashPage = TUNETABLES_PPAGE; 00229 details->RAMAddress = (void*)&TablesB; 00230 details->FlashAddress = SmallTablesBFlash2Location; 00231 break; 00232 case SmallTablesCLocationID: 00233 details->RAMPage = RPAGE_TUNE_ONE; 00234 details->FlashPage = TUNETABLES_PPAGE; 00235 details->RAMAddress = (void*)&TablesC; 00236 details->FlashAddress = SmallTablesCFlashLocation; 00237 break; 00238 case SmallTablesC2LocationID: 00239 details->RAMPage = RPAGE_TUNE_TWO; 00240 details->FlashPage = TUNETABLES_PPAGE; 00241 details->RAMAddress = (void*)&TablesC; 00242 details->FlashAddress = SmallTablesCFlash2Location; 00243 break; 00244 case SmallTablesDLocationID: 00245 details->RAMPage = RPAGE_TUNE_ONE; 00246 details->FlashPage = TUNETABLES_PPAGE; 00247 details->RAMAddress = (void*)&TablesD; 00248 details->FlashAddress = SmallTablesDFlashLocation; 00249 break; 00250 case SmallTablesD2LocationID: 00251 details->RAMPage = RPAGE_TUNE_TWO; 00252 details->FlashPage = TUNETABLES_PPAGE; 00253 details->RAMAddress = (void*)&TablesD; 00254 details->FlashAddress = SmallTablesDFlash2Location; 00255 break; 00256 00257 /* TablesA small tables */ 00258 case dwellDesiredVersusVoltageTableLocationID: 00259 details->size = TWODTABLEUS_SIZE; 00260 details->RAMPage = RPAGE_TUNE_ONE; 00261 details->FlashPage = TUNETABLES_PPAGE; 00262 details->RAMAddress = (void*)&TablesA.SmallTablesA.dwellDesiredVersusVoltageTable; 00263 details->FlashAddress = dwellDesiredVersusVoltageTableLocation; 00264 break; 00265 case dwellDesiredVersusVoltageTable2LocationID: 00266 details->size = TWODTABLEUS_SIZE; 00267 details->RAMPage = RPAGE_TUNE_TWO; 00268 details->FlashPage = TUNETABLES_PPAGE; 00269 details->RAMAddress = (void*)&TablesA.SmallTablesA.dwellDesiredVersusVoltageTable; 00270 details->FlashAddress = dwellDesiredVersusVoltageTable2Location; 00271 break; 00272 case injectorDeadTimeTableLocationID: 00273 details->size = TWODTABLEUS_SIZE; 00274 details->RAMPage = RPAGE_TUNE_ONE; 00275 details->FlashPage = TUNETABLES_PPAGE; 00276 details->RAMAddress = (void*)&TablesA.SmallTablesA.injectorDeadTimeTable; 00277 details->FlashAddress = injectorDeadTimeTableLocation; 00278 break; 00279 case injectorDeadTimeTable2LocationID: 00280 details->size = TWODTABLEUS_SIZE; 00281 details->RAMPage = RPAGE_TUNE_TWO; 00282 details->FlashPage = TUNETABLES_PPAGE; 00283 details->RAMAddress = (void*)&TablesA.SmallTablesA.injectorDeadTimeTable; 00284 details->FlashAddress = injectorDeadTimeTable2Location; 00285 break; 00286 case postStartEnrichmentTableLocationID: 00287 details->size = TWODTABLEUS_SIZE; 00288 details->RAMPage = RPAGE_TUNE_ONE; 00289 details->FlashPage = TUNETABLES_PPAGE; 00290 details->RAMAddress = (void*)&TablesA.SmallTablesA.postStartEnrichmentTable; 00291 details->FlashAddress = postStartEnrichmentTableLocation; 00292 break; 00293 case postStartEnrichmentTable2LocationID: 00294 details->size = TWODTABLEUS_SIZE; 00295 details->RAMPage = RPAGE_TUNE_TWO; 00296 details->FlashPage = TUNETABLES_PPAGE; 00297 details->RAMAddress = (void*)&TablesA.SmallTablesA.postStartEnrichmentTable; 00298 details->FlashAddress = postStartEnrichmentTable2Location; 00299 break; 00300 case engineTempEnrichmentTableFixedLocationID: 00301 details->size = TWODTABLEUS_SIZE; 00302 details->RAMPage = RPAGE_TUNE_ONE; 00303 details->FlashPage = TUNETABLES_PPAGE; 00304 details->RAMAddress = (void*)&TablesA.SmallTablesA.engineTempEnrichmentTableFixed; 00305 details->FlashAddress = engineTempEnrichmentTableFixedLocation; 00306 break; 00307 case engineTempEnrichmentTableFixed2LocationID: 00308 details->size = TWODTABLEUS_SIZE; 00309 details->RAMPage = RPAGE_TUNE_TWO; 00310 details->FlashPage = TUNETABLES_PPAGE; 00311 details->RAMAddress = (void*)&TablesA.SmallTablesA.engineTempEnrichmentTableFixed; 00312 details->FlashAddress = engineTempEnrichmentTableFixed2Location; 00313 break; 00314 case primingVolumeTableLocationID: 00315 details->size = TWODTABLEUS_SIZE; 00316 details->RAMPage = RPAGE_TUNE_ONE; 00317 details->FlashPage = TUNETABLES_PPAGE; 00318 details->RAMAddress = (void*)&TablesA.SmallTablesA.primingVolumeTable; 00319 details->FlashAddress = primingVolumeTableLocation; 00320 break; 00321 case primingVolumeTable2LocationID: 00322 details->size = TWODTABLEUS_SIZE; 00323 details->RAMPage = RPAGE_TUNE_TWO; 00324 details->FlashPage = TUNETABLES_PPAGE; 00325 details->RAMAddress = (void*)&TablesA.SmallTablesA.primingVolumeTable; 00326 details->FlashAddress = primingVolumeTable2Location; 00327 break; 00328 case engineTempEnrichmentTablePercentLocationID: 00329 details->size = TWODTABLEUS_SIZE; 00330 details->RAMPage = RPAGE_TUNE_ONE; 00331 details->FlashPage = TUNETABLES_PPAGE; 00332 details->RAMAddress = (void*)&TablesA.SmallTablesA.engineTempEnrichmentTablePercent; 00333 details->FlashAddress = engineTempEnrichmentTablePercentLocation; 00334 break; 00335 case engineTempEnrichmentTablePercent2LocationID: 00336 details->size = TWODTABLEUS_SIZE; 00337 details->RAMPage = RPAGE_TUNE_TWO; 00338 details->FlashPage = TUNETABLES_PPAGE; 00339 details->RAMAddress = (void*)&TablesA.SmallTablesA.engineTempEnrichmentTablePercent; 00340 details->FlashAddress = engineTempEnrichmentTablePercent2Location; 00341 break; 00342 case dwellMaxVersusRPMTableLocationID: 00343 details->size = TWODTABLEUS_SIZE; 00344 details->RAMPage = RPAGE_TUNE_ONE; 00345 details->FlashPage = TUNETABLES_PPAGE; 00346 details->RAMAddress = (void*)&TablesA.SmallTablesA.dwellMaxVersusRPMTable; 00347 details->FlashAddress = dwellMaxVersusRPMTableLocation; 00348 break; 00349 case dwellMaxVersusRPMTable2LocationID: 00350 details->size = TWODTABLEUS_SIZE; 00351 details->RAMPage = RPAGE_TUNE_TWO; 00352 details->FlashPage = TUNETABLES_PPAGE; 00353 details->RAMAddress = (void*)&TablesA.SmallTablesA.dwellMaxVersusRPMTable; 00354 details->FlashAddress = dwellMaxVersusRPMTable2Location; 00355 break; 00356 00357 /* TablesB small tables */ 00358 case perCylinderFuelTrimsLocationID: 00359 details->size = 12; 00360 details->RAMPage = RPAGE_TUNE_ONE; 00361 details->FlashPage = TUNETABLES_PPAGE; 00362 details->RAMAddress = (void*)&TablesB.SmallTablesB.perCylinderFuelTrims; 00363 details->FlashAddress = perCylinderFuelTrimsLocation; 00364 break; 00365 case perCylinderFuelTrims2LocationID: 00366 details->size = 12; 00367 details->RAMPage = RPAGE_TUNE_TWO; 00368 details->FlashPage = TUNETABLES_PPAGE; 00369 details->RAMAddress = (void*)&TablesB.SmallTablesB.perCylinderFuelTrims; 00370 details->FlashAddress = perCylinderFuelTrims2Location; 00371 break; 00372 00373 /* TablesC small tables */ 00374 // TODO add data chunks from TablesC when some are put in 00375 00376 /* TablesD small tables */ 00377 // TODO add data chunks from TablesD when some are put in 00378 00379 /* filler block entries */ 00380 case fillerALocationID: 00381 details->size = 576; 00382 details->RAMPage = RPAGE_TUNE_ONE; 00383 details->FlashPage = TUNETABLES_PPAGE; 00384 details->RAMAddress = (void*)&TablesA.SmallTablesA.filler; 00385 details->FlashAddress = fillerALocation; 00386 break; 00387 case fillerA2LocationID: 00388 details->size = 576; 00389 details->RAMPage = RPAGE_TUNE_TWO; 00390 details->FlashPage = TUNETABLES_PPAGE; 00391 details->RAMAddress = (void*)&TablesA.SmallTablesA.filler; 00392 details->FlashAddress = fillerA2Location; 00393 break; 00394 case fillerBLocationID: 00395 details->size = 1012; 00396 details->RAMPage = RPAGE_TUNE_ONE; 00397 details->FlashPage = TUNETABLES_PPAGE; 00398 details->RAMAddress = (void*)&TablesB.SmallTablesB.filler; 00399 details->FlashAddress = fillerBLocation; 00400 break; 00401 case fillerB2LocationID: 00402 details->size = 1012; 00403 details->RAMPage = RPAGE_TUNE_TWO; 00404 details->FlashPage = TUNETABLES_PPAGE; 00405 details->RAMAddress = (void*)&TablesB.SmallTablesB.filler; 00406 details->FlashAddress = fillerB2Location; 00407 break; 00408 case fillerCLocationID: 00409 details->size = 1024; 00410 details->RAMPage = RPAGE_TUNE_ONE; 00411 details->FlashPage = TUNETABLES_PPAGE; 00412 details->RAMAddress = (void*)&TablesC.SmallTablesC.filler; 00413 details->FlashAddress = fillerCLocation; 00414 break; 00415 case fillerC2LocationID: 00416 details->size = 1024; 00417 details->RAMPage = RPAGE_TUNE_TWO; 00418 details->FlashPage = TUNETABLES_PPAGE; 00419 details->RAMAddress = (void*)&TablesC.SmallTablesC.filler; 00420 details->FlashAddress = fillerC2Location; 00421 break; 00422 case fillerDLocationID: 00423 details->size = 1024; 00424 details->RAMPage = RPAGE_TUNE_ONE; 00425 details->FlashPage = TUNETABLES_PPAGE; 00426 details->RAMAddress = (void*)&TablesD.SmallTablesD.filler; 00427 details->FlashAddress = fillerDLocation; 00428 break; 00429 case fillerD2LocationID: 00430 details->size = 1024; 00431 details->RAMPage = RPAGE_TUNE_TWO; 00432 details->FlashPage = TUNETABLES_PPAGE; 00433 details->RAMAddress = (void*)&TablesD.SmallTablesD.filler; 00434 details->FlashAddress = fillerD2Location; 00435 break; 00436 00437 /* Fixed conf 1 small chunks */ 00438 case engineSettingsLocationID: 00439 details->size = ENGINE_SETTINGS_SIZE; 00440 details->FlashPage = PPAGE; 00441 details->FlashAddress = (void*)&(fixedConfigs1.engineSettings); 00442 break; 00443 case serialSettingsLocationID: 00444 details->size = SERIAL_SETTINGS_SIZE; 00445 details->FlashPage = PPAGE; 00446 details->FlashAddress = (void*)&(fixedConfigs1.serialSettings); 00447 break; 00448 case tachoSettingsLocationID: 00449 details->size = TACHO_SETTINGS_SIZE; 00450 details->FlashPage = PPAGE; 00451 details->FlashAddress = (void*)&(fixedConfigs1.tachoSettings); 00452 break; 00453 case coreSettingsALocationID: 00454 details->size = 2; 00455 details->FlashPage = PPAGE; 00456 details->FlashAddress = (void*)&(fixedConfigs1.coreSettingsA); 00457 break; 00458 case userTextFieldLocationID: 00459 details->size = userTextFieldArrayLength1; 00460 details->FlashPage = PPAGE; 00461 details->FlashAddress = (void*)&(fixedConfigs1.userTextField); 00462 break; 00463 00464 /* Fixed conf 2 small chunks */ 00465 case sensorRangesLocationID: 00466 details->size = SENSOR_RANGES_SIZE; 00467 details->FlashPage = PPAGE; 00468 details->FlashAddress = (void*)&(fixedConfigs2.sensorRanges); 00469 break; 00470 case sensorPresetsLocationID: 00471 details->size = SENSOR_PRESETS_SIZE; 00472 details->FlashPage = PPAGE; 00473 details->FlashAddress = (void*)&(fixedConfigs2.sensorPresets); 00474 break; 00475 case sensorSettingsLocationID: 00476 details->size = SENSOR_SETTINGS_SIZE; 00477 details->FlashPage = PPAGE; 00478 details->FlashAddress = (void*)&(fixedConfigs2.sensorSettings); 00479 break; 00480 case userTextField2LocationID: 00481 details->size = userTextFieldArrayLength2; 00482 details->FlashPage = PPAGE; 00483 details->FlashAddress = (void*)&(fixedConfigs2.userTextField2); 00484 break; 00485 00486 default: 00487 /* Return early if locationID is not valid. */ 00488 return locationIDNotFound; 00489 } 00490 00491 /* Fall through to not return error */ 00492 return 0; 00493 }