Mercurial > public > ostc4
annotate Discovery/Inc/gfx_fonts.h @ 892:0e084e5554a8 Evo_2_23
Smal modification slow exit counter:
The slow exit counter is not only activated if deco obligations have been completed and if the dive time is longer than 15 minutes.
author | ideenmodellierer |
---|---|
date | Tue, 10 Sep 2024 21:18:36 +0200 |
parents | bc6c90e20d9e |
children |
rev | line source |
---|---|
38 | 1 /////////////////////////////////////////////////////////////////////////////// |
2 /// -*- coding: UTF-8 -*- | |
3 /// | |
4 /// \file Discovery/Inc/gfx_fonts.h | |
5 /// \brief Header file to control placement of font in STM32 Flash | |
6 /// \author heinrichs weikamp gmbh | |
7 /// \date 14-Aug-2014 | |
8 /// | |
9 /// $Id$ | |
10 /////////////////////////////////////////////////////////////////////////////// | |
11 /// \par Copyright (c) 2014-2018 Heinrichs Weikamp gmbh | |
12 /// | |
13 /// This program is free software: you can redistribute it and/or modify | |
14 /// it under the terms of the GNU General Public License as published by | |
15 /// the Free Software Foundation, either version 3 of the License, or | |
16 /// (at your option) any later version. | |
17 /// | |
18 /// This program is distributed in the hope that it will be useful, | |
19 /// but WITHOUT ANY WARRANTY; without even the implied warranty of | |
20 /// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
21 /// GNU General Public License for more details. | |
22 /// | |
23 /// You should have received a copy of the GNU General Public License | |
24 /// along with this program. If not, see <http://www.gnu.org/licenses/>. | |
25 ////////////////////////////////////////////////////////////////////////////// | |
26 | |
27 /* Define to prevent recursive inclusion -------------------------------------*/ | |
28 #ifndef GFX_FONTS_H | |
29 #define GFX_FONTS_H | |
30 | |
31 #include "gfx.h" | |
32 | |
33 // From image_heinrichs_weikamp.c | |
34 enum { indexHWcolorSIZE = 256 }; | |
35 | |
36 // Forward declarations | |
37 // | |
38 // 2018-01-01 jDG: | |
39 // - the exact address is fixed in linker script CPU1-F429.ld, | |
40 // so that every font can be used even when not included in the actual | |
41 // binary (boot-loader, fonts, or firmware). | |
42 // | |
43 // - Actual font data is defined by the OSTC4/FontPack project, that shall | |
44 // be loaded before the firmware is executed. | |
45 // | |
46 // - Font directory starts at address 0x081E0000. Each header is 12 bytes. | |
47 // A 0xFFFFFFFF (32 bits) marks the directory's end. | |
48 // It is stored between __font_directory and __font_directory_end; | |
49 // | |
50 // - Font data (chars) is stored after 0x08132040 (end of font's SFirmareData). | |
51 // So there is space for 0x081E0000 - 0x08132040 = ADFC0 = 694 KB of fonts. | |
52 // Actual data is stored between __upper_font_data and __upper_font_data_end, | |
53 // and uses 0x081b9a3a - 0x08132040 = 879FA = 542 KB. | |
54 // | |
870 | 55 |
38 | 56 extern const tFont Awe48; |
57 extern const tFont FontT24; | |
58 extern const tFont FontT42; | |
59 extern const tFont FontT48; | |
60 extern const tFont FontT54; | |
61 extern const tFont FontT84; | |
62 extern const tFont FontT105; | |
63 extern const tFont FontT144; | |
64 | |
567 | 65 extern const tFont FontT84Spaced; |
66 | |
67 extern const tFont FontT54Extra; | |
68 extern const tFont FontT84Extra; | |
69 extern const tFont FontT105Extra; | |
38 | 70 extern const tFont Batt24; |
71 | |
72 extern const tImage ImgHWcolor; | |
73 extern const tImage ImgOSTC; | |
74 | |
75 extern const uint32_t indexHWcolor[indexHWcolorSIZE]; | |
76 | |
77 // Macro to store in UPPER rom font sections | |
44
7c786c7aa99b
Placed directory sections in firmware memory space
Ideenmodellierer
parents:
38
diff
changeset
|
78 /* TODO: Looking at older map files the directories should be placed within the firmware memory */ |
7c786c7aa99b
Placed directory sections in firmware memory space
Ideenmodellierer
parents:
38
diff
changeset
|
79 /* As well as the image data => to be confirmed */ |
74 | 80 #define UPPER_FONT_DIRECTORY __attribute__ (( used, section(".upper_font_directory") )) |
569 | 81 #define LOWER_FONT_DIRECTORY __attribute__ (( used, section(".lower_font_directory") )) /* store new fonts within firmware image to avoid fontlib update */ |
44
7c786c7aa99b
Placed directory sections in firmware memory space
Ideenmodellierer
parents:
38
diff
changeset
|
82 |
7c786c7aa99b
Placed directory sections in firmware memory space
Ideenmodellierer
parents:
38
diff
changeset
|
83 #define UPPER_IMAGE_DIRECTORY __attribute__(( section(".lower_image_directory") )) |
7c786c7aa99b
Placed directory sections in firmware memory space
Ideenmodellierer
parents:
38
diff
changeset
|
84 #define UPPER_IMAGES __attribute__(( section(".lower_images") )) |
38 | 85 |
86 #endif // GFX_FONTS_H |