comparison BootLoader/Src/tComm_mini.c @ 1016:0dd92e9b70a2 BootloaderOstc5

Bootloader use compressed fonts: The previous Bootloader was larger than 128k => not fitting into the first sectors of the second flash bank. Most memory is occupied by the two fonts in use. In order to make the bootloader small enough for the bootloader update function the fonts need to be compressed. To avoid code changes in visualization functions the compressed fonts are decompressed into RAM and then used in the same way as before.
author Ideenmodellierer
date Wed, 28 May 2025 17:20:44 +0200
parents f1b78bc8de10
children 9d9d506a82d3
comparison
equal deleted inserted replaced
1015:4ef0511c6665 1016:0dd92e9b70a2
197 197
198 if(tCscreen.FBStartAdress == 0) 198 if(tCscreen.FBStartAdress == 0)
199 { 199 {
200 GFX_hwBackgroundOn(); 200 GFX_hwBackgroundOn();
201 tCscreen.FBStartAdress = getFrame(18); 201 tCscreen.FBStartAdress = getFrame(18);
202 write_content_simple(&tCscreen, 0, 800, 480-24, &FontT24,"Exit",CLUT_ButtonSurfaceScreen); 202 write_content_simple(&tCscreen, 0, 800, 480-24, &FontT24min,"Exit",CLUT_ButtonSurfaceScreen);
203 write_content_simple(&tCscreen, 800 - 70, 800, 480-24, &FontT24,"Signal",CLUT_ButtonSurfaceScreen); 203 write_content_simple(&tCscreen, 800 - 70, 800, 480-24, &FontT24min,"Signal",CLUT_ButtonSurfaceScreen);
204 204
205 if(receiveStartByteUart == BYTE_SERVICE_MODE) 205 if(receiveStartByteUart == BYTE_SERVICE_MODE)
206 GFX_write_string(&FontT48, &tCwindow, "Service mode enabled",2); 206 GFX_write_string(&FontT48min, &tCwindow, "Service mode enabled",2);
207 else 207 else
208 GFX_write_string(&FontT48, &tCwindow, "Download mode enabled",2); 208 GFX_write_string(&FontT48min, &tCwindow, "Download mode enabled",2);
209 GFX_SetFramesTopBottom(tCscreen.FBStartAdress, 0,480); 209 GFX_SetFramesTopBottom(tCscreen.FBStartAdress, 0,480);
210 display_text[0] = 0; 210 display_text[0] = 0;
211 display_text[255] = 0; 211 display_text[255] = 0;
212 } 212 }
213 else if(display_text[255]) 213 else if(display_text[255])
215 display_text[(uint8_t)display_text[255]] = 0; 215 display_text[(uint8_t)display_text[255]] = 0;
216 localString[0] = TXT_MINIMAL; 216 localString[0] = TXT_MINIMAL;
217 strcpy (&localString[1],display_text); 217 strcpy (&localString[1],display_text);
218 releaseFrame(18,tCscreen.FBStartAdress); 218 releaseFrame(18,tCscreen.FBStartAdress);
219 tCscreen.FBStartAdress = getFrame(18); 219 tCscreen.FBStartAdress = getFrame(18);
220 write_content_simple(&tCscreen, 0, 800, 480-24, &FontT24,"Exit",CLUT_ButtonSurfaceScreen); 220 write_content_simple(&tCscreen, 0, 800, 480-24, &FontT24min,"Exit",CLUT_ButtonSurfaceScreen);
221 write_content_simple(&tCscreen, 800 - 70, 800, 480-24, &FontT24,"Signal",CLUT_ButtonSurfaceScreen); 221 write_content_simple(&tCscreen, 800 - 70, 800, 480-24, &FontT24min,"Signal",CLUT_ButtonSurfaceScreen);
222 GFX_write_string(&FontT48, &tCwindow, localString,2); 222 GFX_write_string(&FontT48min, &tCwindow, localString,2);
223 GFX_SetFrameTop(tCscreen.FBStartAdress); 223 GFX_SetFrameTop(tCscreen.FBStartAdress);
224 display_text[0] = 0; 224 display_text[0] = 0;
225 display_text[255] = 0; 225 display_text[255] = 0;
226 } 226 }
227 } 227 }