From e31545860e2c44e67f45dd5132e85f18b6fab5d7 Mon Sep 17 00:00:00 2001 From: Don Reilly Date: Tue, 8 Aug 2023 16:46:30 -0500 Subject: [PATCH] don't generate adc peripheral for f3 series --- embassy-stm32/build.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/embassy-stm32/build.rs b/embassy-stm32/build.rs index 30e25aef..743631b8 100644 --- a/embassy-stm32/build.rs +++ b/embassy-stm32/build.rs @@ -310,7 +310,10 @@ fn main() { for p in METADATA.peripherals { // generating RccPeripheral impl for H7 ADC3 would result in bad frequency - if !singletons.contains(&p.name.to_string()) || (p.name == "ADC3" && METADATA.line.starts_with("STM32H7")) { + if !singletons.contains(&p.name.to_string()) + || (p.name == "ADC3" && METADATA.line.starts_with("STM32H7")) + || (p.name.starts_with("ADC") && p.registers.as_ref().map_or(false, |r| r.version == "f3")) + { continue; }