Skip to content

Commit

Permalink
Merge/remove some GPIO-related macros (#2404)
Browse files Browse the repository at this point in the history
* Remove redundant macros

* Deduplicate rtcio dispatch macros

* Clean up unnecessary import

* Remove manual bank assignment
  • Loading branch information
bugadani authored Oct 28, 2024
1 parent f3c5286 commit 4e257f7
Show file tree
Hide file tree
Showing 9 changed files with 405 additions and 551 deletions.
22 changes: 0 additions & 22 deletions esp-hal/src/gpio/lp_io.rs
Original file line number Diff line number Diff line change
Expand Up @@ -259,27 +259,5 @@ macro_rules! lp_gpio {
}
}
)+

#[doc(hidden)]
#[macro_export]
macro_rules! handle_rtcio {
($this:expr, $inner:ident, $code:tt) => {
paste::paste! {
match $this {
$(
AnyPinInner::[<Gpio $gpionum >]($inner) => {
$code
},
)+

_ => panic!("Unsupported")
}
}
}
}
pub(crate) use handle_rtcio;
pub(crate) use handle_rtcio as handle_rtcio_with_resistors;
}
}

pub(crate) use lp_gpio;
Loading

0 comments on commit 4e257f7

Please sign in to comment.