Clock_Ip_PBcfg.c 40 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174
  1. /* TEXT BELOW IS USED AS SETTING FOR TOOLS *************************************
  2. !!GlobalInfo
  3. product: Clocks v7.0
  4. processor: S32K144
  5. package_id: S32K144_LQFP100
  6. mcu_data: PlatformSDK_S32K1_2021_08
  7. processor_version: 0.0.0
  8. * BE CAREFUL MODIFYING THIS COMMENT - IT IS YAML SETTINGS FOR TOOLS **********/
  9. /*==================================================================================================
  10. * Project : RTD AUTOSAR 4.4
  11. * Platform : CORTEXM
  12. * Peripheral :
  13. * Dependencies : none
  14. *
  15. * Autosar Version : 4.4.0
  16. * Autosar Revision : ASR_REL_4_4_REV_0000
  17. * Autosar Conf.Variant :
  18. * SW Version : 1.0.0
  19. * Build Version : S32K1_RTD_1_0_0_ASR_REL_4_4_REV_0000_20210810
  20. *
  21. * (c) Copyright 2020 NXP Semiconductors
  22. * All Rights Reserved.
  23. *
  24. * NXP Confidential. This software is owned or controlled by NXP and may only be
  25. * used strictly in accordance with the applicable license terms. By expressly
  26. * accepting such terms or by downloading, installing, activating and/or otherwise
  27. * using the software, you are agreeing that you have read, and that you agree to
  28. * comply with and are bound by, such license terms. If you do not agree to be
  29. * bound by the applicable license terms, then you may not retain, install,
  30. * activate or otherwise use the software.
  31. ==================================================================================================*/
  32. /**
  33. * @file Clock_Ip_PBcfg.c
  34. * @version 1.0.0
  35. *
  36. * @brief AUTOSAR Mcu - Post-Build(PB) configuration file code template.
  37. * @details Code template for Post-Build(PB) configuration file generation.
  38. *
  39. * @addtogroup CLOCK_DRIVER_CONFIGURATION Clock Driver
  40. * @{
  41. */
  42. #ifdef __cplusplus
  43. extern "C"{
  44. #endif
  45. /*==================================================================================================
  46. INCLUDE FILES
  47. 1) system and project includes
  48. 2) needed interfaces from external units
  49. 3) internal and external interfaces from this unit
  50. ==================================================================================================*/
  51. #include "Clock_Ip_PBcfg.h"
  52. #include "StandardTypes.h"
  53. #include "Clock_Ip.h"
  54. #include "Clock_Ip_Private.h"
  55. /*==================================================================================================
  56. * SOURCE FILE VERSION INFORMATION
  57. ==================================================================================================*/
  58. #define CLOCK_IP_PBCFG_VENDOR_ID_C 43
  59. #define CLOCK_IP_PBCFG_AR_RELEASE_MAJOR_VERSION_C 4
  60. #define CLOCK_IP_PBCFG_AR_RELEASE_MINOR_VERSION_C 4
  61. #define CLOCK_IP_PBCFG_AR_RELEASE_REVISION_VERSION_C 0
  62. #define CLOCK_IP_PBCFG_SW_MAJOR_VERSION_C 1
  63. #define CLOCK_IP_PBCFG_SW_MINOR_VERSION_C 0
  64. #define CLOCK_IP_PBCFG_SW_PATCH_VERSION_C 0
  65. /*==================================================================================================
  66. * FILE VERSION CHECKS
  67. ==================================================================================================*/
  68. /* Check if source file and Clock_Ip_PBcfg.h file are of the same vendor */
  69. #if (CLOCK_IP_PBCFG_VENDOR_ID_C != CLOCK_IP_PBCFG_VENDOR_ID)
  70. #error "Clock_Ip_PBcfg.c and Clock_Ip_PBcfg.h have different vendor ids"
  71. #endif
  72. /* Check if source file and Clock_Ip_PBcfg.h file are of the same Autosar version */
  73. #if ((CLOCK_IP_PBCFG_AR_RELEASE_MAJOR_VERSION_C != CLOCK_IP_PBCFG_AR_RELEASE_MAJOR_VERSION) || \
  74. (CLOCK_IP_PBCFG_AR_RELEASE_MINOR_VERSION_C != CLOCK_IP_PBCFG_AR_RELEASE_MINOR_VERSION) || \
  75. (CLOCK_IP_PBCFG_AR_RELEASE_REVISION_VERSION_C != CLOCK_IP_PBCFG_AR_RELEASE_REVISION_VERSION) \
  76. )
  77. #error "AutoSar Version Numbers of Clock_Ip_PBcfg.c and Clock_Ip_PBcfg.h are different"
  78. #endif
  79. /* Check if source file and Clock_Ip_PBcfg.h file are of the same Software version */
  80. #if ((CLOCK_IP_PBCFG_SW_MAJOR_VERSION_C != CLOCK_IP_PBCFG_SW_MAJOR_VERSION) || \
  81. (CLOCK_IP_PBCFG_SW_MINOR_VERSION_C != CLOCK_IP_PBCFG_SW_MINOR_VERSION) || \
  82. (CLOCK_IP_PBCFG_SW_PATCH_VERSION_C != CLOCK_IP_PBCFG_SW_PATCH_VERSION) \
  83. )
  84. #error "Software Version Numbers of Clock_Ip_PBcfg.c and Clock_Ip_PBcfg.h are different"
  85. #endif
  86. #ifndef DISABLE_MCAL_INTERMODULE_ASR_CHECK
  87. /* Check if source file and StandardTypes.h file are of the same Autosar version */
  88. #if ((CLOCK_IP_PBCFG_AR_RELEASE_MAJOR_VERSION_C != STD_AR_RELEASE_MAJOR_VERSION) || \
  89. (CLOCK_IP_PBCFG_AR_RELEASE_MINOR_VERSION_C != STD_AR_RELEASE_MINOR_VERSION) \
  90. )
  91. #error "AutoSar Version Numbers of Clock_Ip_PBcfg.c and StandardTypes.h are different"
  92. #endif
  93. #endif /* DISABLE_MCAL_INTERMODULE_ASR_CHECK */
  94. /* Check if source file and Clock_Ip.h file are of the same vendor */
  95. #if (CLOCK_IP_PBCFG_VENDOR_ID_C != CLOCK_IP_VENDOR_ID)
  96. #error "Clock_Ip_PBcfg.c and Clock_Ip.h have different vendor ids"
  97. #endif
  98. /* Check if source file and Clock_Ip.h file are of the same Autosar version */
  99. #if ((CLOCK_IP_PBCFG_AR_RELEASE_MAJOR_VERSION_C != CLOCK_IP_AR_RELEASE_MAJOR_VERSION) || \
  100. (CLOCK_IP_PBCFG_AR_RELEASE_MINOR_VERSION_C != CLOCK_IP_AR_RELEASE_MINOR_VERSION) || \
  101. (CLOCK_IP_PBCFG_AR_RELEASE_REVISION_VERSION_C != CLOCK_IP_AR_RELEASE_REVISION_VERSION) \
  102. )
  103. #error "AutoSar Version Numbers of Clock_Ip_PBcfg.c and Clock_Ip.h are different"
  104. #endif
  105. /* Check if source file and Clock_Ip.h file are of the same Software version */
  106. #if ((CLOCK_IP_PBCFG_SW_MAJOR_VERSION_C != CLOCK_IP_SW_MAJOR_VERSION) || \
  107. (CLOCK_IP_PBCFG_SW_MINOR_VERSION_C != CLOCK_IP_SW_MINOR_VERSION) || \
  108. (CLOCK_IP_PBCFG_SW_PATCH_VERSION_C != CLOCK_IP_SW_PATCH_VERSION) \
  109. )
  110. #error "Software Version Numbers of Clock_Ip_PBcfg.c and Clock_Ip.h are different"
  111. #endif
  112. /* Check if source file and Clock_Ip_Private.h file are of the same vendor */
  113. #if (CLOCK_IP_PBCFG_VENDOR_ID_C != CLOCK_IP_PRIVATE_VENDOR_ID)
  114. #error "Clock_Ip_PBcfg.c and Clock_Ip_Private.h have different vendor ids"
  115. #endif
  116. /* Check if source file and Clock_Ip_Private.h file are of the same Autosar version */
  117. #if ((CLOCK_IP_PBCFG_AR_RELEASE_MAJOR_VERSION_C != CLOCK_IP_PRIVATE_AR_RELEASE_MAJOR_VERSION) || \
  118. (CLOCK_IP_PBCFG_AR_RELEASE_MINOR_VERSION_C != CLOCK_IP_PRIVATE_AR_RELEASE_MINOR_VERSION) || \
  119. (CLOCK_IP_PBCFG_AR_RELEASE_REVISION_VERSION_C != CLOCK_IP_PRIVATE_AR_RELEASE_REVISION_VERSION) \
  120. )
  121. #error "AutoSar Version Numbers of Clock_Ip_PBcfg.c and Clock_Ip_Private.h are different"
  122. #endif
  123. /* Check if source file and Clock_Ip_Private.h file are of the same Software version */
  124. #if ((CLOCK_IP_PBCFG_SW_MAJOR_VERSION_C != CLOCK_IP_PRIVATE_SW_MAJOR_VERSION) || \
  125. (CLOCK_IP_PBCFG_SW_MINOR_VERSION_C != CLOCK_IP_PRIVATE_SW_MINOR_VERSION) || \
  126. (CLOCK_IP_PBCFG_SW_PATCH_VERSION_C != CLOCK_IP_PRIVATE_SW_PATCH_VERSION) \
  127. )
  128. #error "Software Version Numbers of Clock_Ip_PBcfg.c and Clock_Ip_Private.h are different"
  129. #endif
  130. /*==================================================================================================
  131. LOCAL TYPEDEFS (STRUCTURES, UNIONS, ENUMS)
  132. ==================================================================================================*/
  133. /*==================================================================================================
  134. LOCAL MACROS
  135. ==================================================================================================*/
  136. /*==================================================================================================
  137. LOCAL CONSTANTS
  138. ==================================================================================================*/
  139. /*==================================================================================================
  140. LOCAL VARIABLES
  141. ==================================================================================================*/
  142. /*==================================================================================================
  143. GLOBAL CONSTANTS
  144. ==================================================================================================*/
  145. /*==================================================================================================
  146. GLOBAL VARIABLES
  147. ==================================================================================================*/
  148. #define MCU_START_SEC_CONFIG_DATA_UNSPECIFIED
  149. #include "Mcu_MemMap.h"
  150. /* TEXT BELOW IS USED AS SETTING FOR TOOLS *************************************
  151. !!Configuration
  152. name: BOARD_BootClockRUN
  153. called_from_default_init: true
  154. outputs:
  155. - {id: ADC0_CLK.outFreq, value: 8 MHz}
  156. - {id: ADC1_CLK.outFreq, value: 8 MHz}
  157. - {id: BUS_CLK.outFreq, value: 48 MHz}
  158. - {id: CLKOUT0_CLK.outFreq, value: 48 MHz}
  159. - {id: CMP0_CLK.outFreq, value: 48 MHz}
  160. - {id: CORE_CLK.outFreq, value: 48 MHz}
  161. - {id: CRC0_CLK.outFreq, value: 48 MHz}
  162. - {id: DMA0_CLK.outFreq, value: 48 MHz}
  163. - {id: DMAMUX0_CLK.outFreq, value: 48 MHz}
  164. - {id: EIM0_CLK.outFreq, value: 48 MHz}
  165. - {id: ERM0_CLK.outFreq, value: 48 MHz}
  166. - {id: EWM0_CLK.outFreq, value: 48 MHz}
  167. - {id: FIRCDIV1_CLK.outFreq, value: 48 MHz}
  168. - {id: FIRCDIV2_CLK.outFreq, value: 48 MHz}
  169. - {id: FIRCOUT.outFreq, value: 48 MHz}
  170. - {id: FLASH_CLK.outFreq, value: 12 MHz}
  171. - {id: FLEXCAN0_CLK.outFreq, value: 48 MHz}
  172. - {id: FLEXCAN1_CLK.outFreq, value: 48 MHz}
  173. - {id: FLEXCAN2_CLK.outFreq, value: 48 MHz}
  174. - {id: FTFC0_CLK.outFreq, value: 12 MHz}
  175. - {id: FTM0_CLK.outFreq, value: 8 MHz}
  176. - {id: FTM1_CLK.outFreq, value: 8 MHz}
  177. - {id: FTM2_CLK.outFreq, value: 8 MHz}
  178. - {id: FTM3_CLK.outFreq, value: 8 MHz}
  179. - {id: FlexIO0_CLK.outFreq, value: 8 MHz}
  180. - {id: FlexIO_CLK.outFreq, value: 8 MHz}
  181. - {id: LPI2C0_CLK.outFreq, value: 8 MHz}
  182. - {id: LPIT0_CLK.outFreq, value: 8 MHz}
  183. - {id: LPO_128K_CLK.outFreq, value: 128 kHz}
  184. - {id: LPO_1K_CLK.outFreq, value: 1 kHz}
  185. - {id: LPO_32K_CLK.outFreq, value: 32 kHz}
  186. - {id: LPO_CLK.outFreq, value: 128 kHz}
  187. - {id: LPSPI0_CLK.outFreq, value: 8 MHz}
  188. - {id: LPSPI1_CLK.outFreq, value: 8 MHz}
  189. - {id: LPSPI2_CLK.outFreq, value: 8 MHz}
  190. - {id: LPTMR0_CLK.outFreq, value: 8 MHz}
  191. - {id: LPUART0_CLK.outFreq, value: 8 MHz}
  192. - {id: LPUART1_CLK.outFreq, value: 8 MHz}
  193. - {id: LPUART2_CLK.outFreq, value: 8 MHz}
  194. - {id: MPU0_CLK.outFreq, value: 48 MHz}
  195. - {id: MSCM0_CLK.outFreq, value: 48 MHz}
  196. - {id: PDB0_CLK.outFreq, value: 48 MHz}
  197. - {id: PDB1_CLK.outFreq, value: 48 MHz}
  198. - {id: PORTA_CLK.outFreq, value: 48 MHz}
  199. - {id: PORTB_CLK.outFreq, value: 48 MHz}
  200. - {id: PORTC_CLK.outFreq, value: 48 MHz}
  201. - {id: PORTD_CLK.outFreq, value: 48 MHz}
  202. - {id: PORTE_CLK.outFreq, value: 48 MHz}
  203. - {id: RTC0_CLK.outFreq, value: 8 MHz}
  204. - {id: RTC_CLK.outFreq, value: 8 MHz}
  205. - {id: RTC_CLKIN.outFreq, value: 32.768 kHz}
  206. - {id: SCGCLKOUT_CLK.outFreq, value: 48 MHz}
  207. - {id: SIRCDIV1_CLK.outFreq, value: 8 MHz}
  208. - {id: SIRCDIV2_CLK.outFreq, value: 8 MHz}
  209. - {id: SIRCOUT.outFreq, value: 8 MHz}
  210. - {id: SOSCDIV1_CLK.outFreq, value: 8 MHz}
  211. - {id: SOSCDIV2_CLK.outFreq, value: 8 MHz}
  212. - {id: SOSCOUT.outFreq, value: 8 MHz}
  213. - {id: SPLLDIV1_CLK.outFreq, value: 48 MHz}
  214. - {id: SPLLDIV2_CLK.outFreq, value: 24 MHz}
  215. - {id: SYS_CLK.outFreq, value: 48 MHz}
  216. - {id: TRACE_CLK.outFreq, value: 48 MHz}
  217. settings:
  218. - {id: DIVBUS.scale, value: '1', locked: true}
  219. - {id: DIVCORE.scale, value: '1', locked: true}
  220. - {id: DIVSLOW.scale, value: '4', locked: true}
  221. - {id: 'HSRUN:DIVBUS.scale', value: '1', locked: true}
  222. - {id: 'HSRUN:DIVCORE.scale', value: '1', locked: true}
  223. - {id: 'HSRUN:DIVSLOW.scale', value: '4', locked: true}
  224. - {id: PREDIV.scale, value: '1', locked: true}
  225. - {id: 'RUN:DIVBUS.scale', value: '1', locked: true}
  226. - {id: 'RUN:DIVCORE.scale', value: '1', locked: true}
  227. - {id: 'RUN:DIVSLOW.scale', value: '4', locked: true}
  228. - {id: SCG_SOSCCSR_SOSCEN_CFG, value: Enabled}
  229. - {id: SCG_SPLLCSR_SPLLEN_CFG, value: Enabled}
  230. - {id: SIRCDIV1.scale, value: '1', locked: true}
  231. - {id: SIRCDIV2.scale, value: '1', locked: true}
  232. - {id: SPLLDIV1.scale, value: '2', locked: true}
  233. - {id: SPLLDIV2.scale, value: '4', locked: true}
  234. - {id: SPLL_mul.scale, value: '24', locked: true}
  235. - {id: 'VLPR:DIVBUS.scale', value: '1', locked: true}
  236. - {id: 'VLPR:DIVCORE.scale', value: '8', locked: true}
  237. - {id: 'VLPR:DIVSLOW.scale', value: '4', locked: true}
  238. - {id: 'VLPR:SCSSEL.sel', value: SIRC}
  239. sources:
  240. - {id: RTC.RTC_CLK_EXT_IN.outFreq, value: 32.768 kHz, enabled: true}
  241. - {id: SOSC.SOSC.outFreq, value: 8 MHz, enabled: true}
  242. * BE CAREFUL MODIFYING THIS COMMENT - IT IS YAML SETTINGS FOR TOOLS **********/
  243. /* *************************************************************************
  244. * Configuration structure for Clock Configuration
  245. * ************************************************************************* */
  246. /*! @brief User Configuration structure clock_Cfg_0 */
  247. const Clock_Ip_ClockConfigType Mcu_aClockConfigPB[1] = {
  248. {
  249. 0U, /* clkConfigId */
  250. 2U, /* ircoscsCount */
  251. 1U, /* xoscsCount */
  252. 1U, /* pllsCount */
  253. 28U, /* selectorsCount */
  254. 20U, /* dividersCount */
  255. 0U, /* dividerTriggersCount */
  256. 0U, /* fracDivsCount */
  257. 4U, /* extClksCount */
  258. 40U, /* gatesCount */
  259. 0U, /* pcfsCount */
  260. 0U, /* cmusCount */
  261. 0U, /* configureFrequenciesCount */
  262. /* IRCOSC initialization. */
  263. {
  264. #if CLOCK_IRCOSCS_NO > 0U
  265. {
  266. SIRC_CLK, /* name */
  267. 1U, /* Enabled ircosc */
  268. 0U, /* Disabled regulator */
  269. 1U, /* Ircosc range */
  270. 1U, /* Ircosc enable in VLP mode */
  271. 0U, /* Ircosc disable in STOP mode */
  272. },
  273. #endif
  274. #if CLOCK_IRCOSCS_NO > 1U
  275. {
  276. FIRC_CLK, /* name */
  277. 1U, /* Enabled ircosc */
  278. 0U, /* Disabled regulator */
  279. 0U, /* Ircosc range */
  280. 0U, /* Ircosc disable in VLP mode */
  281. 0U, /* Ircosc disable in STOP mode */
  282. },
  283. #endif
  284. },
  285. /* XOSC initialization. */
  286. {
  287. #if CLOCK_XOSCS_NO > 0U
  288. {
  289. SOSC_CLK, /* Clock name associated to xosc */
  290. 8000000U, /* External oscillator frequency */
  291. 1U, /* Enable xosc */
  292. 0U, /* Startup stabilization time */
  293. 0U, /* XOSC bypass option */
  294. 0U, /* Comparator is not enabled */
  295. 0U, /* Crystal overdrive protection */
  296. 0U, /* High gain value */
  297. FEATURE_CLOCK_IP_HAS_MONITOR_DISABLE, /* Monitor type */
  298. },
  299. #endif
  300. },
  301. /* PLL initialization. */
  302. {
  303. #if CLOCK_PLLS_NO > 0U
  304. {
  305. SPLL_CLK, /* name */
  306. 1U, /* enable */
  307. SOSC_CLK, /* inputReference */
  308. 0U, /* Bypass */
  309. 1U, /* predivider */
  310. 0U, /* numeratorFracLoopDiv */
  311. 24U, /* mulFactorDiv */
  312. 0U, /* modulation */
  313. 0U, /* Modulaton type: Spread spectrum modulation not bypassed */
  314. 0U, /* modulationPeriod */
  315. 1U, /* incrementStep */
  316. 0U, /* sigmaDelta */
  317. 0U, /* ditherControl */
  318. 0U, /* ditherControlValue */
  319. FEATURE_CLOCK_IP_HAS_MONITOR_DISABLE, /* Monitor type */
  320. },
  321. #endif
  322. },
  323. /* SELECTOR initialization. */
  324. {
  325. #if CLOCK_SELECTORS_NO > 0U
  326. {
  327. SCS_RUN_CLK, /* Clock name associated to selector */
  328. FIRC_CLK, /* Name of the selected input source */
  329. },
  330. #endif
  331. #if CLOCK_SELECTORS_NO > 1U
  332. {
  333. SCS_VLPR_CLK, /* Clock name associated to selector */
  334. SIRC_CLK, /* Name of the selected input source */
  335. },
  336. #endif
  337. #if CLOCK_SELECTORS_NO > 2U
  338. {
  339. SCS_HSRUN_CLK, /* Clock name associated to selector */
  340. FIRC_CLK, /* Name of the selected input source */
  341. },
  342. #endif
  343. #if CLOCK_SELECTORS_NO > 3U
  344. {
  345. SCG_CLKOUT_CLK, /* Clock name associated to selector */
  346. FIRC_CLK, /* Name of the selected input source */
  347. },
  348. #endif
  349. #if CLOCK_SELECTORS_NO > 4U
  350. {
  351. RTC_CLK, /* Clock name associated to selector */
  352. SOSCDIV1_CLK, /* Name of the selected input source */
  353. },
  354. #endif
  355. #if CLOCK_SELECTORS_NO > 5U
  356. {
  357. LPO_CLK, /* Clock name associated to selector */
  358. LPO_128K_CLK, /* Name of the selected input source */
  359. },
  360. #endif
  361. #if CLOCK_SELECTORS_NO > 6U
  362. {
  363. TRACE_CLK, /* Clock name associated to selector */
  364. CORE_CLK, /* Name of the selected input source */
  365. },
  366. #endif
  367. #if CLOCK_SELECTORS_NO > 7U
  368. {
  369. CLKOUT0_CLK, /* Clock name associated to selector */
  370. SCG_CLKOUT_CLK, /* Name of the selected input source */
  371. },
  372. #endif
  373. #if CLOCK_SELECTORS_NO > 8U
  374. {
  375. FTM0_EXT_CLK, /* Clock name associated to selector */
  376. TCLK0_REF_CLK, /* Name of the selected input source */
  377. },
  378. #endif
  379. #if CLOCK_SELECTORS_NO > 9U
  380. {
  381. FTM1_EXT_CLK, /* Clock name associated to selector */
  382. TCLK0_REF_CLK, /* Name of the selected input source */
  383. },
  384. #endif
  385. #if CLOCK_SELECTORS_NO > 10U
  386. {
  387. FTM2_EXT_CLK, /* Clock name associated to selector */
  388. TCLK0_REF_CLK, /* Name of the selected input source */
  389. },
  390. #endif
  391. #if CLOCK_SELECTORS_NO > 11U
  392. {
  393. FTM3_EXT_CLK, /* Clock name associated to selector */
  394. TCLK0_REF_CLK, /* Name of the selected input source */
  395. },
  396. #endif
  397. #if CLOCK_SELECTORS_NO > 12U
  398. {
  399. FTM0_CLK, /* Clock name associated to selector */
  400. SIRCDIV1_CLK, /* Name of the selected input source */
  401. },
  402. #endif
  403. #if CLOCK_SELECTORS_NO > 13U
  404. {
  405. FTM1_CLK, /* Clock name associated to selector */
  406. SIRCDIV1_CLK, /* Name of the selected input source */
  407. },
  408. #endif
  409. #if CLOCK_SELECTORS_NO > 14U
  410. {
  411. FTM2_CLK, /* Clock name associated to selector */
  412. SIRCDIV1_CLK, /* Name of the selected input source */
  413. },
  414. #endif
  415. #if CLOCK_SELECTORS_NO > 15U
  416. {
  417. FTM3_CLK, /* Clock name associated to selector */
  418. SIRCDIV1_CLK, /* Name of the selected input source */
  419. },
  420. #endif
  421. #if CLOCK_SELECTORS_NO > 16U
  422. {
  423. ADC1_CLK, /* Clock name associated to selector */
  424. SIRCDIV2_CLK, /* Name of the selected input source */
  425. },
  426. #endif
  427. #if CLOCK_SELECTORS_NO > 17U
  428. {
  429. LPSPI0_CLK, /* Clock name associated to selector */
  430. SIRCDIV2_CLK, /* Name of the selected input source */
  431. },
  432. #endif
  433. #if CLOCK_SELECTORS_NO > 18U
  434. {
  435. LPSPI1_CLK, /* Clock name associated to selector */
  436. SIRCDIV2_CLK, /* Name of the selected input source */
  437. },
  438. #endif
  439. #if CLOCK_SELECTORS_NO > 19U
  440. {
  441. LPSPI2_CLK, /* Clock name associated to selector */
  442. SIRCDIV2_CLK, /* Name of the selected input source */
  443. },
  444. #endif
  445. #if CLOCK_SELECTORS_NO > 20U
  446. {
  447. LPIT0_CLK, /* Clock name associated to selector */
  448. SIRCDIV2_CLK, /* Name of the selected input source */
  449. },
  450. #endif
  451. #if CLOCK_SELECTORS_NO > 21U
  452. {
  453. ADC0_CLK, /* Clock name associated to selector */
  454. SIRCDIV2_CLK, /* Name of the selected input source */
  455. },
  456. #endif
  457. #if CLOCK_SELECTORS_NO > 22U
  458. {
  459. FlexIO_CLK, /* Clock name associated to selector */
  460. SIRCDIV2_CLK, /* Name of the selected input source */
  461. },
  462. #endif
  463. #if CLOCK_SELECTORS_NO > 23U
  464. {
  465. LPI2C0_CLK, /* Clock name associated to selector */
  466. SIRCDIV2_CLK, /* Name of the selected input source */
  467. },
  468. #endif
  469. #if CLOCK_SELECTORS_NO > 24U
  470. {
  471. LPUART0_CLK, /* Clock name associated to selector */
  472. SIRCDIV2_CLK, /* Name of the selected input source */
  473. },
  474. #endif
  475. #if CLOCK_SELECTORS_NO > 25U
  476. {
  477. LPUART1_CLK, /* Clock name associated to selector */
  478. SIRCDIV2_CLK, /* Name of the selected input source */
  479. },
  480. #endif
  481. #if CLOCK_SELECTORS_NO > 26U
  482. {
  483. LPUART2_CLK, /* Clock name associated to selector */
  484. SIRCDIV2_CLK, /* Name of the selected input source */
  485. },
  486. #endif
  487. #if CLOCK_SELECTORS_NO > 27U
  488. {
  489. LPTMR0_CLK, /* Clock name associated to selector */
  490. SIRCDIV2_CLK, /* Name of the selected input source */
  491. },
  492. #endif
  493. },
  494. /* DIVIDER initialization. */
  495. {
  496. #if CLOCK_DIVIDERS_NO > 0U
  497. {
  498. SIRCDIV1_CLK, /* name */
  499. 1U, /* value */
  500. {
  501. 0U,
  502. }
  503. },
  504. #endif
  505. #if CLOCK_DIVIDERS_NO > 1U
  506. {
  507. SIRCDIV2_CLK, /* name */
  508. 1U, /* value */
  509. {
  510. 0U,
  511. }
  512. },
  513. #endif
  514. #if CLOCK_DIVIDERS_NO > 2U
  515. {
  516. FIRCDIV1_CLK, /* name */
  517. 1U, /* value */
  518. {
  519. 0U,
  520. }
  521. },
  522. #endif
  523. #if CLOCK_DIVIDERS_NO > 3U
  524. {
  525. FIRCDIV2_CLK, /* name */
  526. 1U, /* value */
  527. {
  528. 0U,
  529. }
  530. },
  531. #endif
  532. #if CLOCK_DIVIDERS_NO > 4U
  533. {
  534. SOSCDIV1_CLK, /* name */
  535. 1U, /* value */
  536. {
  537. 0U,
  538. }
  539. },
  540. #endif
  541. #if CLOCK_DIVIDERS_NO > 5U
  542. {
  543. SOSCDIV2_CLK, /* name */
  544. 1U, /* value */
  545. {
  546. 0U,
  547. }
  548. },
  549. #endif
  550. #if CLOCK_DIVIDERS_NO > 6U
  551. {
  552. SPLLDIV1_CLK, /* name */
  553. 2U, /* value */
  554. {
  555. 0U,
  556. }
  557. },
  558. #endif
  559. #if CLOCK_DIVIDERS_NO > 7U
  560. {
  561. SPLLDIV2_CLK, /* name */
  562. 4U, /* value */
  563. {
  564. 0U,
  565. }
  566. },
  567. #endif
  568. #if CLOCK_DIVIDERS_NO > 8U
  569. {
  570. CORE_RUN_CLK, /* name */
  571. 1U, /* value */
  572. {
  573. 0U,
  574. }
  575. },
  576. #endif
  577. #if CLOCK_DIVIDERS_NO > 9U
  578. {
  579. CORE_VLPR_CLK, /* name */
  580. 8U, /* value */
  581. {
  582. 0U,
  583. }
  584. },
  585. #endif
  586. #if CLOCK_DIVIDERS_NO > 10U
  587. {
  588. CORE_HSRUN_CLK, /* name */
  589. 1U, /* value */
  590. {
  591. 0U,
  592. }
  593. },
  594. #endif
  595. #if CLOCK_DIVIDERS_NO > 11U
  596. {
  597. BUS_RUN_CLK, /* name */
  598. 1U, /* value */
  599. {
  600. 0U,
  601. }
  602. },
  603. #endif
  604. #if CLOCK_DIVIDERS_NO > 12U
  605. {
  606. BUS_VLPR_CLK, /* name */
  607. 1U, /* value */
  608. {
  609. 0U,
  610. }
  611. },
  612. #endif
  613. #if CLOCK_DIVIDERS_NO > 13U
  614. {
  615. BUS_HSRUN_CLK, /* name */
  616. 1U, /* value */
  617. {
  618. 0U,
  619. }
  620. },
  621. #endif
  622. #if CLOCK_DIVIDERS_NO > 14U
  623. {
  624. SLOW_RUN_CLK, /* name */
  625. 4U, /* value */
  626. {
  627. 0U,
  628. }
  629. },
  630. #endif
  631. #if CLOCK_DIVIDERS_NO > 15U
  632. {
  633. SLOW_VLPR_CLK, /* name */
  634. 4U, /* value */
  635. {
  636. 0U,
  637. }
  638. },
  639. #endif
  640. #if CLOCK_DIVIDERS_NO > 16U
  641. {
  642. SLOW_HSRUN_CLK, /* name */
  643. 4U, /* value */
  644. {
  645. 0U,
  646. }
  647. },
  648. #endif
  649. #if CLOCK_DIVIDERS_NO > 17U
  650. {
  651. CLKOUT0_CLK, /* name */
  652. 1U, /* value */
  653. {
  654. 0U,
  655. }
  656. },
  657. #endif
  658. #if CLOCK_DIVIDERS_NO > 18U
  659. {
  660. LPTMR0_CLK, /* name */
  661. 1U, /* value */
  662. {
  663. 1U,
  664. }
  665. },
  666. #endif
  667. #if CLOCK_DIVIDERS_NO > 19U
  668. {
  669. TRACE_CLK, /* name */
  670. 1U, /* value */
  671. {
  672. 1U,
  673. }
  674. },
  675. #endif
  676. },
  677. /* DIVIDER TRIGGER Initialization. */
  678. {
  679. #if CLOCK_DIVIDER_TRIGGERS_NO > 0U
  680. {
  681. RESERVED_CLK, /* divider name */
  682. IMMEDIATE_DIVIDER_UPDATE, /* trigger value */
  683. RESERVED_CLK, /* input source name */
  684. },
  685. #endif
  686. },
  687. /* FRACTIONAL DIVIDER initialization. */
  688. {
  689. {
  690. RESERVED_CLK,
  691. 0U,
  692. {
  693. 0U,
  694. 0U,
  695. },
  696. },
  697. },
  698. /* EXTERNAL CLOCKS initialization. */
  699. {
  700. #if CLOCK_EXT_CLKS_NO > 0U
  701. {
  702. TCLK0_REF_CLK, /* name */
  703. 0U, /* value */
  704. },
  705. #endif
  706. #if CLOCK_EXT_CLKS_NO > 1U
  707. {
  708. TCLK1_REF_CLK, /* name */
  709. 0U, /* value */
  710. },
  711. #endif
  712. #if CLOCK_EXT_CLKS_NO > 2U
  713. {
  714. TCLK2_REF_CLK, /* name */
  715. 0U, /* value */
  716. },
  717. #endif
  718. #if CLOCK_EXT_CLKS_NO > 3U
  719. {
  720. RTC_CLKIN, /* name */
  721. 32768U, /* value */
  722. },
  723. #endif
  724. },
  725. /* CLOCK GATES initialization. */
  726. {
  727. #if CLOCK_GATES_NO > 0U
  728. {
  729. LPO_32K_CLK, /* name */
  730. 1U, /* enable */
  731. },
  732. #endif
  733. #if CLOCK_GATES_NO > 1U
  734. {
  735. LPO_1K_CLK, /* name */
  736. 1U, /* enable */
  737. },
  738. #endif
  739. #if CLOCK_GATES_NO > 2U
  740. {
  741. ADC0_CLK, /* name */
  742. 1U, /* enable */
  743. },
  744. #endif
  745. #if CLOCK_GATES_NO > 3U
  746. {
  747. ADC1_CLK, /* name */
  748. 1U, /* enable */
  749. },
  750. #endif
  751. #if CLOCK_GATES_NO > 4U
  752. {
  753. CLKOUT0_CLK, /* name */
  754. 1U, /* enable */
  755. },
  756. #endif
  757. #if CLOCK_GATES_NO > 5U
  758. {
  759. CMP0_CLK, /* name */
  760. 1U, /* enable */
  761. },
  762. #endif
  763. #if CLOCK_GATES_NO > 6U
  764. {
  765. CRC0_CLK, /* name */
  766. 1U, /* enable */
  767. },
  768. #endif
  769. #if CLOCK_GATES_NO > 7U
  770. {
  771. DMA0_CLK, /* name */
  772. 1U, /* enable */
  773. },
  774. #endif
  775. #if CLOCK_GATES_NO > 8U
  776. {
  777. DMAMUX0_CLK, /* name */
  778. 1U, /* enable */
  779. },
  780. #endif
  781. #if CLOCK_GATES_NO > 9U
  782. {
  783. EIM0_CLK, /* name */
  784. 1U, /* enable */
  785. },
  786. #endif
  787. #if CLOCK_GATES_NO > 10U
  788. {
  789. ERM0_CLK, /* name */
  790. 1U, /* enable */
  791. },
  792. #endif
  793. #if CLOCK_GATES_NO > 11U
  794. {
  795. EWM0_CLK, /* name */
  796. 1U, /* enable */
  797. },
  798. #endif
  799. #if CLOCK_GATES_NO > 12U
  800. {
  801. FLEXCAN0_CLK, /* name */
  802. 1U, /* enable */
  803. },
  804. #endif
  805. #if CLOCK_GATES_NO > 13U
  806. {
  807. FLEXCAN1_CLK, /* name */
  808. 1U, /* enable */
  809. },
  810. #endif
  811. #if CLOCK_GATES_NO > 14U
  812. {
  813. FLEXCAN2_CLK, /* name */
  814. 1U, /* enable */
  815. },
  816. #endif
  817. #if CLOCK_GATES_NO > 15U
  818. {
  819. FlexIO_CLK, /* name */
  820. 1U, /* enable */
  821. },
  822. #endif
  823. #if CLOCK_GATES_NO > 16U
  824. {
  825. FTFC_CLK, /* name */
  826. 1U, /* enable */
  827. },
  828. #endif
  829. #if CLOCK_GATES_NO > 17U
  830. {
  831. FTM0_CLK, /* name */
  832. 1U, /* enable */
  833. },
  834. #endif
  835. #if CLOCK_GATES_NO > 18U
  836. {
  837. FTM1_CLK, /* name */
  838. 1U, /* enable */
  839. },
  840. #endif
  841. #if CLOCK_GATES_NO > 19U
  842. {
  843. FTM2_CLK, /* name */
  844. 1U, /* enable */
  845. },
  846. #endif
  847. #if CLOCK_GATES_NO > 20U
  848. {
  849. FTM3_CLK, /* name */
  850. 1U, /* enable */
  851. },
  852. #endif
  853. #if CLOCK_GATES_NO > 21U
  854. {
  855. LPI2C0_CLK, /* name */
  856. 1U, /* enable */
  857. },
  858. #endif
  859. #if CLOCK_GATES_NO > 22U
  860. {
  861. LPIT0_CLK, /* name */
  862. 1U, /* enable */
  863. },
  864. #endif
  865. #if CLOCK_GATES_NO > 23U
  866. {
  867. LPSPI0_CLK, /* name */
  868. 1U, /* enable */
  869. },
  870. #endif
  871. #if CLOCK_GATES_NO > 24U
  872. {
  873. LPSPI1_CLK, /* name */
  874. 1U, /* enable */
  875. },
  876. #endif
  877. #if CLOCK_GATES_NO > 25U
  878. {
  879. LPSPI2_CLK, /* name */
  880. 1U, /* enable */
  881. },
  882. #endif
  883. #if CLOCK_GATES_NO > 26U
  884. {
  885. LPTMR0_CLK, /* name */
  886. 1U, /* enable */
  887. },
  888. #endif
  889. #if CLOCK_GATES_NO > 27U
  890. {
  891. LPUART0_CLK, /* name */
  892. 1U, /* enable */
  893. },
  894. #endif
  895. #if CLOCK_GATES_NO > 28U
  896. {
  897. LPUART1_CLK, /* name */
  898. 1U, /* enable */
  899. },
  900. #endif
  901. #if CLOCK_GATES_NO > 29U
  902. {
  903. LPUART2_CLK, /* name */
  904. 1U, /* enable */
  905. },
  906. #endif
  907. #if CLOCK_GATES_NO > 30U
  908. {
  909. MPU0_CLK, /* name */
  910. 1U, /* enable */
  911. },
  912. #endif
  913. #if CLOCK_GATES_NO > 31U
  914. {
  915. MSCM0_CLK, /* name */
  916. 1U, /* enable */
  917. },
  918. #endif
  919. #if CLOCK_GATES_NO > 32U
  920. {
  921. PDB0_CLK, /* name */
  922. 1U, /* enable */
  923. },
  924. #endif
  925. #if CLOCK_GATES_NO > 33U
  926. {
  927. PDB1_CLK, /* name */
  928. 1U, /* enable */
  929. },
  930. #endif
  931. #if CLOCK_GATES_NO > 34U
  932. {
  933. PORTA_CLK, /* name */
  934. 1U, /* enable */
  935. },
  936. #endif
  937. #if CLOCK_GATES_NO > 35U
  938. {
  939. PORTB_CLK, /* name */
  940. 1U, /* enable */
  941. },
  942. #endif
  943. #if CLOCK_GATES_NO > 36U
  944. {
  945. PORTC_CLK, /* name */
  946. 1U, /* enable */
  947. },
  948. #endif
  949. #if CLOCK_GATES_NO > 37U
  950. {
  951. PORTD_CLK, /* name */
  952. 1U, /* enable */
  953. },
  954. #endif
  955. #if CLOCK_GATES_NO > 38U
  956. {
  957. PORTE_CLK, /* name */
  958. 1U, /* enable */
  959. },
  960. #endif
  961. #if CLOCK_GATES_NO > 39U
  962. {
  963. RTC0_CLK, /* name */
  964. 1U, /* enable */
  965. },
  966. #endif
  967. },
  968. /* Progressive clock switching */
  969. {
  970. {
  971. RESERVED_CLK,
  972. 0,
  973. 0,
  974. RESERVED_CLK,
  975. 0,
  976. },
  977. },
  978. /* Clock monitor */
  979. {
  980. {
  981. RESERVED_CLK,
  982. 0U,
  983. 0U,
  984. 0U,
  985. },
  986. },
  987. /* Specific peripheral initialization. */
  988. {
  989. 0U,
  990. {
  991. {
  992. RESERVED_VALUE,
  993. 0U,
  994. },
  995. },
  996. },
  997. /* Configured frequency values. */
  998. {
  999. {
  1000. RESERVED_CLK,
  1001. 0U,
  1002. },
  1003. },
  1004. },
  1005. };
  1006. #define MCU_STOP_SEC_CONFIG_DATA_UNSPECIFIED
  1007. #include "Mcu_MemMap.h"
  1008. /*==================================================================================================
  1009. LOCAL FUNCTION PROTOTYPES
  1010. ==================================================================================================*/
  1011. /*==================================================================================================
  1012. LOCAL FUNCTIONS
  1013. ==================================================================================================*/
  1014. /*==================================================================================================
  1015. GLOBAL FUNCTIONS
  1016. ==================================================================================================*/
  1017. #ifdef __cplusplus
  1018. }
  1019. #endif
  1020. /** @} */