comparison Discovery/Src/settings.c @ 138:cc9c18075e00 FlipDisplay

Removed no longer supported scooter code
author Ideenmodellierer
date Sat, 23 Feb 2019 21:10:51 +0100
parents 3834b6272ee5
children 5c0f80e6b37a
comparison
equal deleted inserted replaced
137:9eda5a75c5fd 138:cc9c18075e00
53 53
54 const SFirmwareData firmware_FirmwareData __attribute__( (section(".firmware_firmware_data")) ) = 54 const SFirmwareData firmware_FirmwareData __attribute__( (section(".firmware_firmware_data")) ) =
55 { 55 {
56 .versionFirst = 1, 56 .versionFirst = 1,
57 .versionSecond = 4, 57 .versionSecond = 4,
58 .versionThird = 4, 58 .versionThird = 5,
59 .versionBeta = 1, 59 .versionBeta = 1,
60 60
61 /* 4 bytes with trailing 0 */ 61 /* 4 bytes with trailing 0 */
62 .signature = "mh", 62 .signature = "mh",
63 63
1131 } 1131 }
1132 1132
1133 /* uint32_t updateSettingsAllowedFromHeader; 1133 /* uint32_t updateSettingsAllowedFromHeader;
1134 */ 1134 */
1135 1135
1136 /* uint8_t scooterControl;
1137 */
1138 if(Settings.scooterControl > 1)
1139 {
1140 Settings.scooterControl = 1;
1141 corrections++;
1142 }
1143
1144 /* char scooterDeviceAddress[12];
1145 */
1146
1147 /* char scooterDeviceName[19];
1148 */
1149
1150 /* uint8_t ppo2sensors_deactivated; 1136 /* uint8_t ppo2sensors_deactivated;
1151 */ 1137 */
1152 if(Settings.ppo2sensors_deactivated > (1+2+4)) 1138 if(Settings.ppo2sensors_deactivated > (1+2+4))
1153 { 1139 {
1154 Settings.ppo2sensors_deactivated = 0; 1140 Settings.ppo2sensors_deactivated = 0;
1322 /* uint8_t debugModeOnStart; 1308 /* uint8_t debugModeOnStart;
1323 */ 1309 */
1324 if(Settings.compassBearing > 360) 1310 if(Settings.compassBearing > 360)
1325 { 1311 {
1326 Settings.compassBearing = 0; 1312 Settings.compassBearing = 0;
1327 corrections++;
1328 }
1329
1330 /* uint8_t scooterDrag;
1331 */
1332 if(Settings.scooterDrag > 3)
1333 {
1334 Settings.scooterDrag = 3;
1335 corrections++;
1336 }
1337
1338 /* uint8_t scooterLoad;
1339 */
1340 if(Settings.scooterLoad > 4)
1341 {
1342 Settings.scooterLoad = 4;
1343 corrections++;
1344 }
1345
1346 /* uint8_t scooterNumberOfBatteries;
1347 */
1348 if(Settings.scooterNumberOfBatteries > 3)
1349 {
1350 Settings.scooterNumberOfBatteries = 3;
1351 corrections++;
1352 }
1353
1354 /* uint16_t scooterBattSize;
1355 */
1356 if((Settings.scooterBattSize < 300) ||
1357 (Settings.scooterBattSize > 5000))
1358 {
1359 Settings.scooterBattSize = 700;
1360 corrections++; 1313 corrections++;
1361 } 1314 }
1362 1315
1363 1316
1364 /* uint8_t lastKnownBatteryPercentage; 1317 /* uint8_t lastKnownBatteryPercentage;
2566 } 2519 }
2567 2520
2568 2521
2569 uint8_t getLicence(void) 2522 uint8_t getLicence(void)
2570 { 2523 {
2571 //return 0xFF;
2572 //return LICENCEBONEX;
2573 return hardwareDataGetPointer()->primaryLicence; 2524 return hardwareDataGetPointer()->primaryLicence;
2574 } 2525 }
2575 2526
2576 2527
2577 void firmwareGetDate(RTC_DateTypeDef *SdateOutput) 2528 void firmwareGetDate(RTC_DateTypeDef *SdateOutput)