Home
last modified time | relevance | path

Searched refs:u32Prescale (Results 1 – 12 of 12) sorted by relevance

/hal_nuvoton-latest/m2l31x/StdDriver/src/
Dttmr.c42 uint32_t u32Cmpr = 0UL, u32Prescale = 0UL; in TTMR_Open() local
55 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TTMR_Open()
56 if (u32Prescale > 0UL) in TTMR_Open()
57 u32Cmpr = u32Cmpr / (u32Prescale + 1UL); in TTMR_Open()
60 ttmr->CTL = (u32Mode | u32Prescale); in TTMR_Open()
63 return(u32Clk / (u32Cmpr * (u32Prescale + 1UL))); in TTMR_Open()
98 uint32_t u32Prescale = 0UL, u32Delay; in TTMR_Delay() local
129 u32Prescale = 0UL; in TTMR_Delay()
136 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TTMR_Delay()
137 if (u32Prescale > 0UL) in TTMR_Delay()
[all …]
Dlptmr.c44 uint32_t u32Cmpr = 0UL, u32Prescale = 0UL; in LPTMR_Open() local
57 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in LPTMR_Open()
58 if (u32Prescale > 0UL) in LPTMR_Open()
59 u32Cmpr = u32Cmpr / (u32Prescale + 1UL); in LPTMR_Open()
62 lptmr->CTL = (u32Mode | u32Prescale); in LPTMR_Open()
65 return(u32Clk / (u32Cmpr * (u32Prescale + 1UL))); in LPTMR_Open()
101 uint32_t u32Prescale = 0UL, u32Delay; in LPTMR_Delay() local
133 u32Prescale = 0UL; in LPTMR_Delay()
140 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in LPTMR_Delay()
141 if (u32Prescale > 0UL) in LPTMR_Delay()
[all …]
Dtimer.c45 uint32_t u32Cmpr = 0UL, u32Prescale = 0UL; in TIMER_Open() local
55 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TIMER_Open()
56 if (u32Prescale > 0UL) in TIMER_Open()
57 u32Cmpr = u32Cmpr / (u32Prescale + 1UL); in TIMER_Open()
60 timer->CTL = u32Mode | u32Prescale; in TIMER_Open()
63 return(u32Clk / (u32Cmpr * (u32Prescale + 1UL))); in TIMER_Open()
100 uint32_t u32Prescale = 0UL, u32Delay; in TIMER_Delay() local
132 u32Prescale = 0UL; in TIMER_Delay()
139 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TIMER_Delay()
140 if (u32Prescale > 0UL) in TIMER_Delay()
[all …]
Depwm.c138 uint32_t u32Prescale = 1U, u32CNR = 0xFFFFU; in EPWM_ConfigOutputChannel() local
168 for(u32Prescale = 1U; u32Prescale < 0xFFFU; u32Prescale++) /* prescale could be 0~0xFFF */ in EPWM_ConfigOutputChannel()
170 i = (u32EPWMClockSrc / u32Frequency) / u32Prescale; in EPWM_ConfigOutputChannel()
179 i = u32EPWMClockSrc / (u32Prescale * u32CNR); in EPWM_ConfigOutputChannel()
183 u32Prescale -= 1U; in EPWM_ConfigOutputChannel()
184 EPWM_SET_PRESCALER(epwm, u32ChannelNum, u32Prescale); in EPWM_ConfigOutputChannel()
327 int32_t EPWM_EnableADCTriggerPrescale(EPWM_T *epwm, uint32_t u32ChannelNum, uint32_t u32Prescale, u… in EPWM_EnableADCTriggerPrescale() argument
336 (u32Prescale << (u32ChannelNum << 3)); in EPWM_EnableADCTriggerPrescale()
343 (u32Prescale << ((u32ChannelNum - 4UL) << 3)); in EPWM_EnableADCTriggerPrescale()
/hal_nuvoton-latest/m48x/StdDriver/src/
Dtimer.c44 uint32_t u32Cmpr = 0UL, u32Prescale = 0UL; in TIMER_Open() local
54 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TIMER_Open()
55 if (u32Prescale > 0UL) in TIMER_Open()
56 u32Cmpr = u32Cmpr / (u32Prescale + 1UL); in TIMER_Open()
59 timer->CTL = u32Mode | u32Prescale; in TIMER_Open()
62 return(u32Clk / (u32Cmpr * (u32Prescale + 1UL))); in TIMER_Open()
95 uint32_t u32Prescale = 0UL, delay = (SystemCoreClock / u32Clk) + 1UL; in TIMER_Delay() local
127 u32Prescale = 0UL; in TIMER_Delay()
134 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TIMER_Delay()
135 if (u32Prescale > 0UL) in TIMER_Delay()
[all …]
Dbpwm.c135 uint32_t u32Prescale = 1U, u32CNR = 0xFFFFU; in BPWM_ConfigOutputChannel() local
165 for(u32Prescale = 1U; u32Prescale < 0xFFFU; u32Prescale++) /* prescale could be 0~0xFFF */ in BPWM_ConfigOutputChannel()
167 i = (u32PWMClockSrc / u32Frequency) / u32Prescale; in BPWM_ConfigOutputChannel()
176 i = u32PWMClockSrc / (u32Prescale * u32CNR); in BPWM_ConfigOutputChannel()
180 u32Prescale -= 1U; in BPWM_ConfigOutputChannel()
181 BPWM_SET_PRESCALER(bpwm, u32ChannelNum, u32Prescale); in BPWM_ConfigOutputChannel()
Depwm.c140 uint32_t u32Prescale = 1U, u32CNR = 0xFFFFU; in EPWM_ConfigOutputChannel() local
170 for(u32Prescale = 1U; u32Prescale < 0xFFFU; u32Prescale++) /* prescale could be 0~0xFFF */ in EPWM_ConfigOutputChannel()
172 i = (u32EPWMClockSrc / u32Frequency) / u32Prescale; in EPWM_ConfigOutputChannel()
181 i = u32EPWMClockSrc / (u32Prescale * u32CNR); in EPWM_ConfigOutputChannel()
185 u32Prescale -= 1U; in EPWM_ConfigOutputChannel()
186 EPWM_SET_PRESCALER(epwm, u32ChannelNum, u32Prescale); in EPWM_ConfigOutputChannel()
/hal_nuvoton-latest/m46x/StdDriver/src/
Dtimer.c45 uint32_t u32Cmpr = 0UL, u32Prescale = 0UL; in TIMER_Open() local
55 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TIMER_Open()
56 if (u32Prescale > 0UL) in TIMER_Open()
57 u32Cmpr = u32Cmpr / (u32Prescale + 1UL); in TIMER_Open()
60 timer->CTL = u32Mode | u32Prescale; in TIMER_Open()
63 return(u32Clk / (u32Cmpr * (u32Prescale + 1UL))); in TIMER_Open()
97 uint32_t u32Prescale = 0UL, u32Delay; in TIMER_Delay() local
129 u32Prescale = 0UL; in TIMER_Delay()
136 u32Prescale = (u32Cmpr >> 24); /* for 24 bits CMPDAT */ in TIMER_Delay()
137 if (u32Prescale > 0UL) in TIMER_Delay()
[all …]
Dbpwm.c40 uint32_t u32Prescale = 1U, u32CNR = 0xFFFFU; in BPWM_ConfigCaptureChannel() local
74 for(u32Prescale = 1U; u32Prescale <= 0x1000UL; u32Prescale++) in BPWM_ConfigCaptureChannel()
77 u32NearestUnitTimeNsec = (1000000UL * u32Prescale) / u32PWMClockSrc; in BPWM_ConfigCaptureChannel()
80 if (u32Prescale == 0x1000U) /* limit to the maximum unit time(nano second) */ in BPWM_ConfigCaptureChannel()
88 if (!(1000000UL * (u32Prescale + 1UL) > (u32NearestUnitTimeNsec * u32PWMClockSrc))) in BPWM_ConfigCaptureChannel()
109 u32Prescale -= 1U; in BPWM_ConfigCaptureChannel()
110 BPWM_SET_PRESCALER(bpwm, u32ChannelNum, u32Prescale); in BPWM_ConfigCaptureChannel()
139 uint32_t u32Prescale = 1U, u32CNR = 0xFFFFU; in BPWM_ConfigOutputChannel() local
169 for(u32Prescale = 1U; u32Prescale < 0xFFFU; u32Prescale++) /* prescale could be 0~0xFFF */ in BPWM_ConfigOutputChannel()
171 i = (u32PWMClockSrc / u32Frequency) / u32Prescale; in BPWM_ConfigOutputChannel()
[all …]
Depwm.c136 uint32_t u32Prescale = 1U, u32CNR = 0xFFFFU; in EPWM_ConfigOutputChannel() local
166 for(u32Prescale = 1U; u32Prescale < 0xFFFU; u32Prescale++) /* prescale could be 0~0xFFF */ in EPWM_ConfigOutputChannel()
168 i = (u32EPWMClockSrc / u32Frequency) / u32Prescale; in EPWM_ConfigOutputChannel()
177 i = u32EPWMClockSrc / (u32Prescale * u32CNR); in EPWM_ConfigOutputChannel()
180 u32Prescale -= 1U; in EPWM_ConfigOutputChannel()
181 EPWM_SET_PRESCALER(epwm, (u32ChannelNum), u32Prescale); in EPWM_ConfigOutputChannel()
324 int32_t EPWM_EnableADCTriggerPrescale(EPWM_T *epwm, uint32_t u32ChannelNum, uint32_t u32Prescale, u… in EPWM_EnableADCTriggerPrescale() argument
333 (u32Prescale << (u32ChannelNum << 3)); in EPWM_EnableADCTriggerPrescale()
340 (u32Prescale << ((u32ChannelNum - 4UL) << 3)); in EPWM_EnableADCTriggerPrescale()
/hal_nuvoton-latest/m46x/StdDriver/inc/
Depwm.h561 int32_t EPWM_EnableADCTriggerPrescale(EPWM_T *epwm, uint32_t u32ChannelNum, uint32_t u32Prescale, u…
/hal_nuvoton-latest/m2l31x/StdDriver/inc/
Depwm.h553 int32_t EPWM_EnableADCTriggerPrescale(EPWM_T *epwm, uint32_t u32ChannelNum, uint32_t u32Prescale, u…