rp/pio: remove PioPeripheral

merge into PioInstance instead. PioPeripheral was mostly a wrapper
around PioInstance anyway, and the way the wrapping was done required
PioInstanceBase<N> types where PIO{N} could've been used instead.
This commit is contained in:
pennae
2023-04-26 00:23:18 +02:00
parent 6cec6fa09b
commit 3229b5e809
5 changed files with 33 additions and 58 deletions

View File

@ -9,8 +9,7 @@ use embassy_rp::dma::{AnyChannel, Channel};
use embassy_rp::gpio::Pin;
use embassy_rp::peripherals::PIO0;
use embassy_rp::pio::{
FifoJoin, PioCommon, PioInstanceBase, PioPeripheral, PioStateMachine, PioStateMachineInstance, ShiftDirection,
SmInstanceBase,
FifoJoin, PioCommon, PioInstance, PioStateMachine, PioStateMachineInstance, ShiftDirection, SmInstanceBase,
};
use embassy_rp::pwm::{Config, Pwm};
use embassy_rp::relocate::RelocatedProgram;
@ -68,7 +67,7 @@ async fn main(_spawner: Spawner) {
pub struct HD44780<'l> {
dma: PeripheralRef<'l, AnyChannel>,
sm: PioStateMachineInstance<PioInstanceBase<0>, SmInstanceBase<0>>,
sm: PioStateMachineInstance<PIO0, SmInstanceBase<0>>,
buf: [u8; 40],
}