aboutsummaryrefslogtreecommitdiff
path: root/embassy-sync/src
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2022-11-23 12:17:02 +0000
committerGitHub <[email protected]>2022-11-23 12:17:02 +0000
commitb76631bebe980a8a04db0f07f0c3efb7edaccf2e (patch)
treede3c8dfe450a02df55e98d5ef6d3463d9d6a1963 /embassy-sync/src
parent2fa2c1a6fe9c79f11f7382a63ba6a13fe1bae1be (diff)
parenteae67d0be888d12e71bc3340279bab85666c05ae (diff)
Merge #1069
1069: GPIOTE InputChannel with mutable reference. r=Dirbaio a=Ardelean-Calin Adding these changes enables us to define a channel using a mutable reference to `GPIOTE_CH(n)`, similar to how we can do with other drivers. So instead of using: ```rust let p = embassy_nrf::init(config); let freq_in = InputChannel::new( p.GPIOTE_CH0, Input::new(&mut p.P0_19, embassy_nrf::gpio::Pull::Up), embassy_nrf::gpiote::InputChannelPolarity::HiToLo, ); ``` we can use: ```rust let p = embassy_nrf::init(config); let freq_in = InputChannel::new( &mut p.GPIOTE_CH0, Input::new(&mut p.P0_19, embassy_nrf::gpio::Pull::Up), embassy_nrf::gpiote::InputChannelPolarity::HiToLo, ); ``` therefore not giving ownership to GPIOTE_CH0. Co-authored-by: Ardelean Călin Petru <[email protected]> Co-authored-by: Ardelean Calin <[email protected]>
Diffstat (limited to 'embassy-sync/src')
0 files changed, 0 insertions, 0 deletions