aboutsummaryrefslogtreecommitdiff
path: root/embassy-mcxa/examples/src/lib.rs
diff options
context:
space:
mode:
authorJames Munns <[email protected]>2025-12-04 18:37:01 +0100
committerJames Munns <[email protected]>2025-12-04 18:43:11 +0100
commitdc6bf5d44675f6f2013ddfab6b14df25a996a965 (patch)
treeab593af8f4b2be502a809833f80e4f3b741b8fad /embassy-mcxa/examples/src/lib.rs
parent22bae2d80153003af4637c4b0cc26d52858f5228 (diff)
Move to subfolder
Diffstat (limited to 'embassy-mcxa/examples/src/lib.rs')
-rw-r--r--embassy-mcxa/examples/src/lib.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/embassy-mcxa/examples/src/lib.rs b/embassy-mcxa/examples/src/lib.rs
new file mode 100644
index 000000000..2573a6adc
--- /dev/null
+++ b/embassy-mcxa/examples/src/lib.rs
@@ -0,0 +1,16 @@
1#![no_std]
2#![allow(clippy::missing_safety_doc)]
3
4//! Shared board-specific helpers for the FRDM-MCXA276 examples.
5//! These live with the examples so the HAL stays generic.
6
7use hal::{clocks, pins};
8use {defmt_rtt as _, embassy_mcxa as hal, panic_probe as _};
9
10/// Initialize clocks and pin muxing for ADC.
11pub unsafe fn init_adc_pins() {
12 // NOTE: Lpuart has been updated to properly enable + reset its own clocks.
13 // GPIO has not.
14 _ = clocks::enable_and_reset::<hal::peripherals::PORT1>(&clocks::periph_helpers::NoConfig);
15 pins::configure_adc_pins();
16}