comparison Discovery/Src/settings.c @ 870:bc6c90e20d9e Evo_2_23

Instrument code for Bootloader: the Bootloader was reactivated. Because some functions have changed in the past years an instrumentation had to be done to avoid compile issues (e.g. no multilanguage in Bootloader, no special fonts)
author Ideenmodellierer
date Mon, 12 Aug 2024 22:25:46 +0200
parents 2cab242c9a4a
children e373e90a48db
comparison
equal deleted inserted replaced
869:4e10a3e087a1 870:bc6c90e20d9e
1856 1856
1857 SettingsStatus.Corrections = corrections; 1857 SettingsStatus.Corrections = corrections;
1858 return (uint8_t)corrections; 1858 return (uint8_t)corrections;
1859 } 1859 }
1860 1860
1861 1861 #ifndef BOOTLOADER_STANDALONE
1862 /* always at 0x8080000, do not move -> bootloader access */ 1862 /* always at 0x8080000, do not move -> bootloader access */
1863 const SFirmwareData* firmwareDataGetPointer(void) 1863 const SFirmwareData* firmwareDataGetPointer(void)
1864 { 1864 {
1865 return &firmware_FirmwareData; 1865 return &firmware_FirmwareData;
1866 } 1866 }
1870 const SHardwareData* hardwareDataGetPointer(void) 1870 const SHardwareData* hardwareDataGetPointer(void)
1871 { 1871 {
1872 return (SHardwareData *)HARDWAREDATA_ADDRESS; 1872 return (SHardwareData *)HARDWAREDATA_ADDRESS;
1873 } 1873 }
1874 #endif 1874 #endif
1875 1875 #endif
1876 const SSettings* settingsGetPointerStandard(void) 1876 const SSettings* settingsGetPointerStandard(void)
1877 { 1877 {
1878 return &SettingsStandard; 1878 return &SettingsStandard;
1879 } 1879 }
1880 1880
3009 { 3009 {
3010 RTEactualHigh = high; 3010 RTEactualHigh = high;
3011 RTEactualLow = low; 3011 RTEactualLow = low;
3012 } 3012 }
3013 3013
3014 3014 #ifndef BOOTLOADER_STANDALONE
3015 void getActualRTEandFONTversion(uint8_t *RTEhigh, uint8_t *RTElow, uint8_t *FONThigh, uint8_t *FONTlow) 3015 void getActualRTEandFONTversion(uint8_t *RTEhigh, uint8_t *RTElow, uint8_t *FONThigh, uint8_t *FONTlow)
3016 { 3016 {
3017 if(RTEhigh && RTElow) 3017 if(RTEhigh && RTElow)
3018 { 3018 {
3019 *RTEhigh = RTEactualHigh; 3019 *RTEhigh = RTEactualHigh;
3029 3029
3030 uint8_t getLicence(void) 3030 uint8_t getLicence(void)
3031 { 3031 {
3032 return hardwareDataGetPointer()->primaryLicence; 3032 return hardwareDataGetPointer()->primaryLicence;
3033 } 3033 }
3034 3034 #endif
3035 3035
3036 void firmwareGetDate(RTC_DateTypeDef *SdateOutput) 3036 void firmwareGetDate(RTC_DateTypeDef *SdateOutput)
3037 { 3037 {
3038 SdateOutput->Year = firmwareDataGetPointer()->release_year; 3038 SdateOutput->Year = firmwareDataGetPointer()->release_year;
3039 SdateOutput->Month = firmwareDataGetPointer()->release_month; 3039 SdateOutput->Month = firmwareDataGetPointer()->release_month;