Merge pull request #4205 from rursprung/add-some-missing-debug-and-format-impls-for-rpi-adc

rp: add missing `Debug` and `defmt::Format` `derive`s for ADC
This commit is contained in:
Dario Nieuwenhuis
2025-05-15 19:33:56 +02:00
committed by GitHub
5 changed files with 13 additions and 2 deletions

View File

@@ -21,6 +21,8 @@ static WAKER: AtomicWaker = AtomicWaker::new();
#[derive(Default)]
pub struct Config {}
#[derive(Debug)]
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
enum Source<'p> {
Pin(Peri<'p, AnyPin>),
TempSensor(Peri<'p, ADC_TEMP_SENSOR>),

View File

@@ -932,6 +932,8 @@ pub trait Pin: PeripheralType + Into<AnyPin> + SealedPin + Sized + 'static {
}
/// Type-erased GPIO pin
#[derive(Debug)]
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
pub struct AnyPin {
pin_bank: u8,
}