Skip to content

Implementation requires PwmPin<Duty=u16> but any Duty value would work #8

Closed
@jasta

Description

@jasta

We can generalize further by only changing a few lines of code I believe:

let max_duty = self.pwm.get_max_duty();
let duty_f = (f64::from(speed) / 100.0) * f64::from(max_duty);
let duty = duty_f.round() as PWM::Duty;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions