rp/pio: drop SmInstance{,Base}
these are just overly convoluted ways of writing down numbers.
This commit is contained in:
@ -6,18 +6,18 @@ use defmt::*;
|
||||
use embassy_executor::Spawner;
|
||||
use embassy_rp::gpio::{self, Pin};
|
||||
use embassy_rp::pio::{
|
||||
FifoJoin, Pio, PioCommon, PioInstance, PioStateMachine, PioStateMachineInstance, ShiftDirection, SmInstance,
|
||||
FifoJoin, Pio, PioCommon, PioInstance, PioStateMachine, PioStateMachineInstance, ShiftDirection,
|
||||
};
|
||||
use embassy_rp::pio_instr_util;
|
||||
use embassy_rp::relocate::RelocatedProgram;
|
||||
use embassy_time::{Duration, Timer};
|
||||
use smart_leds::RGB8;
|
||||
use {defmt_rtt as _, panic_probe as _};
|
||||
pub struct Ws2812<'d, P: PioInstance, S: SmInstance> {
|
||||
pub struct Ws2812<'d, P: PioInstance, const S: usize> {
|
||||
sm: PioStateMachineInstance<'d, P, S>,
|
||||
}
|
||||
|
||||
impl<'d, P: PioInstance, S: SmInstance> Ws2812<'d, P, S> {
|
||||
impl<'d, P: PioInstance, const S: usize> Ws2812<'d, P, S> {
|
||||
pub fn new(mut pio: PioCommon<'d, P>, mut sm: PioStateMachineInstance<'d, P, S>, pin: gpio::AnyPin) -> Self {
|
||||
// Setup sm0
|
||||
|
||||
|
Reference in New Issue
Block a user