Infineon MOTIX™ MCU TLE988x/9x Device Family SDK
tle_device.h
Go to the documentation of this file.
1 /*
2  ***********************************************************************************************************************
3  *
4  * Copyright (c) Infineon Technologies AG
5  * All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without modification,are permitted provided that the
8  * following conditions are met:
9  *
10  * Redistributions of source code must retain the above copyright notice, this list of conditions and the following
11  * disclaimer.
12  *
13  * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the
14  * following disclaimer in the documentation and/or other materials provided with the distribution.
15  *
16  * Neither the name of the copyright holders nor the names of its contributors may be used to endorse or promote
17  * products derived from this software without specific prior written permission.
18  *
19  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
20  * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21  * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
22  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
23  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
24  * WHETHER IN CONTRACT, STRICT LIABILITY,OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
25  * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26  *
27  **********************************************************************************************************************/
39 /*******************************************************************************
40 ** Author(s) Identity **
41 ********************************************************************************
42 ** Initials Name **
43 ** ---------------------------------------------------------------------------**
44 ** DM Daniel Mysliwitz **
45 ** BG Blandine Guillot **
46 ** JO Julia Ott **
47 ** PS Patrik Schwarz **
48 *******************************************************************************/
49 
50 /*******************************************************************************
51 ** Revision Control History **
52 ********************************************************************************
53 ** V0.1.0: 2019-10-28, DM: Initial version **
54 ** V0.2.0: 2020-04-28, BG: Updated revision history format **
55 ** V0.2.1: 2020-09-16, DM: BRDV_initCP() call to TLE_init() added **
56 ** V0.2.2: 2020-10-21, BG: EP-537: Updated placement for interrupt init and **
57 ** added placeholder for CAN **
58 ** V0.2.3: 2020-10-21, BG: EP-539: Considered return codes for TLE_init **
59 ** V0.2.4: 2020-10-22, JO: EP-539: Removed dependency of the init functions **
60 ** on previous error codes in TLE_init **
61 ** V0.2.5: 2020-10-26, BG: EP-550: Added missing ADC2 initialization in **
62 ** TLE_init() **
63 ** V0.2.6: 2020-11-12, JO: EP-590: Removed \param none and \return none to **
64 ** avoid doxygen warning **
65 ** V0.2.7: 2020-11-20, BG: EP-610: Corrected MISRA 2012 errors **
66 ** The following rules are globally deactivated: **
67 ** - Info 774: Boolean within 'if' always evaluates **
68 ** to False/True **
69 ** V0.2.8: 2020-12-18, BG: EP-652: Corrected name of error code variable **
70 ** V0.3.0: 2020-12-30, JO: EP-659: Added missing CANTRX initialization in **
71 ** TLE_init() (function CANTRX_init) **
72 ** V0.3.1: 2021-02-02, BG: EP-654: Separated CAN into CANCONTR and CANTRX **
73 ** V0.3.2: 2021-04-23, JO: EP-776: Added and initialized global variables **
74 ** UC_FLASH0_UBSL_SIZE, UC_FLASH0_UDATA_START, **
75 ** UC_FLASH0_UDATA_SIZE **
76 ** V0.3.3: 2021-06-08, BG: EP-685: Activated the init function for DMA **
77 ** V0.3.4: 2021-11-12, JO: EP-937: Updated copyright and branding **
78 ** V0.3.5: 2023-04-04, PS: EP-1141: Correct MISRA warnings **
79 ** V0.3.6: 2023-04-06, JO: EP-1143: Added error handling for module used in **
80 ** Config Wizard but not enabled in RTE/package **
81 ** manager **
82 ** V0.3.7: 2023-05-09, BG: EP-1428: Updated calculation of UBSL region size **
83 ** with FW API user_nvm_config_get(**) after SVD **
84 ** update **
85 ** V0.3.8: 2023-10-19, JO: EP-1471: Corrected SDADC handling when using **
86 ** a device without SDADC **
87 ** V0.3.9: 2023-05-06, JO: EP-1481: Corrected calculation of **
88 ** UC_FLASH0_UBSL_SIZE **
89 *******************************************************************************/
90 
91 #ifndef _TLE_DEVICE_H
92 #define _TLE_DEVICE_H
93 
94 /*******************************************************************************
95 ** Includes **
96 *******************************************************************************/
97 
98 #include "tle_variants.h"
99 #include "RTE_Components.h"
100 
101 #ifdef RTE_DEVICE_TLELIB_ADC1
102  #include "adc1.h"
103 #endif
104 #ifdef RTE_DEVICE_TLELIB_ADC2
105  #include "adc2.h"
106 #endif
107 #ifdef RTE_DEVICE_TLELIB_BDRV
108  #include "bdrv.h"
109 #endif
110 #ifdef RTE_DEVICE_TLELIB_BOOTROM
111  #include "bootrom.h"
112 #endif
113 #ifdef RTE_DEVICE_TLELIB_CANCONTR
114  #include "can.h"
115 #endif
116 #ifdef RTE_DEVICE_TLELIB_CANTRX
117  #include "cantrx.h"
118 #endif
119 #ifdef RTE_DEVICE_TLELIB_CCU7
120  #include "ccu7.h"
121 #endif
122 #ifdef RTE_DEVICE_TLELIB_CSACSC
123  #include "csacsc.h"
124 #endif
125 #ifdef RTE_DEVICE_TLELIB_DMA
126  #include "dma.h"
127 #endif
128 #ifdef RTE_DEVICE_TLELIB_GPIO
129  #include "gpio.h"
130 #endif
131 #ifdef RTE_DEVICE_TLELIB_GPT12
132  #include "gpt12.h"
133 #endif
134 #ifdef RTE_DEVICE_TLELIB_INT
135  #include "int.h"
136 #endif
137 #ifdef RTE_DEVICE_TLELIB_ISR
138  #include "isr.h"
139 #endif
140 #ifdef RTE_DEVICE_TLELIB_MON
141  #include "mon.h"
142 #endif
143 #ifdef RTE_DEVICE_TLELIB_PMU
144  #include "pmu.h"
145 #endif
146 #ifdef RTE_DEVICE_TLELIB_SCU
147  #include "scu.h"
148 #endif
149 #ifdef RTE_DEVICE_TLELIB_SDADC
150  #include "sdadc.h"
151 #endif
152 #ifdef RTE_DEVICE_TLELIB_SSC
153  #include "ssc.h"
154 #endif
155 #ifdef RTE_DEVICE_TLELIB_TIMER2X
156  #include "timer2x.h"
157 #endif
158 #ifdef RTE_DEVICE_TLELIB_UART
159  #include "uart.h"
160 #endif
161 
162 /*******************************************************************************
163 ** Global Variable Declarations **
164 *******************************************************************************/
168 
169 
170 /*******************************************************************************
171 ** Global Function Declarations **
172 *******************************************************************************/
177 sint8 TLE_init(void);
178 
179 #endif
ADC1 low level access library.
ADC2 low level access library.
Bridge Driver low level access library.
BootROM low level access library.
CAN low level access library.
CANTRX low level access library.
CCU7 low level access library.
CSACSC low level access library.
Direct Memory Access low level access library.
GPIO low level access library.
GPT12 low level access library.
Interrupt low level access library.
Interrupt Service Routines low level access library.
High Voltage Monitor Input low level access library.
PMU low level access library.
System Control Unit low level access library.
Sigma Delta ADC low level access library.
High-Speed Synchronous Serial Interface low level access library.
Timer20/Timer21 low level access library.
uint32 UC_FLASH0_UDATA_SIZE
Definition: tle_device.c:55
sint8 TLE_init(void)
Initialize the TLE modules.
Definition: tle_device.c:168
uint32 UC_FLASH0_UBSL_SIZE
Definition: tle_device.c:53
uint32 UC_FLASH0_UDATA_START
Definition: tle_device.c:54
Device specific memory layout defines and features.
int8_t sint8
8 bit signed value
Definition: types.h:225
uint32_t uint32
32 bit unsigned value
Definition: types.h:222
UART low level access library.