Lines Matching defs:duty
55 * variable-duty-cycle PWM output.
166 u_int duty; /* on duration, in ns */
205 am335x_ehrpwm_cfg_duty(struct am335x_ehrpwm_softc *sc, u_int chan, u_int duty)
209 if (duty == 0)
212 tbcmp = max(1, duty / sc->sc_clktick);
214 sc->sc_channels[chan].duty = tbcmp * sc->sc_clktick;
306 * registers (duty values), just zero them out.
354 /* Reset the duty cycle settings. */
412 uint32_t duty;
415 duty = sc->sc_pwm_dutyA;
417 duty = sc->sc_pwm_dutyB;
418 error = sysctl_handle_int(oidp, &duty, 0, req);
423 if (duty > sc->sc_pwm_period) {
430 sc->sc_pwm_dutyA = duty;
434 sc->sc_pwm_dutyB = duty;
462 /* Reset the duty cycle settings. */
486 am335x_ehrpwm_channel_config(device_t dev, u_int channel, u_int period, u_int duty)
499 am335x_ehrpwm_cfg_duty(sc, channel, duty);
507 u_int *period, u_int *duty)
516 *duty = sc->sc_channels[channel].duty;
605 am335x_ehrpwm_sysctl_duty, "I", "Channel A duty cycles");
609 am335x_ehrpwm_sysctl_duty, "I", "Channel B duty cycles");