1 /**************************************************************************//** 2 * @file timer_reg.h 3 * @version V1.00 4 * @brief TIMER register definition header file 5 * 6 * @copyright SPDX-License-Identifier: Apache-2.0 7 * @copyright Copyright (C) 2020 Nuvoton Technology Corp. All rights reserved. 8 *****************************************************************************/ 9 #ifndef __TIMER_REG_H__ 10 #define __TIMER_REG_H__ 11 12 /** @addtogroup REGISTER Control Register 13 14 @{ 15 16 */ 17 18 /*---------------------- Timer Controller -------------------------*/ 19 /** 20 @addtogroup TIMER Timer Controller(TIMER) 21 Memory Mapped Structure for TIMER Controller 22 @{ 23 */ 24 25 typedef struct 26 { 27 28 29 /** 30 * @var TIMER_T::CTL 31 * Offset: 0x00 Timer Control Register 32 * --------------------------------------------------------------------------------------------------- 33 * |Bits |Field |Descriptions 34 * | :----: | :----: | :---- | 35 * |[7:0] |PSC |Prescale Counter 36 * | | |Timer input clock or event source is divided by (PSC+1) before it is fed to the timer up counter 37 * | | |If this field is 0 (PSC = 0), then there is no scaling. 38 * | | |Note: Update prescale counter value will reset internal 8-bit prescale counter and 24-bit up counter value. 39 * |[15] |FUNCSEL |Function Selection 40 * | | |This bit sets the operation mode of Timer4 and Timer5 to PWM function. 41 * | | |0 = Timer controller is used as timer function. 42 * | | |1 = Timer controller is used as PWM function. 43 * | | |Note: The Timer0 ~ Timer3 function selection is controlled in TIMERx_ALTCTL[0], x= 0~3. 44 * |[19] |INTRGEN |Inter-timer Trigger Mode Enable Control 45 * | | |Setting this bit will enable the inter-timer trigger capture function. 46 * | | |The Timer0/2/4 will be in event counter mode and counting with external clock source or event 47 * | | |Also, Timer1/3/5 will be in trigger-counting mode of capture function. 48 * | | |0 = Inter-Timer Trigger Capture mode Disabled. 49 * | | |1 = Inter-Timer Trigger Capture mode Enabled. 50 * | | |Note: For Timer1/3/5, this bit is ignored and the read back value is always 0. 51 * |[20] |PERIOSEL |Periodic Mode Behavior Selection Enable Bit 52 * | | |0 = The behavior selection in periodic mode is Disabled. 53 * | | |When user updates CMPDAT while timer is running in periodic mode, CNT will be reset to default value. 54 * | | |1 = The behavior selection in periodic mode is Enabled. 55 * | | |When user update CMPDAT while timer is running in periodic mode, the limitations as bellows list, 56 * | | |If updated CMPDAT value > CNT, CMPDAT will be updated and CNT keep running continually. 57 * | | |If updated CMPDAT value = CNT, timer time-out interrupt will be asserted immediately. 58 * | | |If updated CMPDAT value < CNT, CNT will be reset to default value. 59 * |[21] |TGLPINSEL |Toggle-output Pin Select 60 * | | |0 = Toggle mode output to TMx (Timer Event Counter Pin). 61 * | | |1 = Toggle mode output to TMx_EXT (Timer External Capture Pin). 62 * |[22] |CAPSRC |Capture Pin Source Selection 63 * | | |0 = Capture Function source is from TMx_EXT (x= 0~5) pin. 64 * | | |1 = Capture Function source is from internal ACMP output signal, internal clock source (HIRC, LIRC, MIRC) or external clock (HXT, LXT). 65 * | | |Note1: When CAPSRC = 1, user can set INTERCAPSEL (TIMERx_EXTCTL[10:8]) to decide which internal ACMP output signal or which clock is as timer capture source. 66 * | | |Note2: MIRC clock source is only available in Timer4 ~ Timer5. 67 * |[23] |WKEN |Wake-up Function Enable Bit 68 * | | |If this bit is set to 1, while timer interrupt flag TIF (TIMERx_INTSTS[0]) is 1 and INTEN (TIMERx_CTL[29]) is enabled, the timer interrupt signal will generate a wake-up trigger event to CPU. 69 * | | |0 = Wake-up function Disabled if timer interrupt signal generated. 70 * | | |1 = Wake-up function Enabled if timer interrupt signal generated. 71 * |[24] |EXTCNTEN |Event Counter Mode Enable Bit 72 * | | |This bit is for external counting pin function enabled. 73 * | | |0 = Event counter mode Disabled. 74 * | | |1 = Event counter mode Enabled. 75 * | | |Note: When timer is used as an event counter, this bit should be set to 1 and select PCLK as timer clock source. 76 * |[25] |ACTSTS |Timer Active Status Bit (Read Only) 77 * | | |This bit indicates the 24-bit up counter status. 78 * | | |0 = 24-bit up counter is not active. 79 * | | |1 = 24-bit up counter is active. 80 * | | |Note: This bit may active when CNT 0 transition to CNT 1. 81 * |[28:27] |OPMODE |Timer Counting Mode Select 82 * | | |00 = The Timer controller is operated in One-shot mode. 83 * | | |01 = The Timer controller is operated in Periodic mode. 84 * | | |10 = The Timer controller is operated in Toggle-output mode. 85 * | | |11 = The Timer controller is operated in Continuous Counting mode. 86 * |[29] |INTEN |Timer Interrupt Enable Bit 87 * | | |0 = Timer time-out interrupt Disabled. 88 * | | |1 = Timer time-out interrupt Enabled. 89 * | | |Note: If this bit is enabled, when the timer time-out interrupt flag TIF is set to 1, the timer interrupt signal is generated and inform to CPU. 90 * |[30] |CNTEN |Timer Counting Enable Bit 91 * | | |0 = Stops/Suspends counting. 92 * | | |1 = Starts counting. 93 * | | |Note1: In stop status, and then set CNTEN to 1 will enable the 24-bit up counter to keep counting from the last stop counting value. 94 * | | |Note2: This bit is auto-cleared by hardware in one-shot mode (TIMER_CTL[28:27] = 00) when the timer time-out interrupt flag TIF (TIMERx_INTSTS[0]) is generated. 95 * | | |Note3: Set enable/disable this bit needs 2 * TMR_CLK period to become active, user can read ACTSTS (TIMERx_CTL[25]) to check enable/disable command is completed or not. 96 * |[31] |ICEDEBUG |ICE Debug Mode Acknowledge Disable Control (Write Protect) 97 * | | |0 = ICE debug mode acknowledgment effects TIMER counting. 98 * | | |TIMER counter will be held while CPU is held by ICE. 99 * | | |1 = ICE debug mode acknowledgment Disabled. 100 * | | |TIMER counter will keep going no matter CPU is held by ICE or not. 101 * | | |Note: This bit is write protected. Refer to the SYS_REGLCTL register. 102 * @var TIMER_T::CMP 103 * Offset: 0x04 Timer Comparator Register 104 * --------------------------------------------------------------------------------------------------- 105 * |Bits |Field |Descriptions 106 * | :----: | :----: | :---- | 107 * |[23:0] |CMPDAT |Timer Comparator Value 108 * | | |CMPDAT is a 24-bit compared value register. 109 * | | |When the internal 24-bit up counter value is equal to CMPDAT value, the TIF (TIMERx_INTSTS[0] Timer Interrupt Flag) will set to 1. 110 * | | |Time-out period = (Period of timer clock input) * (8-bit PSC + 1) * (24-bit CMPDAT). 111 * | | |Note1: Never write 0x0 or 0x1 in CMPDAT field, or the core will run into unknown state. 112 * | | |Note2: When timer is operating at continuous counting mode, the 24-bit up counter will keep counting continuously even if user writes a new value into CMPDAT field. 113 * | | |But if timer is operating at other modes, the 24-bit up counter will restart counting from 0 and using newest CMPDAT value to be the timer compared value while user writes a new value into CMPDAT field. 114 * @var TIMER_T::INTSTS 115 * Offset: 0x08 Timer Interrupt Status Register 116 * --------------------------------------------------------------------------------------------------- 117 * |Bits |Field |Descriptions 118 * | :----: | :----: | :---- | 119 * |[0] |TIF |Timer Interrupt Flag 120 * | | |This bit indicates the interrupt flag status of Timer while 24-bit timer up counter CNT (TIMERx_CNT[23:0]) value reaches to CMPDAT (TIMERx_CMP[23:0]) value. 121 * | | |0 = No effect. 122 * | | |1 = CNT value matches the CMPDAT value. 123 * | | |Note: This bit is cleared by writing 1 to it. 124 * |[1] |TWKF |Timer Wake-up Flag 125 * | | |This bit indicates the interrupt wake-up flag status of timer. 126 * | | |0 = Timer does not cause CPU wake-up. 127 * | | |1 = CPU wake-up from Idle or Power-down mode if timer time-out interrupt signal generated. 128 * | | |Note: This bit is cleared by writing 1 to it. 129 * @var TIMER_T::CNT 130 * Offset: 0x0C Timer Data Register 131 * --------------------------------------------------------------------------------------------------- 132 * |Bits |Field |Descriptions 133 * | :----: | :----: | :---- | 134 * |[23:0] |CNT |Timer Data Register 135 * | | |Read operation. 136 * | | |Read this register to get CNT value. For example: 137 * | | |If EXTCNTEN (TIMERx_CTL[24]) is 0, user can read CNT value for getting current 24-bit counter value. 138 * | | |If EXTCNTEN (TIMERx_CTL[24]) is 1, user can read CNT value for getting current 24-bit event input counter value. 139 * | | |Write operation. 140 * | | |Writing any value to this register will reset current CNT value to 0 and reload internal 8-bit prescale counter. 141 * |[31] |RSTACT |Timer Data Register Reset Active (Read Only) 142 * | | |This bit indicates if the counter reset operation active. 143 * | | |When user writes this CNT register, timer starts to reset its internal 24-bit timer up-counter to 0 and reload 8-bit pre-scale counter. 144 * | | |At the same time, timer set this flag to 1 to indicate the counter reset operation is in progress. 145 * | | |Once the counter reset operation done, timer clear this bit to 0 automatically. 146 * | | |0 = Reset operation is done. 147 * | | |1 = Reset operation triggered by writing TIMERx_CNT is in progress. 148 * | | |Note: This bit is read only. 149 * @var TIMER_T::CAP 150 * Offset: 0x10 Timer Capture Data Register 151 * --------------------------------------------------------------------------------------------------- 152 * |Bits |Field |Descriptions 153 * | :----: | :----: | :---- | 154 * |[23:0] |CAPDAT |Timer Capture Data Register 155 * | | |When CAPEN (TIMERx_EXTCTL[3]) bit is set, the transition on the capture source matches the CAPEDGE (TIMERx_EXTCTL[14:12]) setting, 156 * | | |CAPIF (TIMERx_EINTSTS[0]) will set to 1 and the current timer counter value CNT (TIMERx_CNT[23:0]) will be auto-loaded into this CAPDAT field. 157 * @var TIMER_T::EXTCTL 158 * Offset: 0x14 Timer External Control Register 159 * --------------------------------------------------------------------------------------------------- 160 * |Bits |Field |Descriptions 161 * | :----: | :----: | :---- | 162 * |[0] |CNTPHASE |Timer External Count Phase 163 * | | |This bit indicates the detection phase of external counting pin TMx (x= 0~5). 164 * | | |0 = A falling edge of external counting pin will be counted. 165 * | | |1 = A rising edge of external counting pin will be counted. 166 * |[3] |CAPEN |Timer Capture Function Enable Bit 167 * | | |This bit enables the capture input function. 168 * | | |0 = Timer capture function Disabled. 169 * | | |1 = Timer capture function Enabled. 170 * |[4] |CAPFUNCS |Capture Function Selection 171 * | | |0 = Capture Mode Enabled. 172 * | | |1 = Reset Mode Enabled. 173 * | | |Note1: When CAPFUNCS is 0 and CAPIF becomes 1, the current 24-bit timer counter value (CNT value) will be saved to CAPDAT field. 174 * | | |Note2: When CAPFUNCS is 1 and CAPIF becomes 1, the current 24-bit timer counter value (CNT value) will be saved to CAPDAT field then CNT value will be reset immediately. 175 * |[5] |CAPIEN |Timer Capture Interrupt Enable Bit 176 * | | |0 = TMx_EXT (x= 0~5), ACMP, internal clock, or external clock detection Interrupt Disabled. 177 * | | |1 = TMx_EXT (x= 0~5), ACMP, internal clock, or external clock detection Interrupt Enabled. 178 * | | |Note: CAPIEN is used to enable timer capture interrupt. 179 * | | |If CAPIEN enabled, timer will rise an interrupt when CAPIF (TIMERx_EINTSTS[0]) is 1. 180 * | | |For example, while CAPIEN = 1, CAPEN = 1, and CAPEDGE = 00, a 1 to 0 transition on the TMx_EXT pin, ACMP, internal clock, or external clock 181 * | | |will cause the CAPIF to be set then the interrupt signal is generated and sent to NVIC to inform CPU. 182 * |[6] |CAPDBEN |Timer Capture De-bounce Enable Bit 183 * | | |0 = TMx_EXT (x= 0~5) pin de-bounce or ACMP output de-bounce Disabled. 184 * | | |1 = TMx_EXT (x= 0~5) pin de-bounce or ACMP output de-bounce Enabled. 185 * | | |Note: If this bit is enabled, the edge detection of TMx_EXT pin or ACMP output is detected with de-bounce circuit. 186 * |[7] |CNTDBEN |Timer External Counter Pin De-bounce Enable Bit 187 * | | |0 = TMx (x= 0~5) pin de-bounce Disabled. 188 * | | |1 = TMx (x= 0~5) pin de-bounce Enabled. 189 * | | |Note: If this bit is enabled, the edge detection of TMx pin is detected with de-bounce circuit. 190 * |[10:8] |INTERCAPSEL|Internal Capture Source Select 191 * | | |000 = Capture Function source is from internal ACMP0 output signal. 192 * | | |001 = Capture Function source is from internal ACMP1 output signal. 193 * | | |010 = Capture Function source is from HXT. 194 * | | |011 = Capture Function source is from LXT. 195 * | | |100 = Capture Function source is from HIRC. 196 * | | |101 = Capture Function source is from LIRC. 197 * | | |101 = Capture Function source is from LIRC. 198 * | | |110 = Capture Function source is from MIRC, only available in Timer4 and Timer5. 199 * | | |111 = Reserved. 200 * | | |Note: These bits only available when CAPSRC (TIMERx_CTL[22]) is 1. 201 * |[14:12] |CAPEDGE |Timer Capture Edge Detect 202 * | | |When first capture event is generated, the CNT (TIMERx_CNT[23:0]) will be reset to 0 and first CAPDAT (TIMERx_CAP[23:0]) should be to 0. 203 * | | |000 = Capture event occurred when detect falling edge transfer on capture source. 204 * | | |001 = Capture event occurred when detect rising edge transfer on capture source. 205 * | | |010 = Capture event occurred when detect both falling and rising edge transfer on capture source, and the first capture event occurred at falling edge transfer. 206 * | | |011 = Capture event occurred when detect both rising and falling edge transfer on capture source, and the first capture event occurred at rising edge transfer. 207 * | | |110 = First capture event occurred at falling edge, follows capture events are at rising edge transfer on capture source. 208 * | | |111 = First capture event occurred at rising edge, follows capture events are at falling edge transfer on capture source. 209 * | | |100, 101 = Reserved. 210 * | | |Note: Set CAPSRC (TIMERx_CTL[22]) and INTERCAPSEL (TIMERx_EXTCTL[10:8]) to select capture source. 211 * |[16] |ECNTSSEL |Event Counter Source Selection to Trigger Event Counter Function 212 * | | |0 = Event Counter input source is from TMx (x= 0~5) pin. 213 * | | |1 = Event Counter input source is from USB internal SOF output signal. 214 * |[31:28] |CAPDIVSCL |Timer Capture Source Divider Scale 215 * | | |This bits indicate the divide scale for capture source divider. 216 * | | |0000 = Capture source/1. 217 * | | |0001 = Capture source/2. 218 * | | |0010 = Capture source/4. 219 * | | |0011 = Capture source/8. 220 * | | |0100 = Capture source/16. 221 * | | |0101 = Capture source/32. 222 * | | |0110 = Capture source/64. 223 * | | |0111 = Capture source/128. 224 * | | |1000 = Capture source/256. 225 * | | |1001~1111 = Reserved. 226 * | | |Note: Sets INTERCAPSEL (TIMERx_EXTCTL[10:8]) and CAPSRC (TIMERx_CTL[22]) to select capture source. 227 * @var TIMER_T::EINTSTS 228 * Offset: 0x18 Timer External Interrupt Status Register 229 * --------------------------------------------------------------------------------------------------- 230 * |Bits |Field |Descriptions 231 * | :----: | :----: | :---- | 232 * |[0] |CAPIF |Timer Capture Interrupt Flag 233 * | | |This bit indicates the timer capture interrupt flag status. 234 * | | |0 = TMx_EXT (x= 0~5) pin, ACMP, internal clock, or external clock capture interrupt did not occur. 235 * | | |1 = TMx_EXT (x= 0~5) pin, ACMP, internal clock, or external clock capture interrupt occurred. 236 * | | |Note1: This bit is cleared by writing 1 to it. 237 * | | |Note2: When CAPEN (TIMERx_EXTCTL[3]) bit is set, the transition on the capture source matches the CAPEDGE (TIMERx_EXTCTL[14:12]) setting, this bit will set to 1 by hardware. 238 * | | |Note3: There is a new incoming capture event detected before CPU clearing the CAPIF status. 239 * | | |If the above condition occurred, the timer will keep register TIMERx_CAP unchanged and drop the new capture value. 240 * @var TIMER_T::TRGCTL 241 * Offset: 0x1C Timer Trigger Control Register 242 * --------------------------------------------------------------------------------------------------- 243 * |Bits |Field |Descriptions 244 * | :----: | :----: | :---- | 245 * |[0] |TRGSSEL |Trigger Source Select Bit 246 * | | |This bit is used to select internal trigger source is form timer time-out interrupt signal or capture interrupt signal. 247 * | | |0 = Time-out interrupt signal is used to internal trigger EPWM/BPWM, PDMA, DAC, and EADC. 248 * | | |1 = Capture interrupt signal is used to internal trigger EPWM/BPWM, PDMA, DAC, and EADC. 249 * |[1] |TRGPWM |Trigger EPWM and BPWM Enable Bit 250 * | | |If this bit is set to 1, each timer time-out event or capture event can be as EPWM and BPWM counter clock source. 251 * | | |0 = Timer interrupt trigger EPWM and BPWM Disabled. 252 * | | |1 = Timer interrupt trigger EPWM and BPWM Enabled. 253 * | | |Note1: This bit is not available in Timer4 and Timer5. 254 * | | |Note2: If TRGSSEL (TIMERx_TRGCTL[0]) = 0, time-out interrupt signal as EPWM and BPWM counter clock source. 255 * | | |If TRGSSEL (TIMERx_TRGCTL[0]) = 1, capture interrupt signal as EPWM and BPWM counter clock source. 256 * |[2] |TRGEADC |Trigger EADC Enable Bit 257 * | | |If this bit is set to 1, each timer time-out event or capture event can be triggered EADC conversion. 258 * | | |0 = Timer interrupt trigger EADC Disabled. 259 * | | |1 = Timer interrupt trigger EADC Enabled. 260 * | | |Note: If TRGSSEL (TIMERx_TRGCTL[0]) = 0, time-out interrupt signal will trigger EADC conversion. 261 * | | |If TRGSSEL (TIMERx_TRGCTL[0]) = 1, capture interrupt signal will trigger EADC conversion. 262 * |[3] |TRGDAC |Trigger DAC Enable Bit 263 * | | |If this bit is set to 1, each timer time-out event or capture event can be triggered DAC. 264 * | | |0 = Timer interrupt trigger DAC Disabled. 265 * | | |1 = Timer interrupt trigger DAC Enabled. 266 * | | |Note1: This bit is not available in Timer4 and Timer5. 267 * | | |Note2: If TRGSSEL (TIMERx_TRGCTL[0]) = 0, time-out interrupt signal will trigger DAC. 268 * | | |If TRGSSEL (TIMERx_TRGCTL[0]) = 1, capture interrupt signal will trigger DAC. 269 * |[4] |TRGPDMA |Trigger PDMA Enable Bit 270 * | | |If this bit is set to 1, each timer time-out event or capture event can be triggered PDMA transfer. 271 * | | |0 = Timer interrupt trigger PDMA Disabled. 272 * | | |1 = Timer interrupt trigger PDMA Enabled. 273 * | | |Note: If TRGSSEL (TIMERx_TRGCTL[0]) = 0, time-out interrupt signal will trigger PDMA transfer. 274 * | | |If TRGSSEL (TIMERx_TRGCTL[0]) = 1, capture interrupt signal will trigger PDMA transfer. 275 * @var TIMER_T::ALTCTL 276 * Offset: 0x20 Timer Alternative Control Register 277 * --------------------------------------------------------------------------------------------------- 278 * |Bits |Field |Descriptions 279 * | :----: | :----: | :---- | 280 * |[0] |FUNCSEL |Function Selection 281 * | | |This bit sets the operation mode of Timer0 ~ Timer3 to PWM function. 282 * | | |0 = Timer controller is used as timer function. 283 * | | |1 = Timer controller is used as PWM function. 284 * | | |Note1: The Timer4 and Timer5 function selection is controlled in TIMERx_CTL[15], x= 4~5. 285 * | | |Note2: When timer is used as PWM, the clock source of time controller will be forced to PCLKx automatically. 286 * @var TIMER_T::PWMCTL 287 * Offset: 0x40 Timer PWM Control Register 288 * --------------------------------------------------------------------------------------------------- 289 * |Bits |Field |Descriptions 290 * | :----: | :----: | :---- | 291 * |[0] |CNTEN |PWM Counter Enable Bit 292 * | | |0 = PWM counter and clock prescale Stop Running. 293 * | | |1 = PWM counter and clock prescale Start Running. 294 * |[2:1] |CNTTYPE |PWM Counter Behavior Type 295 * | | |These bits are used to set the count type of Timer0 ~ Timer3. The count type of Timer4 and Timer5 is fixed as the up count type. 296 * | | |00 = Up count type. 297 * | | |01 = Down count type. 298 * | | |10 = Up-down count type. 299 * | | |11 = Reserved. 300 * | | |Note: These bits are not available in Timer4 and Timer5. 301 * |[3] |CNTMODE |PWM Counter Mode 302 * | | |0 = Auto-reload mode. 303 * | | |1 = One-shot mode. 304 * |[8] |CTRLD |Center Re-load 305 * | | |In up-down count type, PERIOD will load to PBUF when current PWM period is completed always and CMP will load to CMPBUF at the center point of current period. 306 * | | |Note: This bit is not available in Timer4 and Timer5. 307 * |[9] |IMMLDEN |Immediately Load Enable Bit 308 * | | |0 = PERIOD will load to PBUF when current PWM period is completed no matter CTRLD is enabled/disabled. 309 * | | |If CTRLD is disabled, CMP will load to CMPBUF when current PWM period is completed; if CTRLD is enabled in up-down count type, CMP will load to CMPBUF at the center point of current period. 310 * | | |1 = PERIOD/CMP will load to PBUF/CMPBUF immediately when user update PERIOD/CMP. 311 * | | |Note1: This bit is not available in Timer4 and Timer5. 312 * | | |Note2: If IMMLDEN is enabled, CTRLD will be invalid. 313 * |[12] |WKEN |PWM Wake-up Enable Bit 314 * | | |If this bit is set to 1, the Timer4 and Timer5 PWM interrupt eventl will generate a wake-up trigger event to CPU. 315 * | | |0 = PWM interrupt wake-up Disabled. 316 * | | |1 = PWM interrupt wake-up Enabled. 317 * | | |Note: This bit is only available in Timer4 and Timer5. 318 * |[16] |OUTMODE |PWM Output Mode 319 * | | |This bit controls the output mode of corresponding PWM channel. 320 * | | |0 = PWM independent mode. 321 * | | |1 = PWM complementary mode. 322 * | | |Note: This bit is not available in Timer4 and Timer5. 323 * |[30] |DBGHALT |ICE Debug Mode Counter Halt (Write Protect) 324 * | | |If debug mode counter halt is enabled, PWM counter will keep current value until exit ICE debug mode. 325 * | | |0 = ICE debug mode counter halt disable. 326 * | | |1 = ICE debug mode counter halt enable. 327 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 328 * |[31] |DBGTRIOFF |ICE Debug Mode Acknowledge Disable Bit (Write Protect) 329 * | | |0 = ICE debug mode acknowledgment effects PWM output. 330 * | | |PWM output pin will be forced as tri-state while ICE debug mode acknowledged. 331 * | | |1 = ICE debug mode acknowledgment disabled. 332 * | | |PWM output pin will keep output no matter ICE debug mode acknowledged or not. 333 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 334 * @var TIMER_T::PWMCLKSRC 335 * Offset: 0x44 Timer PWM Counter Clock Source Register 336 * --------------------------------------------------------------------------------------------------- 337 * |Bits |Field |Descriptions 338 * | :----: | :----: | :---- | 339 * |[2:0] |CLKSRC |PWM Counter Clock Source Select 340 * | | |The PWM counter clock source can be selected from TMRx_CLK or internal timer time-out or capture event in Timer0 ~ Timer3. 341 * | | |000 = TMRx_CLK. 342 * | | |001 = Internal TIMER0 time-out or capture event. 343 * | | |010 = Internal TIMER1 time-out or capture event. 344 * | | |011 = Internal TIMER2 time-out or capture event. 345 * | | |100 = Internal TIMER3 time-out or capture event. 346 * | | |Others = Reserved. 347 * | | |Note1: These bits are not available in Timer4 and Timer5. 348 * | | |Note2: If TIMER0 PWM function is enabled, the PWM counter clock source can be selected from TMR0_CLK, TIMER1 interrupt events, TIMER2 interrupt events, or TIMER3 interrupt events. 349 * @var TIMER_T::PWMCLKPSC 350 * Offset: 0x48 Timer PWM Counter Clock Pre-scale Register 351 * --------------------------------------------------------------------------------------------------- 352 * |Bits |Field |Descriptions 353 * | :----: | :----: | :---- | 354 * |[11:0] |CLKPSC |PWM Counter Clock Pre-scale 355 * | | |The active clock of PWM counter is decided by counter clock prescale and divided by (CLKPSC + 1). 356 * | | |If CLKPSC is 0, then there is no scaling in PWM counter clock source. 357 * | | |Note: The valid value is 12-bit TIMERx_PWMCLKPSC[11:0] in Timer0 ~ Timer3, and 8-bit TIMERx_PWMCLKPSC[7:0] in Timer4 and Timer5. 358 * @var TIMER_T::PWMCNTCLR 359 * Offset: 0x4C Timer PWM Clear Counter Register 360 * --------------------------------------------------------------------------------------------------- 361 * |Bits |Field |Descriptions 362 * | :----: | :----: | :---- | 363 * |[0] |CNTCLR |Clear PWM Counter Control Bit 364 * | | |It is automatically cleared by hardware. 365 * | | |0 = No effect. 366 * | | |1 = In Timer0 ~ Timer3, clears 16-bit PWM counter to 0x10000 in up and up-down count type and reset counter value to PERIOD in down count type. 367 * | | |In Timer4 and Timer5, clears 16-bit PWM counter to 0x0 in up count type. 368 * @var TIMER_T::PWMPERIOD 369 * Offset: 0x50 Timer PWM Period Register 370 * --------------------------------------------------------------------------------------------------- 371 * |Bits |Field |Descriptions 372 * | :----: | :----: | :---- | 373 * |[15:0] |PERIOD |PWM Period Register 374 * | | |In up count type: PWM counter counts from 0 to PERIOD, and restarts from 0. 375 * | | |In down count type: PWM counter counts from PERIOD to 0, and restarts from PERIOD. 376 * | | |In up-down count type: PWM counter counts from 0 to PERIOD, then decrements to 0 and repeats again. 377 * | | |In up and down count type: 378 * | | |PWM period time = (PERIOD + 1) * (CLKPSC + 1) * TMRx_PWMCLK. 379 * | | |In up-down count type: 380 * | | |PWM period time = 2 * PERIOD * (CLKPSC+ 1) * TMRx_PWMCLK. 381 * | | |Note1: The count type of Timer4 and Timer5 is fixed as up count type. 382 * | | |Note2: User should take care DIRF (TIMERx_PWMCNT[16]) bit in up/down/up-down count type to monitor current counter direction in each count type in Timer0 ~ Timer3. 383 * @var TIMER_T::PWMCMPDAT 384 * Offset: 0x54 Timer PWM Comparator Register 385 * --------------------------------------------------------------------------------------------------- 386 * |Bits |Field |Descriptions 387 * | :----: | :----: | :---- | 388 * |[15:0] |CMP |PWM Comparator Register 389 * | | |PWM CMP is used to compare with PWM CNT to generate PWM output waveform, interrupt events and trigger EADC and PDMA to start conversion. 390 * @var TIMER_T::PWMDTCTL 391 * Offset: 0x58 Timer PWM Dead-Time Control Register 392 * --------------------------------------------------------------------------------------------------- 393 * |Bits |Field |Descriptions 394 * | :----: | :----: | :---- | 395 * |[11:0] |DTCNT |Dead-time Counter (Write Protect) 396 * | | |The dead-time can be calculated from the following two formulas: 397 * | | |Dead-time = (DTCNT[11:0] + 1) * TMRx_PWMCLK, if DTCKSEL is 0. 398 * | | |Dead-time = (DTCNT[11:0] + 1) * TMRx_PWMCLK * (CLKPSC + 1), if DTCKSEL is 1. 399 * | | |Note: These bits are write protected. Refer to SYS_REGLCTL register. 400 * |[16] |DTEN |Enable Dead-time Insertion for PWMx_CH0 and PWMx_CH1 (Write Protect) 401 * | | |Dead-time insertion function is only active when PWM complementary mode is enabled. 402 * | | |If dead-time insertion is inactive, the outputs of PWMx_CH0 and PWMx_CH1 are complementary without any delay. 403 * | | |0 = Dead-time insertion Disabled on the pin pair. 404 * | | |1 = Dead-time insertion Enabled on the pin pair. 405 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 406 * |[24] |DTCKSEL |Dead-time Clock Select (Write Protect) 407 * | | |0 = Dead-time clock source from TMRx_PWMCLK without counter clock prescale. 408 * | | |1 = Dead-time clock source from TMRx_PWMCLK with counter clock prescale. 409 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 410 * @var TIMER_T::PWMCNT 411 * Offset: 0x5C Timer PWM Counter Register 412 * --------------------------------------------------------------------------------------------------- 413 * |Bits |Field |Descriptions 414 * | :----: | :----: | :---- | 415 * |[15:0] |CNT |PWM Counter Value Register (Read Only) 416 * | | |User can monitor CNT to know the current counter value in 16-bit period counter. 417 * |[16] |DIRF |PWM Counter Direction Indicator Flag (Read Only) 418 * | | |0 = Counter is active in down count. 419 * | | |1 = Counter is active up count. 420 * | | |Note1: This indicator flag is used for Timer0 ~ Timer3 only. 421 * | | |Note2: Since the count type of Timer4 ~ Timer5 is fixed as up count, this bit is fixed 0 in Timer4 and Timer5. 422 * @var TIMER_T::PWMMSKEN 423 * Offset: 0x60 Timer PWM Output Mask Enable Register 424 * --------------------------------------------------------------------------------------------------- 425 * |Bits |Field |Descriptions 426 * | :----: | :----: | :---- | 427 * |[0] |MSKEN0 |PWMx_CH0 Output Mask Enable Bit 428 * | | |The PWMx_CH0 output signal will be masked when this bit is enabled. 429 * | | |The PWMx_CH0 will output MSKDAT0 (TIMERx_PWMMSK[0]) data. 430 * | | |0 = PWMx_CH0 output signal is non-masked. 431 * | | |1 = PWMx_CH0 output signal is masked and output MSKDAT0 data. 432 * |[1] |MSKEN1 |PWMx_CH1 Output Mask Enable Bit 433 * | | |The PWMx_CH1 output signal will be masked when this bit is enabled. 434 * | | |The PWMx_CH1 will output MSKDAT1 (TIMERx_PWMMSK[1]) data. 435 * | | |0 = PWMx_CH1 output signal is non-masked. 436 * | | |1 = PWMx_CH1 output signal is masked and output MSKDAT1 data. 437 * @var TIMER_T::PWMMSK 438 * Offset: 0x64 Timer PWM Output Mask Data Control Register 439 * --------------------------------------------------------------------------------------------------- 440 * |Bits |Field |Descriptions 441 * | :----: | :----: | :---- | 442 * |[0] |MSKDAT0 |PWMx_CH0 Output Mask Data Control Bit 443 * | | |This bit is used to control the output state of PWMx_CH0 pin when PWMx_CH0 output mask function is enabled (MSKEN0 = 1). 444 * | | |0 = Output logic Low to PWMx_CH0. 445 * | | |1 = Output logic High to PWMx_CH0. 446 * |[1] |MSKDAT1 |PWMx_CH1 Output Mask Data Control Bit 447 * | | |This bit is used to control the output state of PWMx_CH1 pin when PWMx_CH1 output mask function is enabled (MSKEN1 = 1). 448 * | | |0 = Output logic Low to PWMx_CH1. 449 * | | |1 = Output logic High to PWMx_CH1. 450 * @var TIMER_T::PWMBNF 451 * Offset: 0x68 Timer PWM Brake Pin Noise Filter Register 452 * --------------------------------------------------------------------------------------------------- 453 * |Bits |Field |Descriptions 454 * | :----: | :----: | :---- | 455 * |[0] |BRKNFEN |Brake Pin Noise Filter Enable Bit 456 * | | |0 = Pin noise filter detect of PWMx_BRAKEy Disabled. 457 * | | |1 = Pin noise filter detect of PWMx_BRAKEy Enabled. 458 * |[3:1] |BRKNFSEL |Brake Pin Noise Filter Clock Selection 459 * | | |000 = Noise filter clock is PCLKx. 460 * | | |001 = Noise filter clock is PCLKx/2. 461 * | | |010 = Noise filter clock is PCLKx/4. 462 * | | |011 = Noise filter clock is PCLKx/8. 463 * | | |100 = Noise filter clock is PCLKx/16. 464 * | | |101 = Noise filter clock is PCLKx/32. 465 * | | |110 = Noise filter clock is PCLKx/64. 466 * | | |111 = Noise filter clock is PCLKx/128. 467 * |[6:4] |BRKFCNT |Brake Pin Noise Filter Count 468 * | | |The fields is used to control the active noise filter sample time. 469 * | | |Once noise filter sample time = (Period time of BRKNFSEL) * (BRKFCNT + 1). 470 * |[7] |BRKPINV |Brake Pin Detection Control Bit 471 * | | |0 = Brake pin event will be detected if PWMx_BRAKEy pin status transfer from low to high in edge-detect, or pin status is high in level-detect. 472 * | | |1 = Brake pin event will be detected if PWMx_BRAKEy pin status transfer from high to low in edge-detect, or pin status is low in level-detect . 473 * |[17:16] |BKPINSRC |Brake Pin Source Select 474 * | | |00 = Brake pin source comes from PWM0_BRAKE0 pin. 475 * | | |01 = Brake pin source comes from PWM0_BRAKE1 pin. 476 * | | |10 = Brake pin source comes from PWM1_BRAKE0 pin. 477 * | | |11 = Brake pin source comes from PWM1_BRAKE1 pin. 478 * @var TIMER_T::PWMFAILBRK 479 * Offset: 0x6C Timer PWM System Fail Brake Control Register 480 * --------------------------------------------------------------------------------------------------- 481 * |Bits |Field |Descriptions 482 * | :----: | :----: | :---- | 483 * |[0] |CSSBRKEN |Clock Security System Detection Trigger PWM Brake Function Enable Bit 484 * | | |0 = Brake Function triggered by clock fail detection Disabled. 485 * | | |1 = Brake Function triggered by clock fail detection Enabled. 486 * |[1] |BODBRKEN |Brown-out Detection Trigger PWM Brake Function Enable Bit 487 * | | |0 = Brake Function triggered by BOD event Disabled. 488 * | | |1 = Brake Function triggered by BOD event Enabled. 489 * |[2] |RAMBRKEN |SRAM Parity Error Detection Trigger PWM Brake Function Enable Bit 490 * | | |0 = Brake Function triggered by SRAM parity error detection Disabled. 491 * | | |1 = Brake Function triggered by SRAM parity error detection Enabled. 492 * |[3] |CORBRKEN |Core Lockup Detection Trigger PWM Brake Function Enable Bit 493 * | | |0 = Brake Function triggered by core lockup event Disabled. 494 * | | |1 = Brake Function triggered by core lockup event Enabled. 495 * @var TIMER_T::PWMBRKCTL 496 * Offset: 0x70 Timer PWM Brake Control Register 497 * --------------------------------------------------------------------------------------------------- 498 * |Bits |Field |Descriptions 499 * | :----: | :----: | :---- | 500 * |[0] |CPO0EBEN |Enable Internal ACMP0_O Digital Output As Edge-detect Brake Source (Write Protect) 501 * | | |0 = Internal ACMP0_O signal as edge-detect brake source Disabled. 502 * | | |1 = Internal ACMP0_O signal as edge-detect brake source Enabled. 503 * | | |Note1: Only internal ACMP0_O signal from low to high will be detected as brake event. 504 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 505 * |[1] |CPO1EBEN |Enable Internal ACMP1_O Digital Output As Edge-detect Brake Source (Write Protect) 506 * | | |0 = Internal ACMP1_O signal as edge-detect brake source Disabled. 507 * | | |1 = Internal ACMP1_O signal as edge-detect brake source Enabled. 508 * | | |Note1: Only internal ACMP1_O signal from low to high will be detected as brake event. 509 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 510 * |[4] |BRKPEEN |Enable TM_BRAKEx Pin As Edge-detect Brake Source (Write Protect) 511 * | | |0 = PWMx_BRAKEy pin event as edge-detect brake source Disabled. 512 * | | |1 = PWMx_BRAKEy pin event as edge-detect brake source Enabled. 513 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 514 * |[7] |SYSEBEN |Enable System Fail As Edge-detect Brake Source (Write Protect) 515 * | | |0 = System fail condition as edge-detect brake source Disabled. 516 * | | |1 = System fail condition as edge-detect brake source Enabled. 517 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 518 * |[8] |CPO0LBEN |Enable Internal ACMP0_O Digital Output As Level-detect Brake Source (Write Protect) 519 * | | |0 = Internal ACMP0_O signal as level-detect brake source Disabled. 520 * | | |1 = Internal ACMP0_O signal as level-detect brake source Enabled. 521 * | | |Note1: Only internal ACMP0_O signal from low to high will be detected as brake event. 522 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 523 * |[9] |CPO1LBEN |Enable Internal ACMP1_O Digital Output As Level-detect Brake Source (Write Protect) 524 * | | |0 = Internal ACMP1_O signal as level-detect brake source Disabled. 525 * | | |1 = Internal ACMP1_O signal as level-detect brake source Enabled. 526 * | | |Note1: Only internal ACMP1_O signal from low to high will be detected as brake event. 527 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 528 * |[12] |BRKPLEN |Enable TM_BRAKEx Pin As Level-detect Brake Source (Write Protect) 529 * | | |0 = PWMx_BRAKEy pin event as level-detect brake source Disabled. 530 * | | |1 = PWMx_BRAKEy pin event as level-detect brake source Enabled. 531 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 532 * |[15] |SYSLBEN |Enable System Fail As Level-detect Brake Source (Write Protect) 533 * | | |0 = System fail condition as level-detect brake source Disabled. 534 * | | |1 = System fail condition as level-detect brake source Enabled. 535 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 536 * |[17:16] |BRKAEVEN |PWM Brake Action Select for PWMx_CH0 (Write Protect) 537 * | | |00 = PWMx_BRAKEy brake event will not affect PWMx_CH0 output. 538 * | | |01 = PWMx_CH0 output tri-state when PWMx_BRAKEy brake event happened. 539 * | | |10 = PWMx_CH0 output low level when PWMx_BRAKEy brake event happened. 540 * | | |11 = PWMx_CH0 output high level when PWMx_BRAKEy brake event happened. 541 * | | |Note: These bits are write protected. Refer to SYS_REGLCTL register. 542 * |[19:18] |BRKAODD |PWM Brake Action Select for PWMx_CH1 (Write Protect) 543 * | | |00 = PWMx_BRAKEy brake event will not affect PWMx_CH1 output. 544 * | | |01 = PWMx_CH1 output tri-state when PWMx_BRAKEy brake event happened. 545 * | | |10 = PWMx_CH1 output low level when PWMx_BRAKEy brake event happened. 546 * | | |11 = PWMx_CH1 output high level when PWMx_BRAKEy brake event happened. 547 * | | |Note: These bits are write protected. Refer to SYS_REGLCTL register. 548 * @var TIMER_T::PWMPOLCTL 549 * Offset: 0x74 Timer PWM Pin Output Polar Control Register 550 * --------------------------------------------------------------------------------------------------- 551 * |Bits |Field |Descriptions 552 * | :----: | :----: | :---- | 553 * |[0] |PINV0 |PWMx_CH0 Output Pin Polar Control Bit 554 * | | |The bit is used to control polarity state of PWMx_CH0 output pin. 555 * | | |0 = PWMx_CH0 output pin polar inverse Disabled. 556 * | | |1 = PWMx_CH0 output pin polar inverse Enabled. 557 * | | |Note: In Timer4 and Timer5, the PWMx_CH0 output pin can be selected as TMx or TMx_EXT pin by POSEL (TIMERx_PWMPOEN[8]), x= 4~5. 558 * |[1] |PINV1 |PWMx_CH1 Output Pin Polar Control Bit 559 * | | |The bit is used to control polarity state of PWMx_CH1 output pin. 560 * | | |0 = PWMx_CH1 output pin polar inverse Disabled. 561 * | | |1 = PWMx_CH1 output pin polar inverse Enabled. 562 * | | |Note: This bit is not available in Timer4 and Timer5. 563 * @var TIMER_T::PWMPOEN 564 * Offset: 0x78 Timer PWM Pin Output Enable Register 565 * --------------------------------------------------------------------------------------------------- 566 * |Bits |Field |Descriptions 567 * | :----: | :----: | :---- | 568 * |[0] |POEN0 |PWMx_CH0 Output Pin Enable Bit 569 * | | |0 = PWMx_CH0 pin at tri-state mode. 570 * | | |1 = PWMx_CH0 pin in output mode. 571 * | | |Note: In Timer4 and Timer5, the PWMx_CH0 output pin can be selected as TMx or TMx_EXT pin by POSEL (TIMERx_PWMPOEN[8]), x= 4~5. 572 * |[1] |POEN1 |PWMx_CH1 Output Pin Enable Bit 573 * | | |0 = PWMx_CH1 pin at tri-state mode. 574 * | | |1 = PWMx_CH1 pin in output mode. 575 * | | |Note: This bit is not available in Timer4 and Timer5. 576 * |[8] |POSEL |PWMx_CH0 Output Pin Select 577 * | | |This bit is used to select the output channel of Timer4 and Timer5 PWM. 578 * | | |0 = PWMx_CH0 pin is TMx. 579 * | | |1 = PWMx_CH0 pin is TMx_EXT. 580 * | | |Note: This bit is only available in Timer4 and Timer5. 581 * @var TIMER_T::PWMSWBRK 582 * Offset: 0x7C Timer PWM Software Trigger Brake Control Register 583 * --------------------------------------------------------------------------------------------------- 584 * |Bits |Field |Descriptions 585 * | :----: | :----: | :---- | 586 * |[0] |BRKETRG |Software Trigger Edge-detect Brake Source (Write Only) (Write Protect) 587 * | | |Write 1 to this bit will trigger PWM edge-detect brake source, then BRKEIF0 and BRKEIF1 will set to 1 automatically in TIMERx_PWMINTSTS1 register. 588 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 589 * |[8] |BRKLTRG |Software Trigger Level-detect Brake Source (Write Only) (Write Protect) 590 * | | |Write 1 to this bit will trigger PWM level-detect brake source, then BRKLIF0 and BRKLIF1 will set to 1 automatically in TIMERx_PWMINTSTS1 register. 591 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 592 * @var TIMER_T::PWMINTEN0 593 * Offset: 0x80 Timer PWM Interrupt Enable Register 0 594 * --------------------------------------------------------------------------------------------------- 595 * |Bits |Field |Descriptions 596 * | :----: | :----: | :---- | 597 * |[0] |ZIEN |PWM Zero Point Interrupt Enable Bit 598 * | | |0 = Zero point interrupt Disabled. 599 * | | |1 = Zero point interrupt Enabled. 600 * | | |Note: This bit is not available in Timer4 and Timer5. 601 * |[1] |PIEN |PWM Period Point Interrupt Enable Bit 602 * | | |0 = Period point interrupt Disabled. 603 * | | |1 = Period point interrupt Enabled. 604 * | | |Note: In up-down count type, period point means the center point of current PWM period. 605 * |[2] |CMPUIEN |PWM Compare Up Count Interrupt Enable Bit 606 * | | |0 = Compare up count interrupt Disabled. 607 * | | |1 = Compare up count interrupt Enabled. 608 * |[3] |CMPDIEN |PWM Compare Down Count Interrupt Enable Bit 609 * | | |0 = Compare down count interrupt Disabled. 610 * | | |1 = Compare down count interrupt Enabled. 611 * | | |Note: This bit is not available in Timer4 and Timer5. 612 * @var TIMER_T::PWMINTEN1 613 * Offset: 0x84 Timer PWM Interrupt Enable Register 1 614 * --------------------------------------------------------------------------------------------------- 615 * |Bits |Field |Descriptions 616 * | :----: | :----: | :---- | 617 * |[0] |BRKEIEN |PWM Edge-detect Brake Interrupt Enable (Write Protect) 618 * | | |0 = PWM edge-detect brake interrupt Disabled. 619 * | | |1 = PWM edge-detect brake interrupt Enabled. 620 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 621 * |[8] |BRKLIEN |PWM Level-detect Brake Interrupt Enable (Write Protect) 622 * | | |0 = PWM level-detect brake interrupt Disabled. 623 * | | |1 = PWM level-detect brake interrupt Enabled. 624 * | | |Note: This bit is write protected. Refer to SYS_REGLCTL register. 625 * @var TIMER_T::PWMINTSTS0 626 * Offset: 0x88 Timer PWM Interrupt Status Register 0 627 * --------------------------------------------------------------------------------------------------- 628 * |Bits |Field |Descriptions 629 * | :----: | :----: | :---- | 630 * |[0] |ZIF |PWM Zero Point Interrupt Flag 631 * | | |This bit is set by hardware when TIMERx_PWM counter reaches zero. 632 * | | |Note1: This bit is not available in Timer4 and Timer5. 633 * | | |Note2: This bit is cleared by writing 1 to it. 634 * |[1] |PIF |PWM Period Point Interrupt Flag 635 * | | |This bit is set by hardware when TIMERx_PWM counter reaches PERIOD. 636 * | | |Note1: In up-down count type, PIF flag means the center point flag of current PWM period. 637 * | | |Note2: This bit is cleared by writing 1 to it. 638 * |[2] |CMPUIF |PWM Compare Up Count Interrupt Flag 639 * | | |This bit is set by hardware when TIMERx_PWM counter in up count direction and reaches CMP. 640 * | | |Note1: If CMP equal to PERIOD, there is no CMPUIF flag in up count type and up-down count type.. 641 * | | |Note2: This bit is cleared by writing 1 to it. 642 * |[3] |CMPDIF |PWM Compare Down Count Interrupt Flag 643 * | | |This bit is set by hardware when TIMERx_PWM counter in down count direction and reaches CMP. 644 * | | |Note1: This bit is not available in Timer4 and Timer5. 645 * | | |Note2: If CMP equal to PERIOD, there is no CMPDIF flag in down count type. 646 * | | |Note3: This bit is cleared by writing 1 to it. 647 * @var TIMER_T::PWMINTSTS1 648 * Offset: 0x8C Timer PWM Interrupt Status Register 1 649 * --------------------------------------------------------------------------------------------------- 650 * |Bits |Field |Descriptions 651 * | :----: | :----: | :---- | 652 * |[0] |BRKEIF0 |Edge-detect Brake Interrupt Flag on PWMx_CH0 (Write Protect) 653 * | | |0 = PWMx_CH0 edge-detect brake event do not happened. 654 * | | |1 = PWMx_CH0 edge-detect brake event happened. 655 * | | |Note1: This bit is cleared by writing 1 to it. 656 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 657 * |[1] |BRKEIF1 |Edge-detect Brake Interrupt Flag PWMx_CH1 (Write Protect) 658 * | | |0 = PWMx_CH1 edge-detect brake event do not happened. 659 * | | |1 = PWMx_CH1 edge-detect brake event happened. 660 * | | |Note1: This bit is cleared by writing 1 to it. 661 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 662 * |[8] |BRKLIF0 |Level-detect Brake Interrupt Flag on PWMx_CH0 (Write Protect) 663 * | | |0 = PWMx_CH0 level-detect brake event do not happened. 664 * | | |1 = PWMx_CH0 level-detect brake event happened. 665 * | | |Note1: This bit is cleared by writing 1 to it. 666 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 667 * |[9] |BRKLIF1 |Level-detect Brake Interrupt Flag on PWMx_CH1 (Write Protect) 668 * | | |0 = PWMx_CH1 level-detect brake event do not happened. 669 * | | |1 = PWMx_CH1 level-detect brake event happened. 670 * | | |Note1: This bit is cleared by writing 1 to it. 671 * | | |Note2: This bit is write protected. Refer to SYS_REGLCTL register. 672 * |[16] |BRKESTS0 |Edge -detect Brake Status of PWMx_CH0 (Read Only) 673 * | | |0 = PWMx_CH0 edge-detect brake state is released. 674 * | | |1 = PWMx_CH0 at edge-detect brake state. 675 * | | |Note: User can set BRKEIF0 1 to clear BRKEIF0 flag and PWMx_CH0 will release brake state when current PWM period finished and resume PWMx_CH0 output waveform start from next full PWM period. 676 * |[17] |BRKESTS1 |Edge-detect Brake Status of PWMx_CH1 (Read Only) 677 * | | |0 = PWMx_CH1 edge-detect brake state is released. 678 * | | |1 = PWMx_CH1 at edge-detect brake state. 679 * | | |Note: User can set BRKEIF1 1 to clear BRKEIF1 flag and PWMx_CH1 will release brake state when current PWM period finished and resume PWMx_CH1 output waveform start from next full PWM period. 680 * |[24] |BRKLSTS0 |Level-detect Brake Status of PWMx_CH0 (Read Only) 681 * | | |0 = PWMx_CH0 level-detect brake state is released. 682 * | | |1 = PWMx_CH0 at level-detect brake state. 683 * | | |Note: If TIMERx_PWM level-detect brake source has released, both PWMx_CH0 and PWMx_CH1 will release brake state when current PWM period finished and resume PWMx_CH0 and PWMx_CH1 output waveform start from next full PWM period. 684 * |[25] |BRKLSTS1 |Level-detect Brake Status of PWMx_CH1 (Read Only) 685 * | | |0 = PWMx_CH1 level-detect brake state is released. 686 * | | |1 = PWMx_CH1 at level-detect brake state. 687 * | | |Note: If TIMERx_PWM level-detect brake source has released, both PWMx_CH0 and PWMx_CH1 will release brake state when current PWM period finished and resume PWMx_CH0 and PWMx_CH1 output waveform start from next full PWM period. 688 * @var TIMER_T::PWMTRGCTL 689 * Offset: 0x90 Timer PWM Trigger Control Register 690 * --------------------------------------------------------------------------------------------------- 691 * |Bits |Field |Descriptions 692 * | :----: | :----: | :---- | 693 * |[2:0] |TRGSEL |PWM Counter Event Source Select to Trigger Conversion 694 * | | |In Timer0 ~ Timer3, 695 * | | |000 = Trigger conversion at zero point (ZIF). 696 * | | |001 = Trigger conversion at period point (PIF). 697 * | | |010 = Trigger conversion at zero or period point (ZIF or PIF). 698 * | | |011 = Trigger conversion at compare up count point (CMPUIF). 699 * | | |100 = Trigger conversion at compare down count point (CMPDIF). 700 * | | |In Timer4 and Timer5, 701 * | | |001 = Trigger conversion at period point (PIF). 702 * | | |011 = Trigger conversion at compare up count point (CMPUIF). 703 * | | |101 = Trigger conversion at period or compare up count point (PIF or CMPUIF). 704 * | | |Others = Reserved. 705 * |[7] |TRGEADC |PWM Counter Event Trigger EADC Conversion Enable Bit 706 * | | |0 = PWM counter event trigger EADC conversion Disabled. 707 * | | |1 = PWM counter event trigger EADC conversion Enabled. 708 * | | |Note: Set TRGSEL (TIMERx_PWMTRGCTL[2:0]) to select PWM trigger conversion source. 709 * |[9] |TRGPDMA |PWM Counter Event Trigger PDMA Conversion Enable Bit 710 * | | |0 = PWM counter event trigger PDMA conversion Disabled. 711 * | | |1 = PWM counter event trigger PDMA conversion Enabled. 712 * | | |Note: Set TRGSEL (TIMERx_PWMTRGCTL[2:0]) to select PWM trigger conversion source. 713 * @var TIMER_T::PWMSCTL 714 * Offset: 0x94 Timer PWM Synchronous Control Register 715 * --------------------------------------------------------------------------------------------------- 716 * |Bits |Field |Descriptions 717 * | :----: | :----: | :---- | 718 * |[1:0] |SYNCMODE |PWM Synchronous Mode Enable Select 719 * | | |00 = PWM synchronous function Disabled. 720 * | | |01 = PWM synchronous counter start function Enabled. 721 * | | |10 = Reserved. 722 * | | |11 = PWM synchronous counter clear function Enabled. 723 * |[8] |SYNCSRC |PWM Synchronous Counter Start/Clear Source Select 724 * | | |0 = Counter synchronous start/clear by trigger TIMER0_PWMSTRG STRGEN. 725 * | | |1 = Counter synchronous start/clear by trigger TIMER2_PWMSTRG STRGEN. 726 * | | |Note1: If TIMER0/1/2/3 PWM counter synchronous source are from TIMER0, TIMER0_PWMSCTL[8], TIMER1_PWMSCTL[8], TIMER2_PWMSCTL[8] and TIMER3_PWMSCTL[8] should be 0. 727 * | | |Note2: If TIMER0/1/ PWM counter synchronous source are from TIMER0, TIMER0_PWMSCTL[8] and TIMER1_PWMSCTL[8] should be set 0, and TIMER2/3/ PWM counter synchronous source are from TIMER2, TIME2_PWMSCTL[8] and TIMER3_PWMSCTL[8] should be set 1. 728 * @var TIMER_T::PWMSTRG 729 * Offset: 0x98 Timer PWM Synchronous Trigger Register 730 * --------------------------------------------------------------------------------------------------- 731 * |Bits |Field |Descriptions 732 * | :----: | :----: | :---- | 733 * |[0] |STRGEN |PWM Counter Synchronous Trigger Enable Bit (Write Only) 734 * | | |PMW counter synchronous function is used to make selected PWM channels (include TIMER0/1/2/3 PWM, TIMER0/1 PWM and TIMER2/3 PWM) start counting or clear counter at the same time according to TIMERx_PWMSCTL setting. 735 * | | |Note: This bit is only available in TIMER0 and TIMER2. 736 * @var TIMER_T::PWMSTATUS 737 * Offset: 0x9C Timer PWM Status Register 738 * --------------------------------------------------------------------------------------------------- 739 * |Bits |Field |Descriptions 740 * | :----: | :----: | :---- | 741 * |[0] |CNTMAXF |PWM Counter Equal to 0xFFFF Flag 742 * | | |0 = The PWM counter value never reached its maximum value 0xFFFF. 743 * | | |1 = The PWM counter value has reached its maximum value. 744 * | | |Note: This bit is cleared by writing 1 to it. 745 * |[8] |WKF |PWM Wake-up Flag 746 * | | |0 = PWM interrupt wake-up has not occurred. 747 * | | |1 = PWM interrupt wake-up has occurred. 748 * | | |Note1: This bit is only available in Timer4 and Timer5. 749 * | | |Note2: This bit is cleared by writing 1 to it. 750 * |[16] |EADCTRGF |Trigger EADC Start Conversion Flag 751 * | | |0 = PWM counter event trigger EADC start conversion is not occurred. 752 * | | |1 = PWM counter event trigger EADC start conversion has occurred. 753 * | | |Note: This bit is cleared by writing 1 to it. 754 * |[19] |PDMATRGF |Trigger PDMA Start Conversion Flag 755 * | | |0 = PWM counter event trigger PDMA start conversion is not occurred. 756 * | | |1 = PWM counter event trigger PDMA start conversion has occurred. 757 * | | |Note1: This bit is only available in Timer4 and Timer5. 758 * | | |Note2: This bit is cleared by writing 1 to it. 759 * @var TIMER_T::PWMPBUF 760 * Offset: 0xA0 Timer PWM Period Buffer Register 761 * --------------------------------------------------------------------------------------------------- 762 * |Bits |Field |Descriptions 763 * | :----: | :----: | :---- | 764 * |[15:0] |PBUF |PWM Period Buffer Register (Read Only) 765 * | | |Used as PERIOD active register. 766 * @var TIMER_T::PWMCMPBUF 767 * Offset: 0xA4 Timer PWM Comparator Buffer Register 768 * --------------------------------------------------------------------------------------------------- 769 * |Bits |Field |Descriptions 770 * | :----: | :----: | :---- | 771 * |[15:0] |CMPBUF |PWM Comparator Buffer Register (Read Only) 772 * | | |Used as CMP active register. 773 */ 774 __IO uint32_t CTL; /*!< [0x0000] Timer Control Register */ 775 __IO uint32_t CMP; /*!< [0x0004] Timer Comparator Register */ 776 __IO uint32_t INTSTS; /*!< [0x0008] Timer Interrupt Status Register */ 777 __IO uint32_t CNT; /*!< [0x000c] Timer Data Register */ 778 __I uint32_t CAP; /*!< [0x0010] Timer Capture Data Register */ 779 __IO uint32_t EXTCTL; /*!< [0x0014] Timer External Control Register */ 780 __IO uint32_t EINTSTS; /*!< [0x0018] Timer External Interrupt Status Register */ 781 __IO uint32_t TRGCTL; /*!< [0x001c] Timer Trigger Control Register */ 782 __IO uint32_t ALTCTL; /*!< [0x0020] Timer Alternative Control Register */ 783 __I uint32_t RESERVE0[7]; 784 __IO uint32_t PWMCTL; /*!< [0x0040] Timer PWM Control Register */ 785 __IO uint32_t PWMCLKSRC; /*!< [0x0044] Timer PWM Counter Clock Source Register */ 786 __IO uint32_t PWMCLKPSC; /*!< [0x0048] Timer PWM Counter Clock Pre-scale Register */ 787 __IO uint32_t PWMCNTCLR; /*!< [0x004c] Timer PWM Clear Counter Register */ 788 __IO uint32_t PWMPERIOD; /*!< [0x0050] Timer PWM Period Register */ 789 __IO uint32_t PWMCMPDAT; /*!< [0x0054] Timer PWM Comparator Register */ 790 __IO uint32_t PWMDTCTL; /*!< [0x0058] Timer PWM Dead-Time Control Register */ 791 __I uint32_t PWMCNT; /*!< [0x005c] Timer PWM Counter Register */ 792 __IO uint32_t PWMMSKEN; /*!< [0x0060] Timer PWM Output Mask Enable Register */ 793 __IO uint32_t PWMMSK; /*!< [0x0064] Timer PWM Output Mask Data Control Register */ 794 __IO uint32_t PWMBNF; /*!< [0x0068] Timer PWM Brake Pin Noise Filter Register */ 795 __IO uint32_t PWMFAILBRK; /*!< [0x006c] Timer PWM System Fail Brake Control Register */ 796 __IO uint32_t PWMBRKCTL; /*!< [0x0070] Timer PWM Brake Control Register */ 797 __IO uint32_t PWMPOLCTL; /*!< [0x0074] Timer PWM Pin Output Polar Control Register */ 798 __IO uint32_t PWMPOEN; /*!< [0x0078] Timer PWM Pin Output Enable Register */ 799 __O uint32_t PWMSWBRK; /*!< [0x007c] Timer PWM Software Trigger Brake Control Register */ 800 __IO uint32_t PWMINTEN0; /*!< [0x0080] Timer PWM Interrupt Enable Register 0 */ 801 __IO uint32_t PWMINTEN1; /*!< [0x0084] Timer PWM Interrupt Enable Register 1 */ 802 __IO uint32_t PWMINTSTS0; /*!< [0x0088] Timer PWM Interrupt Status Register 0 */ 803 __IO uint32_t PWMINTSTS1; /*!< [0x008c] Timer PWM Interrupt Status Register 1 */ 804 __IO uint32_t PWMTRGCTL; /*!< [0x0090] Timer PWM Trigger Control Register */ 805 __IO uint32_t PWMSCTL; /*!< [0x0094] Timer PWM Synchronous Control Register */ 806 __O uint32_t PWMSTRG; /*!< [0x0098] Timer PWM Synchronous Trigger Register */ 807 __IO uint32_t PWMSTATUS; /*!< [0x009c] Timer PWM Status Register */ 808 __I uint32_t PWMPBUF; /*!< [0x00a0] Timer PWM Period Buffer Register */ 809 __I uint32_t PWMCMPBUF; /*!< [0x00a4] Timer PWM Comparator Buffer Register */ 810 811 } TIMER_T; 812 813 /** 814 @addtogroup TIMER_CONST TIMER Bit Field Definition 815 Constant Definitions for TIMER Controller 816 @{ 817 */ 818 819 #define TIMER_CTL_PSC_Pos (0) /*!< TIMER_T::CTL: PSC Position */ 820 #define TIMER_CTL_PSC_Msk (0xfful << TIMER_CTL_PSC_Pos) /*!< TIMER_T::CTL: PSC Mask */ 821 822 #define TIMER_CTL_FUNCSEL_Pos (15) /*!< TIMER_T::CTL: FUNCSEL Position */ 823 #define TIMER_CTL_FUNCSEL_Msk (0x1ul << TIMER_CTL_FUNCSEL_Pos) /*!< TIMER_T::CTL: FUNCSEL Mask */ 824 825 #define TIMER_CTL_INTRGEN_Pos (19) /*!< TIMER_T::CTL: INTRGEN Position */ 826 #define TIMER_CTL_INTRGEN_Msk (0x1ul << TIMER_CTL_INTRGEN_Pos) /*!< TIMER_T::CTL: INTRGEN Mask */ 827 828 #define TIMER_CTL_PERIOSEL_Pos (20) /*!< TIMER_T::CTL: PERIOSEL Position */ 829 #define TIMER_CTL_PERIOSEL_Msk (0x1ul << TIMER_CTL_PERIOSEL_Pos) /*!< TIMER_T::CTL: PERIOSEL Mask */ 830 831 #define TIMER_CTL_TGLPINSEL_Pos (21) /*!< TIMER_T::CTL: TGLPINSEL Position */ 832 #define TIMER_CTL_TGLPINSEL_Msk (0x1ul << TIMER_CTL_TGLPINSEL_Pos) /*!< TIMER_T::CTL: TGLPINSEL Mask */ 833 834 #define TIMER_CTL_CAPSRC_Pos (22) /*!< TIMER_T::CTL: CAPSRC Position */ 835 #define TIMER_CTL_CAPSRC_Msk (0x1ul << TIMER_CTL_CAPSRC_Pos) /*!< TIMER_T::CTL: CAPSRC Mask */ 836 837 #define TIMER_CTL_WKEN_Pos (23) /*!< TIMER_T::CTL: WKEN Position */ 838 #define TIMER_CTL_WKEN_Msk (0x1ul << TIMER_CTL_WKEN_Pos) /*!< TIMER_T::CTL: WKEN Mask */ 839 840 #define TIMER_CTL_EXTCNTEN_Pos (24) /*!< TIMER_T::CTL: EXTCNTEN Position */ 841 #define TIMER_CTL_EXTCNTEN_Msk (0x1ul << TIMER_CTL_EXTCNTEN_Pos) /*!< TIMER_T::CTL: EXTCNTEN Mask */ 842 843 #define TIMER_CTL_ACTSTS_Pos (25) /*!< TIMER_T::CTL: ACTSTS Position */ 844 #define TIMER_CTL_ACTSTS_Msk (0x1ul << TIMER_CTL_ACTSTS_Pos) /*!< TIMER_T::CTL: ACTSTS Mask */ 845 846 #define TIMER_CTL_OPMODE_Pos (27) /*!< TIMER_T::CTL: OPMODE Position */ 847 #define TIMER_CTL_OPMODE_Msk (0x3ul << TIMER_CTL_OPMODE_Pos) /*!< TIMER_T::CTL: OPMODE Mask */ 848 849 #define TIMER_CTL_INTEN_Pos (29) /*!< TIMER_T::CTL: INTEN Position */ 850 #define TIMER_CTL_INTEN_Msk (0x1ul << TIMER_CTL_INTEN_Pos) /*!< TIMER_T::CTL: INTEN Mask */ 851 852 #define TIMER_CTL_CNTEN_Pos (30) /*!< TIMER_T::CTL: CNTEN Position */ 853 #define TIMER_CTL_CNTEN_Msk (0x1ul << TIMER_CTL_CNTEN_Pos) /*!< TIMER_T::CTL: CNTEN Mask */ 854 855 #define TIMER_CTL_ICEDEBUG_Pos (31) /*!< TIMER_T::CTL: ICEDEBUG Position */ 856 #define TIMER_CTL_ICEDEBUG_Msk (0x1ul << TIMER_CTL_ICEDEBUG_Pos) /*!< TIMER_T::CTL: ICEDEBUG Mask */ 857 858 #define TIMER_CMP_CMPDAT_Pos (0) /*!< TIMER_T::CMP: CMPDAT Position */ 859 #define TIMER_CMP_CMPDAT_Msk (0xfffffful << TIMER_CMP_CMPDAT_Pos) /*!< TIMER_T::CMP: CMPDAT Mask */ 860 861 #define TIMER_INTSTS_TIF_Pos (0) /*!< TIMER_T::INTSTS: TIF Position */ 862 #define TIMER_INTSTS_TIF_Msk (0x1ul << TIMER_INTSTS_TIF_Pos) /*!< TIMER_T::INTSTS: TIF Mask */ 863 864 #define TIMER_INTSTS_TWKF_Pos (1) /*!< TIMER_T::INTSTS: TWKF Position */ 865 #define TIMER_INTSTS_TWKF_Msk (0x1ul << TIMER_INTSTS_TWKF_Pos) /*!< TIMER_T::INTSTS: TWKF Mask */ 866 867 #define TIMER_CNT_CNT_Pos (0) /*!< TIMER_T::CNT: CNT Position */ 868 #define TIMER_CNT_CNT_Msk (0xfffffful << TIMER_CNT_CNT_Pos) /*!< TIMER_T::CNT: CNT Mask */ 869 870 #define TIMER_CNT_RSTACT_Pos (31) /*!< TIMER_T::CNT: RSTACT Position */ 871 #define TIMER_CNT_RSTACT_Msk (0x1ul << TIMER_CNT_RSTACT_Pos) /*!< TIMER_T::CNT: RSTACT Mask */ 872 873 #define TIMER_CAP_CAPDAT_Pos (0) /*!< TIMER_T::CAP: CAPDAT Position */ 874 #define TIMER_CAP_CAPDAT_Msk (0xfffffful << TIMER_CAP_CAPDAT_Pos) /*!< TIMER_T::CAP: CAPDAT Mask */ 875 876 #define TIMER_EXTCTL_CNTPHASE_Pos (0) /*!< TIMER_T::EXTCTL: CNTPHASE Position */ 877 #define TIMER_EXTCTL_CNTPHASE_Msk (0x1ul << TIMER_EXTCTL_CNTPHASE_Pos) /*!< TIMER_T::EXTCTL: CNTPHASE Mask */ 878 879 #define TIMER_EXTCTL_CAPEN_Pos (3) /*!< TIMER_T::EXTCTL: CAPEN Position */ 880 #define TIMER_EXTCTL_CAPEN_Msk (0x1ul << TIMER_EXTCTL_CAPEN_Pos) /*!< TIMER_T::EXTCTL: CAPEN Mask */ 881 882 #define TIMER_EXTCTL_CAPFUNCS_Pos (4) /*!< TIMER_T::EXTCTL: CAPFUNCS Position */ 883 #define TIMER_EXTCTL_CAPFUNCS_Msk (0x1ul << TIMER_EXTCTL_CAPFUNCS_Pos) /*!< TIMER_T::EXTCTL: CAPFUNCS Mask */ 884 885 #define TIMER_EXTCTL_CAPIEN_Pos (5) /*!< TIMER_T::EXTCTL: CAPIEN Position */ 886 #define TIMER_EXTCTL_CAPIEN_Msk (0x1ul << TIMER_EXTCTL_CAPIEN_Pos) /*!< TIMER_T::EXTCTL: CAPIEN Mask */ 887 888 #define TIMER_EXTCTL_CAPDBEN_Pos (6) /*!< TIMER_T::EXTCTL: CAPDBEN Position */ 889 #define TIMER_EXTCTL_CAPDBEN_Msk (0x1ul << TIMER_EXTCTL_CAPDBEN_Pos) /*!< TIMER_T::EXTCTL: CAPDBEN Mask */ 890 891 #define TIMER_EXTCTL_CNTDBEN_Pos (7) /*!< TIMER_T::EXTCTL: CNTDBEN Position */ 892 #define TIMER_EXTCTL_CNTDBEN_Msk (0x1ul << TIMER_EXTCTL_CNTDBEN_Pos) /*!< TIMER_T::EXTCTL: CNTDBEN Mask */ 893 894 #define TIMER_EXTCTL_INTERCAPSEL_Pos (8) /*!< TIMER_T::EXTCTL: INTERCAPSEL Position */ 895 #define TIMER_EXTCTL_INTERCAPSEL_Msk (0x7ul << TIMER_EXTCTL_INTERCAPSEL_Pos) /*!< TIMER_T::EXTCTL: INTERCAPSEL Mask */ 896 897 #define TIMER_EXTCTL_CAPEDGE_Pos (12) /*!< TIMER_T::EXTCTL: CAPEDGE Position */ 898 #define TIMER_EXTCTL_CAPEDGE_Msk (0x7ul << TIMER_EXTCTL_CAPEDGE_Pos) /*!< TIMER_T::EXTCTL: CAPEDGE Mask */ 899 900 #define TIMER_EXTCTL_ECNTSSEL_Pos (16) /*!< TIMER_T::EXTCTL: ECNTSSEL Position */ 901 #define TIMER_EXTCTL_ECNTSSEL_Msk (0x1ul << TIMER_EXTCTL_ECNTSSEL_Pos) /*!< TIMER_T::EXTCTL: ECNTSSEL Mask */ 902 903 #define TIMER_EXTCTL_CAPDIVSCL_Pos (28) /*!< TIMER_T::EXTCTL: CAPDIVSCL Position */ 904 #define TIMER_EXTCTL_CAPDIVSCL_Msk (0xful << TIMER_EXTCTL_CAPDIVSCL_Pos) /*!< TIMER_T::EXTCTL: CAPDIVSCL Mask */ 905 906 #define TIMER_EINTSTS_CAPIF_Pos (0) /*!< TIMER_T::EINTSTS: CAPIF Position */ 907 #define TIMER_EINTSTS_CAPIF_Msk (0x1ul << TIMER_EINTSTS_CAPIF_Pos) /*!< TIMER_T::EINTSTS: CAPIF Mask */ 908 909 #define TIMER_TRGCTL_TRGSSEL_Pos (0) /*!< TIMER_T::TRGCTL: TRGSSEL Position */ 910 #define TIMER_TRGCTL_TRGSSEL_Msk (0x1ul << TIMER_TRGCTL_TRGSSEL_Pos) /*!< TIMER_T::TRGCTL: TRGSSEL Mask */ 911 912 #define TIMER_TRGCTL_TRGPWM_Pos (1) /*!< TIMER_T::TRGCTL: TRGPWM Position */ 913 #define TIMER_TRGCTL_TRGPWM_Msk (0x1ul << TIMER_TRGCTL_TRGPWM_Pos) /*!< TIMER_T::TRGCTL: TRGPWM Mask */ 914 915 #define TIMER_TRGCTL_TRGEADC_Pos (2) /*!< TIMER_T::TRGCTL: TRGEADC Position */ 916 #define TIMER_TRGCTL_TRGEADC_Msk (0x1ul << TIMER_TRGCTL_TRGEADC_Pos) /*!< TIMER_T::TRGCTL: TRGEADC Mask */ 917 918 #define TIMER_TRGCTL_TRGDAC_Pos (3) /*!< TIMER_T::TRGCTL: TRGDAC Position */ 919 #define TIMER_TRGCTL_TRGDAC_Msk (0x1ul << TIMER_TRGCTL_TRGDAC_Pos) /*!< TIMER_T::TRGCTL: TRGDAC Mask */ 920 921 #define TIMER_TRGCTL_TRGPDMA_Pos (4) /*!< TIMER_T::TRGCTL: TRGPDMA Position */ 922 #define TIMER_TRGCTL_TRGPDMA_Msk (0x1ul << TIMER_TRGCTL_TRGPDMA_Pos) /*!< TIMER_T::TRGCTL: TRGPDMA Mask */ 923 924 #define TIMER_ALTCTL_FUNCSEL_Pos (0) /*!< TIMER_T::ALTCTL: FUNCSEL Position */ 925 #define TIMER_ALTCTL_FUNCSEL_Msk (0x1ul << TIMER_ALTCTL_FUNCSEL_Pos) /*!< TIMER_T::ALTCTL: FUNCSEL Mask */ 926 927 #define TIMER_PWMCTL_CNTEN_Pos (0) /*!< TIMER_T::PWMCTL: CNTEN Position */ 928 #define TIMER_PWMCTL_CNTEN_Msk (0x1ul << TIMER_PWMCTL_CNTEN_Pos) /*!< TIMER_T::PWMCTL: CNTEN Mask */ 929 930 #define TIMER_PWMCTL_CNTTYPE_Pos (1) /*!< TIMER_T::PWMCTL: CNTTYPE Position */ 931 #define TIMER_PWMCTL_CNTTYPE_Msk (0x3ul << TIMER_PWMCTL_CNTTYPE_Pos) /*!< TIMER_T::PWMCTL: CNTTYPE Mask */ 932 933 #define TIMER_PWMCTL_CNTMODE_Pos (3) /*!< TIMER_T::PWMCTL: CNTMODE Position */ 934 #define TIMER_PWMCTL_CNTMODE_Msk (0x1ul << TIMER_PWMCTL_CNTMODE_Pos) /*!< TIMER_T::PWMCTL: CNTMODE Mask */ 935 936 #define TIMER_PWMCTL_CTRLD_Pos (8) /*!< TIMER_T::PWMCTL: CTRLD Position */ 937 #define TIMER_PWMCTL_CTRLD_Msk (0x1ul << TIMER_PWMCTL_CTRLD_Pos) /*!< TIMER_T::PWMCTL: CTRLD Mask */ 938 939 #define TIMER_PWMCTL_IMMLDEN_Pos (9) /*!< TIMER_T::PWMCTL: IMMLDEN Position */ 940 #define TIMER_PWMCTL_IMMLDEN_Msk (0x1ul << TIMER_PWMCTL_IMMLDEN_Pos) /*!< TIMER_T::PWMCTL: IMMLDEN Mask */ 941 942 #define TIMER_PWMCTL_WKEN_Pos (12) /*!< TIMER_T::PWMCTL: WKEN Position */ 943 #define TIMER_PWMCTL_WKEN_Msk (0x1ul << TIMER_PWMCTL_WKEN_Pos) /*!< TIMER_T::PWMCTL: WKEN Mask */ 944 945 #define TIMER_PWMCTL_OUTMODE_Pos (16) /*!< TIMER_T::PWMCTL: OUTMODE Position */ 946 #define TIMER_PWMCTL_OUTMODE_Msk (0x1ul << TIMER_PWMCTL_OUTMODE_Pos) /*!< TIMER_T::PWMCTL: OUTMODE Mask */ 947 948 #define TIMER_PWMCTL_DBGHALT_Pos (30) /*!< TIMER_T::PWMCTL: DBGHALT Position */ 949 #define TIMER_PWMCTL_DBGHALT_Msk (0x1ul << TIMER_PWMCTL_DBGHALT_Pos) /*!< TIMER_T::PWMCTL: DBGHALT Mask */ 950 951 #define TIMER_PWMCTL_DBGTRIOFF_Pos (31) /*!< TIMER_T::PWMCTL: DBGTRIOFF Position */ 952 #define TIMER_PWMCTL_DBGTRIOFF_Msk (0x1ul << TIMER_PWMCTL_DBGTRIOFF_Pos) /*!< TIMER_T::PWMCTL: DBGTRIOFF Mask */ 953 954 #define TIMER_PWMCLKSRC_CLKSRC_Pos (0) /*!< TIMER_T::PWMCLKSRC: CLKSRC Position */ 955 #define TIMER_PWMCLKSRC_CLKSRC_Msk (0x7ul << TIMER_PWMCLKSRC_CLKSRC_Pos) /*!< TIMER_T::PWMCLKSRC: CLKSRC Mask */ 956 957 #define TIMER_PWMCLKPSC_CLKPSC_Pos (0) /*!< TIMER_T::PWMCLKPSC: CLKPSC Position */ 958 #define TIMER_PWMCLKPSC_CLKPSC_Msk (0xffful << TIMER_PWMCLKPSC_CLKPSC_Pos) /*!< TIMER_T::PWMCLKPSC: CLKPSC Mask */ 959 960 #define TIMER_PWMCNTCLR_CNTCLR_Pos (0) /*!< TIMER_T::PWMCNTCLR: CNTCLR Position */ 961 #define TIMER_PWMCNTCLR_CNTCLR_Msk (0x1ul << TIMER_PWMCNTCLR_CNTCLR_Pos) /*!< TIMER_T::PWMCNTCLR: CNTCLR Mask */ 962 963 #define TIMER_PWMPERIOD_PERIOD_Pos (0) /*!< TIMER_T::PWMPERIOD: PERIOD Position */ 964 #define TIMER_PWMPERIOD_PERIOD_Msk (0xfffful << TIMER_PWMPERIOD_PERIOD_Pos) /*!< TIMER_T::PWMPERIOD: PERIOD Mask */ 965 966 #define TIMER_PWMCMPDAT_CMP_Pos (0) /*!< TIMER_T::PWMCMPDAT: CMP Position */ 967 #define TIMER_PWMCMPDAT_CMP_Msk (0xfffful << TIMER_PWMCMPDAT_CMP_Pos) /*!< TIMER_T::PWMCMPDAT: CMP Mask */ 968 969 #define TIMER_PWMDTCTL_DTCNT_Pos (0) /*!< TIMER_T::PWMDTCTL: DTCNT Position */ 970 #define TIMER_PWMDTCTL_DTCNT_Msk (0xffful << TIMER_PWMDTCTL_DTCNT_Pos) /*!< TIMER_T::PWMDTCTL: DTCNT Mask */ 971 972 #define TIMER_PWMDTCTL_DTEN_Pos (16) /*!< TIMER_T::PWMDTCTL: DTEN Position */ 973 #define TIMER_PWMDTCTL_DTEN_Msk (0x1ul << TIMER_PWMDTCTL_DTEN_Pos) /*!< TIMER_T::PWMDTCTL: DTEN Mask */ 974 975 #define TIMER_PWMDTCTL_DTCKSEL_Pos (24) /*!< TIMER_T::PWMDTCTL: DTCKSEL Position */ 976 #define TIMER_PWMDTCTL_DTCKSEL_Msk (0x1ul << TIMER_PWMDTCTL_DTCKSEL_Pos) /*!< TIMER_T::PWMDTCTL: DTCKSEL Mask */ 977 978 #define TIMER_PWMCNT_CNT_Pos (0) /*!< TIMER_T::PWMCNT: CNT Position */ 979 #define TIMER_PWMCNT_CNT_Msk (0xfffful << TIMER_PWMCNT_CNT_Pos) /*!< TIMER_T::PWMCNT: CNT Mask */ 980 981 #define TIMER_PWMCNT_DIRF_Pos (16) /*!< TIMER_T::PWMCNT: DIRF Position */ 982 #define TIMER_PWMCNT_DIRF_Msk (0x1ul << TIMER_PWMCNT_DIRF_Pos) /*!< TIMER_T::PWMCNT: DIRF Mask */ 983 984 #define TIMER_PWMMSKEN_MSKEN0_Pos (0) /*!< TIMER_T::PWMMSKEN: MSKEN0 Position */ 985 #define TIMER_PWMMSKEN_MSKEN0_Msk (0x1ul << TIMER_PWMMSKEN_MSKEN0_Pos) /*!< TIMER_T::PWMMSKEN: MSKEN0 Mask */ 986 987 #define TIMER_PWMMSKEN_MSKEN1_Pos (1) /*!< TIMER_T::PWMMSKEN: MSKEN1 Position */ 988 #define TIMER_PWMMSKEN_MSKEN1_Msk (0x1ul << TIMER_PWMMSKEN_MSKEN1_Pos) /*!< TIMER_T::PWMMSKEN: MSKEN1 Mask */ 989 990 #define TIMER_PWMMSK_MSKDAT0_Pos (0) /*!< TIMER_T::PWMMSK: MSKDAT0 Position */ 991 #define TIMER_PWMMSK_MSKDAT0_Msk (0x1ul << TIMER_PWMMSK_MSKDAT0_Pos) /*!< TIMER_T::PWMMSK: MSKDAT0 Mask */ 992 993 #define TIMER_PWMMSK_MSKDAT1_Pos (1) /*!< TIMER_T::PWMMSK: MSKDAT1 Position */ 994 #define TIMER_PWMMSK_MSKDAT1_Msk (0x1ul << TIMER_PWMMSK_MSKDAT1_Pos) /*!< TIMER_T::PWMMSK: MSKDAT1 Mask */ 995 996 #define TIMER_PWMBNF_BRKNFEN_Pos (0) /*!< TIMER_T::PWMBNF: BRKNFEN Position */ 997 #define TIMER_PWMBNF_BRKNFEN_Msk (0x1ul << TIMER_PWMBNF_BRKNFEN_Pos) /*!< TIMER_T::PWMBNF: BRKNFEN Mask */ 998 999 #define TIMER_PWMBNF_BRKNFSEL_Pos (1) /*!< TIMER_T::PWMBNF: BRKNFSEL Position */ 1000 #define TIMER_PWMBNF_BRKNFSEL_Msk (0x7ul << TIMER_PWMBNF_BRKNFSEL_Pos) /*!< TIMER_T::PWMBNF: BRKNFSEL Mask */ 1001 1002 #define TIMER_PWMBNF_BRKFCNT_Pos (4) /*!< TIMER_T::PWMBNF: BRKFCNT Position */ 1003 #define TIMER_PWMBNF_BRKFCNT_Msk (0x7ul << TIMER_PWMBNF_BRKFCNT_Pos) /*!< TIMER_T::PWMBNF: BRKFCNT Mask */ 1004 1005 #define TIMER_PWMBNF_BRKPINV_Pos (7) /*!< TIMER_T::PWMBNF: BRKPINV Position */ 1006 #define TIMER_PWMBNF_BRKPINV_Msk (0x1ul << TIMER_PWMBNF_BRKPINV_Pos) /*!< TIMER_T::PWMBNF: BRKPINV Mask */ 1007 1008 #define TIMER_PWMBNF_BKPINSRC_Pos (16) /*!< TIMER_T::PWMBNF: BKPINSRC Position */ 1009 #define TIMER_PWMBNF_BKPINSRC_Msk (0x3ul << TIMER_PWMBNF_BKPINSRC_Pos) /*!< TIMER_T::PWMBNF: BKPINSRC Mask */ 1010 1011 #define TIMER_PWMFAILBRK_CSSBRKEN_Pos (0) /*!< TIMER_T::PWMFAILBRK: CSSBRKEN Position */ 1012 #define TIMER_PWMFAILBRK_CSSBRKEN_Msk (0x1ul << TIMER_PWMFAILBRK_CSSBRKEN_Pos) /*!< TIMER_T::PWMFAILBRK: CSSBRKEN Mask */ 1013 1014 #define TIMER_PWMFAILBRK_BODBRKEN_Pos (1) /*!< TIMER_T::PWMFAILBRK: BODBRKEN Position */ 1015 #define TIMER_PWMFAILBRK_BODBRKEN_Msk (0x1ul << TIMER_PWMFAILBRK_BODBRKEN_Pos) /*!< TIMER_T::PWMFAILBRK: BODBRKEN Mask */ 1016 1017 #define TIMER_PWMFAILBRK_RAMBRKEN_Pos (2) /*!< TIMER_T::PWMFAILBRK: RAMBRKEN Position */ 1018 #define TIMER_PWMFAILBRK_RAMBRKEN_Msk (0x1ul << TIMER_PWMFAILBRK_RAMBRKEN_Pos) /*!< TIMER_T::PWMFAILBRK: RAMBRKEN Mask */ 1019 1020 #define TIMER_PWMFAILBRK_CORBRKEN_Pos (3) /*!< TIMER_T::PWMFAILBRK: CORBRKEN Position */ 1021 #define TIMER_PWMFAILBRK_CORBRKEN_Msk (0x1ul << TIMER_PWMFAILBRK_CORBRKEN_Pos) /*!< TIMER_T::PWMFAILBRK: CORBRKEN Mask */ 1022 1023 #define TIMER_PWMBRKCTL_CPO0EBEN_Pos (0) /*!< TIMER_T::PWMBRKCTL: CPO0EBEN Position */ 1024 #define TIMER_PWMBRKCTL_CPO0EBEN_Msk (0x1ul << TIMER_PWMBRKCTL_CPO0EBEN_Pos) /*!< TIMER_T::PWMBRKCTL: CPO0EBEN Mask */ 1025 1026 #define TIMER_PWMBRKCTL_CPO1EBEN_Pos (1) /*!< TIMER_T::PWMBRKCTL: CPO1EBEN Position */ 1027 #define TIMER_PWMBRKCTL_CPO1EBEN_Msk (0x1ul << TIMER_PWMBRKCTL_CPO1EBEN_Pos) /*!< TIMER_T::PWMBRKCTL: CPO1EBEN Mask */ 1028 1029 #define TIMER_PWMBRKCTL_BRKPEEN_Pos (4) /*!< TIMER_T::PWMBRKCTL: BRKPEEN Position */ 1030 #define TIMER_PWMBRKCTL_BRKPEEN_Msk (0x1ul << TIMER_PWMBRKCTL_BRKPEEN_Pos) /*!< TIMER_T::PWMBRKCTL: BRKPEEN Mask */ 1031 1032 #define TIMER_PWMBRKCTL_SYSEBEN_Pos (7) /*!< TIMER_T::PWMBRKCTL: SYSEBEN Position */ 1033 #define TIMER_PWMBRKCTL_SYSEBEN_Msk (0x1ul << TIMER_PWMBRKCTL_SYSEBEN_Pos) /*!< TIMER_T::PWMBRKCTL: SYSEBEN Mask */ 1034 1035 #define TIMER_PWMBRKCTL_CPO0LBEN_Pos (8) /*!< TIMER_T::PWMBRKCTL: CPO0LBEN Position */ 1036 #define TIMER_PWMBRKCTL_CPO0LBEN_Msk (0x1ul << TIMER_PWMBRKCTL_CPO0LBEN_Pos) /*!< TIMER_T::PWMBRKCTL: CPO0LBEN Mask */ 1037 1038 #define TIMER_PWMBRKCTL_CPO1LBEN_Pos (9) /*!< TIMER_T::PWMBRKCTL: CPO1LBEN Position */ 1039 #define TIMER_PWMBRKCTL_CPO1LBEN_Msk (0x1ul << TIMER_PWMBRKCTL_CPO1LBEN_Pos) /*!< TIMER_T::PWMBRKCTL: CPO1LBEN Mask */ 1040 1041 #define TIMER_PWMBRKCTL_BRKPLEN_Pos (12) /*!< TIMER_T::PWMBRKCTL: BRKPLEN Position */ 1042 #define TIMER_PWMBRKCTL_BRKPLEN_Msk (0x1ul << TIMER_PWMBRKCTL_BRKPLEN_Pos) /*!< TIMER_T::PWMBRKCTL: BRKPLEN Mask */ 1043 1044 #define TIMER_PWMBRKCTL_SYSLBEN_Pos (15) /*!< TIMER_T::PWMBRKCTL: SYSLBEN Position */ 1045 #define TIMER_PWMBRKCTL_SYSLBEN_Msk (0x1ul << TIMER_PWMBRKCTL_SYSLBEN_Pos) /*!< TIMER_T::PWMBRKCTL: SYSLBEN Mask */ 1046 1047 #define TIMER_PWMBRKCTL_BRKAEVEN_Pos (16) /*!< TIMER_T::PWMBRKCTL: BRKAEVEN Position */ 1048 #define TIMER_PWMBRKCTL_BRKAEVEN_Msk (0x3ul << TIMER_PWMBRKCTL_BRKAEVEN_Pos) /*!< TIMER_T::PWMBRKCTL: BRKAEVEN Mask */ 1049 1050 #define TIMER_PWMBRKCTL_BRKAODD_Pos (18) /*!< TIMER_T::PWMBRKCTL: BRKAODD Position */ 1051 #define TIMER_PWMBRKCTL_BRKAODD_Msk (0x3ul << TIMER_PWMBRKCTL_BRKAODD_Pos) /*!< TIMER_T::PWMBRKCTL: BRKAODD Mask */ 1052 1053 #define TIMER_PWMPOLCTL_PINV0_Pos (0) /*!< TIMER_T::PWMPOLCTL: PINV0 Position */ 1054 #define TIMER_PWMPOLCTL_PINV0_Msk (0x1ul << TIMER_PWMPOLCTL_PINV0_Pos) /*!< TIMER_T::PWMPOLCTL: PINV0 Mask */ 1055 1056 #define TIMER_PWMPOLCTL_PINV1_Pos (1) /*!< TIMER_T::PWMPOLCTL: PINV1 Position */ 1057 #define TIMER_PWMPOLCTL_PINV1_Msk (0x1ul << TIMER_PWMPOLCTL_PINV1_Pos) /*!< TIMER_T::PWMPOLCTL: PINV1 Mask */ 1058 1059 #define TIMER_PWMPOEN_POEN0_Pos (0) /*!< TIMER_T::PWMPOEN: POEN0 Position */ 1060 #define TIMER_PWMPOEN_POEN0_Msk (0x1ul << TIMER_PWMPOEN_POEN0_Pos) /*!< TIMER_T::PWMPOEN: POEN0 Mask */ 1061 1062 #define TIMER_PWMPOEN_POEN1_Pos (1) /*!< TIMER_T::PWMPOEN: POEN1 Position */ 1063 #define TIMER_PWMPOEN_POEN1_Msk (0x1ul << TIMER_PWMPOEN_POEN1_Pos) /*!< TIMER_T::PWMPOEN: POEN1 Mask */ 1064 1065 #define TIMER_PWMPOEN_POSEL_Pos (8) /*!< TIMER_T::PWMPOEN: POSEL Position */ 1066 #define TIMER_PWMPOEN_POSEL_Msk (0x1ul << TIMER_PWMPOEN_POSEL_Pos) /*!< TIMER_T::PWMPOEN: POSEL Mask */ 1067 1068 #define TIMER_PWMSWBRK_BRKETRG_Pos (0) /*!< TIMER_T::PWMSWBRK: BRKETRG Position */ 1069 #define TIMER_PWMSWBRK_BRKETRG_Msk (0x1ul << TIMER_PWMSWBRK_BRKETRG_Pos) /*!< TIMER_T::PWMSWBRK: BRKETRG Mask */ 1070 1071 #define TIMER_PWMSWBRK_BRKLTRG_Pos (8) /*!< TIMER_T::PWMSWBRK: BRKLTRG Position */ 1072 #define TIMER_PWMSWBRK_BRKLTRG_Msk (0x1ul << TIMER_PWMSWBRK_BRKLTRG_Pos) /*!< TIMER_T::PWMSWBRK: BRKLTRG Mask */ 1073 1074 #define TIMER_PWMINTEN0_ZIEN_Pos (0) /*!< TIMER_T::PWMINTEN0: ZIEN Position */ 1075 #define TIMER_PWMINTEN0_ZIEN_Msk (0x1ul << TIMER_PWMINTEN0_ZIEN_Pos) /*!< TIMER_T::PWMINTEN0: ZIEN Mask */ 1076 1077 #define TIMER_PWMINTEN0_PIEN_Pos (1) /*!< TIMER_T::PWMINTEN0: PIEN Position */ 1078 #define TIMER_PWMINTEN0_PIEN_Msk (0x1ul << TIMER_PWMINTEN0_PIEN_Pos) /*!< TIMER_T::PWMINTEN0: PIEN Mask */ 1079 1080 #define TIMER_PWMINTEN0_CMPUIEN_Pos (2) /*!< TIMER_T::PWMINTEN0: CMPUIEN Position */ 1081 #define TIMER_PWMINTEN0_CMPUIEN_Msk (0x1ul << TIMER_PWMINTEN0_CMPUIEN_Pos) /*!< TIMER_T::PWMINTEN0: CMPUIEN Mask */ 1082 1083 #define TIMER_PWMINTEN0_CMPDIEN_Pos (3) /*!< TIMER_T::PWMINTEN0: CMPDIEN Position */ 1084 #define TIMER_PWMINTEN0_CMPDIEN_Msk (0x1ul << TIMER_PWMINTEN0_CMPDIEN_Pos) /*!< TIMER_T::PWMINTEN0: CMPDIEN Mask */ 1085 1086 #define TIMER_PWMINTEN1_BRKEIEN_Pos (0) /*!< TIMER_T::PWMINTEN1: BRKEIEN Position */ 1087 #define TIMER_PWMINTEN1_BRKEIEN_Msk (0x1ul << TIMER_PWMINTEN1_BRKEIEN_Pos) /*!< TIMER_T::PWMINTEN1: BRKEIEN Mask */ 1088 1089 #define TIMER_PWMINTEN1_BRKLIEN_Pos (8) /*!< TIMER_T::PWMINTEN1: BRKLIEN Position */ 1090 #define TIMER_PWMINTEN1_BRKLIEN_Msk (0x1ul << TIMER_PWMINTEN1_BRKLIEN_Pos) /*!< TIMER_T::PWMINTEN1: BRKLIEN Mask */ 1091 1092 #define TIMER_PWMINTSTS0_ZIF_Pos (0) /*!< TIMER_T::PWMINTSTS0: ZIF Position */ 1093 #define TIMER_PWMINTSTS0_ZIF_Msk (0x1ul << TIMER_PWMINTSTS0_ZIF_Pos) /*!< TIMER_T::PWMINTSTS0: ZIF Mask */ 1094 1095 #define TIMER_PWMINTSTS0_PIF_Pos (1) /*!< TIMER_T::PWMINTSTS0: PIF Position */ 1096 #define TIMER_PWMINTSTS0_PIF_Msk (0x1ul << TIMER_PWMINTSTS0_PIF_Pos) /*!< TIMER_T::PWMINTSTS0: PIF Mask */ 1097 1098 #define TIMER_PWMINTSTS0_CMPUIF_Pos (2) /*!< TIMER_T::PWMINTSTS0: CMPUIF Position */ 1099 #define TIMER_PWMINTSTS0_CMPUIF_Msk (0x1ul << TIMER_PWMINTSTS0_CMPUIF_Pos) /*!< TIMER_T::PWMINTSTS0: CMPUIF Mask */ 1100 1101 #define TIMER_PWMINTSTS0_CMPDIF_Pos (3) /*!< TIMER_T::PWMINTSTS0: CMPDIF Position */ 1102 #define TIMER_PWMINTSTS0_CMPDIF_Msk (0x1ul << TIMER_PWMINTSTS0_CMPDIF_Pos) /*!< TIMER_T::PWMINTSTS0: CMPDIF Mask */ 1103 1104 #define TIMER_PWMINTSTS1_BRKEIF0_Pos (0) /*!< TIMER_T::PWMINTSTS1: BRKEIF0 Position */ 1105 #define TIMER_PWMINTSTS1_BRKEIF0_Msk (0x1ul << TIMER_PWMINTSTS1_BRKEIF0_Pos) /*!< TIMER_T::PWMINTSTS1: BRKEIF0 Mask */ 1106 1107 #define TIMER_PWMINTSTS1_BRKEIF1_Pos (1) /*!< TIMER_T::PWMINTSTS1: BRKEIF1 Position */ 1108 #define TIMER_PWMINTSTS1_BRKEIF1_Msk (0x1ul << TIMER_PWMINTSTS1_BRKEIF1_Pos) /*!< TIMER_T::PWMINTSTS1: BRKEIF1 Mask */ 1109 1110 #define TIMER_PWMINTSTS1_BRKLIF0_Pos (8) /*!< TIMER_T::PWMINTSTS1: BRKLIF0 Position */ 1111 #define TIMER_PWMINTSTS1_BRKLIF0_Msk (0x1ul << TIMER_PWMINTSTS1_BRKLIF0_Pos) /*!< TIMER_T::PWMINTSTS1: BRKLIF0 Mask */ 1112 1113 #define TIMER_PWMINTSTS1_BRKLIF1_Pos (9) /*!< TIMER_T::PWMINTSTS1: BRKLIF1 Position */ 1114 #define TIMER_PWMINTSTS1_BRKLIF1_Msk (0x1ul << TIMER_PWMINTSTS1_BRKLIF1_Pos) /*!< TIMER_T::PWMINTSTS1: BRKLIF1 Mask */ 1115 1116 #define TIMER_PWMINTSTS1_BRKESTS0_Pos (16) /*!< TIMER_T::PWMINTSTS1: BRKESTS0 Position */ 1117 #define TIMER_PWMINTSTS1_BRKESTS0_Msk (0x1ul << TIMER_PWMINTSTS1_BRKESTS0_Pos) /*!< TIMER_T::PWMINTSTS1: BRKESTS0 Mask */ 1118 1119 #define TIMER_PWMINTSTS1_BRKESTS1_Pos (17) /*!< TIMER_T::PWMINTSTS1: BRKESTS1 Position */ 1120 #define TIMER_PWMINTSTS1_BRKESTS1_Msk (0x1ul << TIMER_PWMINTSTS1_BRKESTS1_Pos) /*!< TIMER_T::PWMINTSTS1: BRKESTS1 Mask */ 1121 1122 #define TIMER_PWMINTSTS1_BRKLSTS0_Pos (24) /*!< TIMER_T::PWMINTSTS1: BRKLSTS0 Position */ 1123 #define TIMER_PWMINTSTS1_BRKLSTS0_Msk (0x1ul << TIMER_PWMINTSTS1_BRKLSTS0_Pos) /*!< TIMER_T::PWMINTSTS1: BRKLSTS0 Mask */ 1124 1125 #define TIMER_PWMINTSTS1_BRKLSTS1_Pos (25) /*!< TIMER_T::PWMINTSTS1: BRKLSTS1 Position */ 1126 #define TIMER_PWMINTSTS1_BRKLSTS1_Msk (0x1ul << TIMER_PWMINTSTS1_BRKLSTS1_Pos) /*!< TIMER_T::PWMINTSTS1: BRKLSTS1 Mask */ 1127 1128 #define TIMER_PWMTRGCTL_TRGSEL_Pos (0) /*!< TIMER_T::PWMTRGCTL: TRGSEL Position */ 1129 #define TIMER_PWMTRGCTL_TRGSEL_Msk (0x7ul << TIMER_PWMTRGCTL_TRGSEL_Pos) /*!< TIMER_T::PWMTRGCTL: TRGSEL Mask */ 1130 1131 #define TIMER_PWMTRGCTL_TRGEADC_Pos (7) /*!< TIMER_T::PWMTRGCTL: TRGEADC Position */ 1132 #define TIMER_PWMTRGCTL_TRGEADC_Msk (0x1ul << TIMER_PWMTRGCTL_TRGEADC_Pos) /*!< TIMER_T::PWMTRGCTL: TRGEADC Mask */ 1133 1134 #define TIMER_PWMTRGCTL_TRGPDMA_Pos (9) /*!< TIMER_T::PWMTRGCTL: TRGPDMA Position */ 1135 #define TIMER_PWMTRGCTL_TRGPDMA_Msk (0x1ul << TIMER_PWMTRGCTL_TRGPDMA_Pos) /*!< TIMER_T::PWMTRGCTL: TRGPDMA Mask */ 1136 1137 #define TIMER_PWMSCTL_SYNCMODE_Pos (0) /*!< TIMER_T::PWMSCTL: SYNCMODE Position */ 1138 #define TIMER_PWMSCTL_SYNCMODE_Msk (0x3ul << TIMER_PWMSCTL_SYNCMODE_Pos) /*!< TIMER_T::PWMSCTL: SYNCMODE Mask */ 1139 1140 #define TIMER_PWMSCTL_SYNCSRC_Pos (8) /*!< TIMER_T::PWMSCTL: SYNCSRC Position */ 1141 #define TIMER_PWMSCTL_SYNCSRC_Msk (0x1ul << TIMER_PWMSCTL_SYNCSRC_Pos) /*!< TIMER_T::PWMSCTL: SYNCSRC Mask */ 1142 1143 #define TIMER_PWMSTRG_STRGEN_Pos (0) /*!< TIMER_T::PWMSTRG: STRGEN Position */ 1144 #define TIMER_PWMSTRG_STRGEN_Msk (0x1ul << TIMER_PWMSTRG_STRGEN_Pos) /*!< TIMER_T::PWMSTRG: STRGEN Mask */ 1145 1146 #define TIMER_PWMSTATUS_CNTMAXF_Pos (0) /*!< TIMER_T::PWMSTATUS: CNTMAXF Position */ 1147 #define TIMER_PWMSTATUS_CNTMAXF_Msk (0x1ul << TIMER_PWMSTATUS_CNTMAXF_Pos) /*!< TIMER_T::PWMSTATUS: CNTMAXF Mask */ 1148 1149 #define TIMER_PWMSTATUS_WKF_Pos (8) /*!< TIMER_T::PWMSTATUS: WKF Position */ 1150 #define TIMER_PWMSTATUS_WKF_Msk (0x1ul << TIMER_PWMSTATUS_WKF_Pos) /*!< TIMER_T::PWMSTATUS: WKF Mask */ 1151 1152 #define TIMER_PWMSTATUS_EADCTRGF_Pos (16) /*!< TIMER_T::PWMSTATUS: EADCTRGF Position */ 1153 #define TIMER_PWMSTATUS_EADCTRGF_Msk (0x1ul << TIMER_PWMSTATUS_EADCTRGF_Pos) /*!< TIMER_T::PWMSTATUS: EADCTRGF Mask */ 1154 1155 #define TIMER_PWMSTATUS_PDMATRGF_Pos (18) /*!< TIMER_T::PWMSTATUS: PDMATRGF Position */ 1156 #define TIMER_PWMSTATUS_PDMATRGF_Msk (0x1ul << TIMER_PWMSTATUS_PDMATRGF_Pos) /*!< TIMER_T::PWMSTATUS: PDMATRGF Mask */ 1157 1158 #define TIMER_PWMPBUF_PBUF_Pos (0) /*!< TIMER_T::PWMPBUF: PBUF Position */ 1159 #define TIMER_PWMPBUF_PBUF_Msk (0xfffful << TIMER_PWMPBUF_PBUF_Pos) /*!< TIMER_T::PWMPBUF: PBUF Mask */ 1160 1161 #define TIMER_PWMCMPBUF_CMPBUF_Pos (0) /*!< TIMER_T::PWMCMPBUF: CMPBUF Position */ 1162 #define TIMER_PWMCMPBUF_CMPBUF_Msk (0xfffful << TIMER_PWMCMPBUF_CMPBUF_Pos) /*!< TIMER_T::PWMCMPBUF: CMPBUF Mask */ 1163 1164 /**@}*/ /* TIMER_CONST */ 1165 /**@}*/ /* end of TIMER register group */ 1166 /**@}*/ /* end of REGISTER group */ 1167 1168 #endif /* __TIMER_REG_H__ */ 1169