Home
last modified time | relevance | path

Searched refs:slice_idx (Results 1 – 3 of 3) sorted by relevance

/Zephyr-latest/drivers/pwm/
Dpwm_rpi_pico.c158 size_t slice_idx; in pwm_rpi_init() local
177 for (slice_idx = 0; slice_idx < NUM_PWM_SLICES; slice_idx++) { in pwm_rpi_init()
181 pwm_init(slice_idx, &slice_cfg, false); in pwm_rpi_init()
183 if (cfg->slice_configs[slice_idx].integral == 0) { in pwm_rpi_init()
184 pwm_set_clkdiv_int_frac(slice_idx, 1, 0); in pwm_rpi_init()
186 pwm_set_clkdiv_int_frac(slice_idx, in pwm_rpi_init()
187 cfg->slice_configs[slice_idx].integral, in pwm_rpi_init()
188 cfg->slice_configs[slice_idx].frac); in pwm_rpi_init()
190 pwm_set_enabled(slice_idx, true); in pwm_rpi_init()
Dpwm_xmc4xxx_ccu4.c57 int slice_idx = channel; in pwm_xmc4xxx_ccu4_set_cycles() local
67 slice = (XMC_CCU4_SLICE_t *)SLICE_ADDR_FROM_MODULE(config->ccu4, slice_idx); in pwm_xmc4xxx_ccu4_set_cycles()
72 XMC_CCU4_EnableShadowTransfer(config->ccu4, BIT(slice_idx * 4)); in pwm_xmc4xxx_ccu4_set_cycles()
75 XMC_CCU4_EnableClock(config->ccu4, slice_idx); in pwm_xmc4xxx_ccu4_set_cycles()
85 int slice_idx = channel; in pwm_xmc4xxx_ccu4_get_cycles_per_sec() local
91 *cycles = XMC_SCU_CLOCK_GetCcuClockFrequency() >> config->slice_prescaler[slice_idx]; in pwm_xmc4xxx_ccu4_get_cycles_per_sec()
Dpwm_xmc4xxx_ccu8.c95 int slice_idx = channel / 2; in pwm_xmc4xxx_ccu8_set_cycles() local
105 slice = (XMC_CCU8_SLICE_t *)SLICE_ADDR_FROM_MODULE(config->ccu8, slice_idx); in pwm_xmc4xxx_ccu8_set_cycles()
116 cycles = XMC_SCU_CLOCK_GetCcuClockFrequency() >> config->slice_prescaler[slice_idx]; in pwm_xmc4xxx_ccu8_set_cycles()
117 cycles >>= config->slice_deadtime_prescaler[slice_idx]; in pwm_xmc4xxx_ccu8_set_cycles()
128 XMC_CCU8_EnableShadowTransfer(config->ccu8, BIT(slice_idx * 4)); in pwm_xmc4xxx_ccu8_set_cycles()
131 XMC_CCU8_EnableClock(config->ccu8, slice_idx); in pwm_xmc4xxx_ccu8_set_cycles()