FreeHIL
Loading...
Searching...
No Matches
FH_AO_Init_S.c
Go to the documentation of this file.
1/**
2 * @file
3 * @brief
4 * <b>File Map:</b>\n
5 * <b>FH_Root</b>, Section <b>FH_Perif</b>, <b>FH_AO</b> (Analog Output), <b>Cmd</b> (Command), <b>Init</b>, <b>Init_S</b> (Init Set Address)\n
6 * Functions in this file, set the address of the defined <b>FH_Functions</b>, Section <b>FH_AO</b> (Analog Output), <b>FH_AO_Init_AO01-...</b> to an array of function pointers
7 *
8 * @attention <b>FH</b> user could left this file intact
9 *
10 *******************************************************************************
11 * SPDX-License-Identifier: Apache-2.0
12 *
13 * Copyright 2026 Vahid Hasirchi
14 *
15 * Licensed under the Apache License, Version 2.0 (the "License");
16 * you may not use this file except in compliance with the License.
17 * You may obtain a copy of the License at
18 *
19 * http://www.apache.org/licenses/LICENSE-2.0
20 *
21 * Unless required by applicable law or agreed to in writing, software
22 * distributed under the License is distributed on an "AS IS" BASIS,
23 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
24 * See the License for the specific language governing permissions and
25 * limitations under the License.
26 ********************************************************************************
27
28 *
29 * <b>For more information refer to FreeHIL.com</b>
30 *
31*/
32
33/* Includes ------------------------------------------------------------------*/
35
36#include "../../../../../../../FH_Embedded/FH_Root/FH_General/FH_GeneralFunctions/FH_GeneralFunctions.h"
37
38#ifdef FH_AO01
40#endif
41#ifdef FH_AO02
43#endif
44#ifdef FH_AO03
46#endif
47#ifdef FH_AO04
49#endif
50#ifdef FH_AO05
52#endif
53#ifdef FH_AO06
55#endif
56#ifdef FH_AO07
58#endif
59#ifdef FH_AO08
61#endif
62#ifdef FH_AO09
64#endif
65#ifdef FH_AO10
67#endif
68#ifdef FH_AO11
70#endif
71#ifdef FH_AO12
73#endif
74#ifdef FH_AO13
76#endif
77#ifdef FH_AO14
79#endif
80#ifdef FH_AO15
82#endif
83#ifdef FH_AO16
85#endif
86#ifdef FH_AO17
88#endif
89#ifdef FH_AO18
91#endif
92#ifdef FH_AO19
94#endif
95#ifdef FH_AO20
97#endif
98#ifdef FH_AO21
100#endif
101#ifdef FH_AO22
103#endif
104#ifdef FH_AO23
106#endif
107#ifdef FH_AO24
109#endif
110#ifdef FH_AO25
112#endif
113#ifdef FH_AO26
115#endif
116#ifdef FH_AO27
118#endif
119#ifdef FH_AO28
121#endif
122#ifdef FH_AO29
124#endif
125#ifdef FH_AO30
127#endif
128#ifdef FH_AO31
130#endif
131#ifdef FH_AO32
133#endif
134#ifdef FH_AO33
136#endif
137#ifdef FH_AO34
139#endif
140#ifdef FH_AO35
142#endif
143#ifdef FH_AO36
145#endif
146#ifdef FH_AO37
148#endif
149#ifdef FH_AO38
151#endif
152#ifdef FH_AO39
154#endif
155#ifdef FH_AO40
157#endif
158#ifdef FH_AO41
160#endif
161#ifdef FH_AO42
163#endif
164#ifdef FH_AO43
166#endif
167#ifdef FH_AO44
169#endif
170#ifdef FH_AO45
172#endif
173#ifdef FH_AO46
175#endif
176#ifdef FH_AO47
178#endif
179#ifdef FH_AO48
181#endif
182#ifdef FH_AO49
184#endif
185#ifdef FH_AO50
187#endif
188#ifdef FH_AO51
190#endif
191#ifdef FH_AO52
193#endif
194#ifdef FH_AO53
196#endif
197#ifdef FH_AO54
199#endif
200#ifdef FH_AO55
202#endif
203#ifdef FH_AO56
205#endif
206#ifdef FH_AO57
208#endif
209#ifdef FH_AO58
211#endif
212#ifdef FH_AO59
214#endif
215#ifdef FH_AO60
217#endif
218#ifdef FH_AO61
220#endif
221#ifdef FH_AO62
223#endif
224#ifdef FH_AO63
226#endif
227#ifdef FH_AO64
229#endif
230
231#if FH_AO_MaxPeripheralNumber > 0 // It is configurable in FH_DevicePeripherals.h
232
233/**
234 * @brief This function sets the address of the defined <b>FH_Functions</b>, Section <b>FH_AO</b> (Analog Output), <b>FH_AO_Init_AO01-...</b> to an array of function pointers
235 *
236 * @param FH_AO_Init_FuncPtr
237 * An array of function pointers with FH_AO_Init_FuncPtrModel model
238 *
239 * @return None
240 *
241
242*/
243void FH_AO_Init_S(FH_AO_Init_FuncPtrModel *FH_AO_Init_FuncPtr)
244{
245 for (uint8_t i = 0; i < FH_AO_MaxPeripheralNumber; i++) // if FH_AO_MaxPeripheralNumber > 0
246 {
247 FH_AO_Init_FuncPtr[i] = NULL_PTR; // Initialization of the function pointers with null pointer to prevent pointing to undefined addresses
248 }
249
250 #ifdef FH_AO01
251 FH_AO_Init_FuncPtr[0] = FH_AO_Init_AO01; // Set the function pointer address with the related function address
252 #endif
253 #ifdef FH_AO02
254 FH_AO_Init_FuncPtr[1] = FH_AO_Init_AO02; // Set the function pointer address with the related function address
255 #endif
256 #ifdef FH_AO03
257 FH_AO_Init_FuncPtr[2] = FH_AO_Init_AO03; // Set the function pointer address with the related function address
258 #endif
259 #ifdef FH_AO04
260 FH_AO_Init_FuncPtr[3] = FH_AO_Init_AO04; // Set the function pointer address with the related function address
261 #endif
262 #ifdef FH_AO05
263 FH_AO_Init_FuncPtr[4] = FH_AO_Init_AO05; // Set the function pointer address with the related function address
264 #endif
265 #ifdef FH_AO06
266 FH_AO_Init_FuncPtr[5] = FH_AO_Init_AO06; // Set the function pointer address with the related function address
267 #endif
268 #ifdef FH_AO07
269 FH_AO_Init_FuncPtr[6] = FH_AO_Init_AO07; // Set the function pointer address with the related function address
270 #endif
271 #ifdef FH_AO08
272 FH_AO_Init_FuncPtr[7] = FH_AO_Init_AO08; // Set the function pointer address with the related function address
273 #endif
274 #ifdef FH_AO09
275 FH_AO_Init_FuncPtr[8] = FH_AO_Init_AO09; // Set the function pointer address with the related function address
276 #endif
277 #ifdef FH_AO10
278 FH_AO_Init_FuncPtr[9] = FH_AO_Init_AO10; // Set the function pointer address with the related function address
279 #endif
280 #ifdef FH_AO11
281 FH_AO_Init_FuncPtr[10] = FH_AO_Init_AO11; // Set the function pointer address with the related function address
282 #endif
283 #ifdef FH_AO12
284 FH_AO_Init_FuncPtr[11] = FH_AO_Init_AO12; // Set the function pointer address with the related function address
285 #endif
286 #ifdef FH_AO13
287 FH_AO_Init_FuncPtr[12] = FH_AO_Init_AO13; // Set the function pointer address with the related function address
288 #endif
289 #ifdef FH_AO14
290 FH_AO_Init_FuncPtr[13] = FH_AO_Init_AO14; // Set the function pointer address with the related function address
291 #endif
292 #ifdef FH_AO15
293 FH_AO_Init_FuncPtr[14] = FH_AO_Init_AO15; // Set the function pointer address with the related function address
294 #endif
295 #ifdef FH_AO16
296 FH_AO_Init_FuncPtr[15] = FH_AO_Init_AO16; // Set the function pointer address with the related function address
297 #endif
298 #ifdef FH_AO17
299 FH_AO_Init_FuncPtr[16] = FH_AO_Init_AO17; // Set the function pointer address with the related function address
300 #endif
301 #ifdef FH_AO18
302 FH_AO_Init_FuncPtr[17] = FH_AO_Init_AO18; // Set the function pointer address with the related function address
303 #endif
304 #ifdef FH_AO19
305 FH_AO_Init_FuncPtr[18] = FH_AO_Init_AO19; // Set the function pointer address with the related function address
306 #endif
307 #ifdef FH_AO20
308 FH_AO_Init_FuncPtr[19] = FH_AO_Init_AO20; // Set the function pointer address with the related function address
309 #endif
310 #ifdef FH_AO21
311 FH_AO_Init_FuncPtr[20] = FH_AO_Init_AO21; // Set the function pointer address with the related function address
312 #endif
313 #ifdef FH_AO22
314 FH_AO_Init_FuncPtr[21] = FH_AO_Init_AO22; // Set the function pointer address with the related function address
315 #endif
316 #ifdef FH_AO23
317 FH_AO_Init_FuncPtr[22] = FH_AO_Init_AO23; // Set the function pointer address with the related function address
318 #endif
319 #ifdef FH_AO24
320 FH_AO_Init_FuncPtr[23] = FH_AO_Init_AO24; // Set the function pointer address with the related function address
321 #endif
322 #ifdef FH_AO25
323 FH_AO_Init_FuncPtr[24] = FH_AO_Init_AO25; // Set the function pointer address with the related function address
324 #endif
325 #ifdef FH_AO26
326 FH_AO_Init_FuncPtr[25] = FH_AO_Init_AO26; // Set the function pointer address with the related function address
327 #endif
328 #ifdef FH_AO27
329 FH_AO_Init_FuncPtr[26] = FH_AO_Init_AO27; // Set the function pointer address with the related function address
330 #endif
331 #ifdef FH_AO28
332 FH_AO_Init_FuncPtr[27] = FH_AO_Init_AO28; // Set the function pointer address with the related function address
333 #endif
334 #ifdef FH_AO29
335 FH_AO_Init_FuncPtr[28] = FH_AO_Init_AO29; // Set the function pointer address with the related function address
336 #endif
337 #ifdef FH_AO30
338 FH_AO_Init_FuncPtr[29] = FH_AO_Init_AO30; // Set the function pointer address with the related function address
339 #endif
340 #ifdef FH_AO31
341 FH_AO_Init_FuncPtr[30] = FH_AO_Init_AO31; // Set the function pointer address with the related function address
342 #endif
343 #ifdef FH_AO32
344 FH_AO_Init_FuncPtr[31] = FH_AO_Init_AO32; // Set the function pointer address with the related function address
345 #endif
346 #ifdef FH_AO33
347 FH_AO_Init_FuncPtr[32] = FH_AO_Init_AO33; // Set the function pointer address with the related function address
348 #endif
349 #ifdef FH_AO34
350 FH_AO_Init_FuncPtr[33] = FH_AO_Init_AO34; // Set the function pointer address with the related function address
351 #endif
352 #ifdef FH_AO35
353 FH_AO_Init_FuncPtr[34] = FH_AO_Init_AO35; // Set the function pointer address with the related function address
354 #endif
355 #ifdef FH_AO36
356 FH_AO_Init_FuncPtr[35] = FH_AO_Init_AO36; // Set the function pointer address with the related function address
357 #endif
358 #ifdef FH_AO37
359 FH_AO_Init_FuncPtr[36] = FH_AO_Init_AO37; // Set the function pointer address with the related function address
360 #endif
361 #ifdef FH_AO38
362 FH_AO_Init_FuncPtr[37] = FH_AO_Init_AO38; // Set the function pointer address with the related function address
363 #endif
364 #ifdef FH_AO39
365 FH_AO_Init_FuncPtr[38] = FH_AO_Init_AO39; // Set the function pointer address with the related function address
366 #endif
367 #ifdef FH_AO40
368 FH_AO_Init_FuncPtr[39] = FH_AO_Init_AO40; // Set the function pointer address with the related function address
369 #endif
370 #ifdef FH_AO41
371 FH_AO_Init_FuncPtr[40] = FH_AO_Init_AO41; // Set the function pointer address with the related function address
372 #endif
373 #ifdef FH_AO42
374 FH_AO_Init_FuncPtr[41] = FH_AO_Init_AO42; // Set the function pointer address with the related function address
375 #endif
376 #ifdef FH_AO43
377 FH_AO_Init_FuncPtr[42] = FH_AO_Init_AO43; // Set the function pointer address with the related function address
378 #endif
379 #ifdef FH_AO44
380 FH_AO_Init_FuncPtr[43] = FH_AO_Init_AO44; // Set the function pointer address with the related function address
381 #endif
382 #ifdef FH_AO45
383 FH_AO_Init_FuncPtr[44] = FH_AO_Init_AO45; // Set the function pointer address with the related function address
384 #endif
385 #ifdef FH_AO46
386 FH_AO_Init_FuncPtr[45] = FH_AO_Init_AO46; // Set the function pointer address with the related function address
387 #endif
388 #ifdef FH_AO47
389 FH_AO_Init_FuncPtr[46] = FH_AO_Init_AO47; // Set the function pointer address with the related function address
390 #endif
391 #ifdef FH_AO48
392 FH_AO_Init_FuncPtr[47] = FH_AO_Init_AO48; // Set the function pointer address with the related function address
393 #endif
394 #ifdef FH_AO49
395 FH_AO_Init_FuncPtr[48] = FH_AO_Init_AO49; // Set the function pointer address with the related function address
396 #endif
397 #ifdef FH_AO50
398 FH_AO_Init_FuncPtr[49] = FH_AO_Init_AO50; // Set the function pointer address with the related function address
399 #endif
400 #ifdef FH_AO51
401 FH_AO_Init_FuncPtr[50] = FH_AO_Init_AO51; // Set the function pointer address with the related function address
402 #endif
403 #ifdef FH_AO52
404 FH_AO_Init_FuncPtr[51] = FH_AO_Init_AO52; // Set the function pointer address with the related function address
405 #endif
406 #ifdef FH_AO53
407 FH_AO_Init_FuncPtr[52] = FH_AO_Init_AO53; // Set the function pointer address with the related function address
408 #endif
409 #ifdef FH_AO54
410 FH_AO_Init_FuncPtr[53] = FH_AO_Init_AO54; // Set the function pointer address with the related function address
411 #endif
412 #ifdef FH_AO55
413 FH_AO_Init_FuncPtr[54] = FH_AO_Init_AO55; // Set the function pointer address with the related function address
414 #endif
415 #ifdef FH_AO56
416 FH_AO_Init_FuncPtr[55] = FH_AO_Init_AO56; // Set the function pointer address with the related function address
417 #endif
418 #ifdef FH_AO57
419 FH_AO_Init_FuncPtr[56] = FH_AO_Init_AO57; // Set the function pointer address with the related function address
420 #endif
421 #ifdef FH_AO58
422 FH_AO_Init_FuncPtr[57] = FH_AO_Init_AO58; // Set the function pointer address with the related function address
423 #endif
424 #ifdef FH_AO59
425 FH_AO_Init_FuncPtr[58] = FH_AO_Init_AO59; // Set the function pointer address with the related function address
426 #endif
427 #ifdef FH_AO60
428 FH_AO_Init_FuncPtr[59] = FH_AO_Init_AO60; // Set the function pointer address with the related function address
429 #endif
430 #ifdef FH_AO61
431 FH_AO_Init_FuncPtr[60] = FH_AO_Init_AO61; // Set the function pointer address with the related function address
432 #endif
433 #ifdef FH_AO62
434 FH_AO_Init_FuncPtr[61] = FH_AO_Init_AO62; // Set the function pointer address with the related function address
435 #endif
436 #ifdef FH_AO63
437 FH_AO_Init_FuncPtr[62] = FH_AO_Init_AO63; // Set the function pointer address with the related function address
438 #endif
439 #ifdef FH_AO64
440 FH_AO_Init_FuncPtr[63] = FH_AO_Init_AO64; // Set the function pointer address with the related function address
441 #endif
442}
443
444#endif