imxrt-rs / imxrt-iomuxc

Pin definitions, configurations, and multiplexing API
Apache License 2.0
1 stars 13 forks source link

Favor optional daisy registers in Pin traits #31

Closed mciantyre closed 1 year ago

mciantyre commented 1 year ago

Although daisy registers may be required today, #30 shows that daisy registers may be optional tomorrow. Refactor traits and implementations to always use Option<Daisy> associated constants. This lets us extend chip support without incurring breaking changes.

After #30, it seems that only lpi2c::Pins needs this treatment.

Florob commented 1 year ago

Relatedly, flexpwm::Pin doesn't have any daisy register specified. However, everything except the RT 101x seems to need one.

mciantyre commented 1 year ago

Thanks for noting the missing PWM daisies. That might've been annoying to find when exploring FlexPWM inputs.