distortos  v0.7.0
object-oriented C++ RTOS for microcontrollers
BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION.h
Go to the documentation of this file.
1 
12 #ifndef INCLUDE_DISTORTOS_INTERNAL_BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION_H_
13 #define INCLUDE_DISTORTOS_INTERNAL_BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION_H_
14 
15 #include "distortos/CONCATENATE.h"
16 
17 /*---------------------------------------------------------------------------------------------------------------------+
18 | global types
19 +---------------------------------------------------------------------------------------------------------------------*/
20 
22 typedef void (LowLevelInitializer)(void);
23 
24 /*---------------------------------------------------------------------------------------------------------------------+
25 | global defines
26 +---------------------------------------------------------------------------------------------------------------------*/
27 
28 #define PRIORITY_STRING_0 "00"
29 #define PRIORITY_STRING_1 "01"
30 #define PRIORITY_STRING_2 "02"
31 #define PRIORITY_STRING_3 "03"
32 #define PRIORITY_STRING_4 "04"
33 #define PRIORITY_STRING_5 "05"
34 #define PRIORITY_STRING_6 "06"
35 #define PRIORITY_STRING_7 "07"
36 #define PRIORITY_STRING_8 "08"
37 #define PRIORITY_STRING_9 "09"
38 
39 #define PRIORITY_STRING_10 "10"
40 #define PRIORITY_STRING_11 "11"
41 #define PRIORITY_STRING_12 "12"
42 #define PRIORITY_STRING_13 "13"
43 #define PRIORITY_STRING_14 "14"
44 #define PRIORITY_STRING_15 "15"
45 #define PRIORITY_STRING_16 "16"
46 #define PRIORITY_STRING_17 "17"
47 #define PRIORITY_STRING_18 "18"
48 #define PRIORITY_STRING_19 "19"
49 
50 #define PRIORITY_STRING_20 "20"
51 #define PRIORITY_STRING_21 "21"
52 #define PRIORITY_STRING_22 "22"
53 #define PRIORITY_STRING_23 "23"
54 #define PRIORITY_STRING_24 "24"
55 #define PRIORITY_STRING_25 "25"
56 #define PRIORITY_STRING_26 "26"
57 #define PRIORITY_STRING_27 "27"
58 #define PRIORITY_STRING_28 "28"
59 #define PRIORITY_STRING_29 "29"
60 
61 #define PRIORITY_STRING_30 "30"
62 #define PRIORITY_STRING_31 "31"
63 #define PRIORITY_STRING_32 "32"
64 #define PRIORITY_STRING_33 "33"
65 #define PRIORITY_STRING_34 "34"
66 #define PRIORITY_STRING_35 "35"
67 #define PRIORITY_STRING_36 "36"
68 #define PRIORITY_STRING_37 "37"
69 #define PRIORITY_STRING_38 "38"
70 #define PRIORITY_STRING_39 "39"
71 
72 #define PRIORITY_STRING_40 "40"
73 #define PRIORITY_STRING_41 "41"
74 #define PRIORITY_STRING_42 "42"
75 #define PRIORITY_STRING_43 "43"
76 #define PRIORITY_STRING_44 "44"
77 #define PRIORITY_STRING_45 "45"
78 #define PRIORITY_STRING_46 "46"
79 #define PRIORITY_STRING_47 "47"
80 #define PRIORITY_STRING_48 "48"
81 #define PRIORITY_STRING_49 "49"
82 
83 #define PRIORITY_STRING_50 "50"
84 #define PRIORITY_STRING_51 "51"
85 #define PRIORITY_STRING_52 "52"
86 #define PRIORITY_STRING_53 "53"
87 #define PRIORITY_STRING_54 "54"
88 #define PRIORITY_STRING_55 "55"
89 #define PRIORITY_STRING_56 "56"
90 #define PRIORITY_STRING_57 "57"
91 #define PRIORITY_STRING_58 "58"
92 #define PRIORITY_STRING_59 "59"
93 
94 #define PRIORITY_STRING_60 "60"
95 #define PRIORITY_STRING_61 "61"
96 #define PRIORITY_STRING_62 "62"
97 #define PRIORITY_STRING_63 "63"
98 #define PRIORITY_STRING_64 "64"
99 #define PRIORITY_STRING_65 "65"
100 #define PRIORITY_STRING_66 "66"
101 #define PRIORITY_STRING_67 "67"
102 #define PRIORITY_STRING_68 "68"
103 #define PRIORITY_STRING_69 "69"
104 
105 #define PRIORITY_STRING_70 "70"
106 #define PRIORITY_STRING_71 "71"
107 #define PRIORITY_STRING_72 "72"
108 #define PRIORITY_STRING_73 "73"
109 #define PRIORITY_STRING_74 "74"
110 #define PRIORITY_STRING_75 "75"
111 #define PRIORITY_STRING_76 "76"
112 #define PRIORITY_STRING_77 "77"
113 #define PRIORITY_STRING_78 "78"
114 #define PRIORITY_STRING_79 "79"
115 
116 #define PRIORITY_STRING_80 "80"
117 #define PRIORITY_STRING_81 "81"
118 #define PRIORITY_STRING_82 "82"
119 #define PRIORITY_STRING_83 "83"
120 #define PRIORITY_STRING_84 "84"
121 #define PRIORITY_STRING_85 "85"
122 #define PRIORITY_STRING_86 "86"
123 #define PRIORITY_STRING_87 "87"
124 #define PRIORITY_STRING_88 "88"
125 #define PRIORITY_STRING_89 "89"
126 
127 #define PRIORITY_STRING_90 "90"
128 #define PRIORITY_STRING_91 "91"
129 #define PRIORITY_STRING_92 "92"
130 #define PRIORITY_STRING_93 "93"
131 #define PRIORITY_STRING_94 "94"
132 #define PRIORITY_STRING_95 "95"
133 #define PRIORITY_STRING_96 "96"
134 #define PRIORITY_STRING_97 "97"
135 #define PRIORITY_STRING_98 "98"
136 #define PRIORITY_STRING_99 "99"
137 
144 #define PRIORITY_STRING(priority) CONCATENATE2(PRIORITY_STRING_, priority)
145 
154 #define BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION(priority, function, sectionPrefix) \
155  __attribute__ ((section(sectionPrefix PRIORITY_STRING(priority)), used)) \
156  static LowLevelInitializer* const CONCATENATE2(lowLevelInitializerPointer, __COUNTER__) = function
157 
158 #endif /* INCLUDE_DISTORTOS_INTERNAL_BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION_H_ */
CONCATENATE() macros.
void() LowLevelInitializer(void)
low-level initializer function
Definition: BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION.h:22