You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to propose a waveform generation trait. This would be useful for efficient bitbanging, PWM, etc.
I will begin with simple sketch and we will see where it will lead.
pubstructMicroseconds(/*What should go here? Maybe `pub u32` is fine?*/);pubenumPinState{High,Low,}pubtraitWaveGen{fngenerate<I:Clone + IntoIterator<Item=Microseconds>>(&mutself,pin:Pin,initial_state:PinState,delays:I,repeat_count:u32);}
The implementor should set the pin into state defined by initial_state, then wait for duration specified by item from delays and toggle the pin after each item.
I'd love to implement some drivers for wireless sockets I have.
The text was updated successfully, but these errors were encountered:
I'd like to propose a waveform generation trait. This would be useful for efficient bitbanging, PWM, etc.
I will begin with simple sketch and we will see where it will lead.
The implementor should set the
pin
into state defined byinitial_state
, then wait for duration specified by item fromdelays
and toggle the pin after each item.I'd love to implement some drivers for wireless sockets I have.
The text was updated successfully, but these errors were encountered: