Fix internal channel reading on adc_v2

This commit is contained in:
chemicstry
2022-10-07 14:31:55 +03:00
parent 9dca368c3d
commit df7174ecb0
4 changed files with 130 additions and 57 deletions

View File

@@ -50,14 +50,6 @@ impl Resolution {
}
}
pub trait InternalChannel<T>: sealed::InternalChannel<T> {}
mod sealed {
pub trait InternalChannel<T> {
fn channel(&self) -> u8;
}
}
// NOTE: Vrefint/Temperature/Vbat are only available on ADC3 on H7, this currently cannot be modeled with stm32-data, so these are available from the software on all ADCs
pub struct VrefInt;
impl<T: Instance> InternalChannel<T> for VrefInt {}