pub struct OutputSignal { /* private fields */ }
unstable
only.Expand description
A configurable output signal between a peripheral and a GPIO pin.
Multiple pins can be connected to one output signal.
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Implementations§
Source§impl OutputSignal
impl OutputSignal
Sourcepub fn invert(&mut self)
pub fn invert(&mut self)
Inverts the peripheral’s output signal.
Calling this function multiple times toggles the setting.
Sourcepub fn inverted(self) -> Self
pub fn inverted(self) -> Self
Consumes the signal and returns a new one that inverts the peripheral’s output signal.
Calling this function multiple times toggles the setting.
Sourcepub fn pull_direction(&self, pull: Pull)
pub fn pull_direction(&self, pull: Pull)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn input_signals(
&self,
_internal: Internal,
) -> &'static [(AlternateFunction, InputSignal)]
pub fn input_signals( &self, _internal: Internal, ) -> &'static [(AlternateFunction, InputSignal)]
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn init_input(&self, pull: Pull)
pub fn init_input(&self, pull: Pull)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn is_input_high(&self) -> bool
pub fn is_input_high(&self) -> bool
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn enable_input(&self, on: bool)
pub fn enable_input(&self, on: bool)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn output_signals(
&self,
_internal: Internal,
) -> &'static [(AlternateFunction, OutputSignal)]
pub fn output_signals( &self, _internal: Internal, ) -> &'static [(AlternateFunction, OutputSignal)]
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn set_to_open_drain_output(&self)
pub fn set_to_open_drain_output(&self)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn set_to_push_pull_output(&self)
pub fn set_to_push_pull_output(&self)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn enable_output(&self, on: bool)
pub fn enable_output(&self, on: bool)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn set_output_high(&self, on: bool)
pub fn set_output_high(&self, on: bool)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn set_drive_strength(&self, strength: DriveStrength)
pub fn set_drive_strength(&self, strength: DriveStrength)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn enable_open_drain(&self, on: bool)
pub fn enable_open_drain(&self, on: bool)
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Sourcepub fn is_set_high(&self) -> bool
pub fn is_set_high(&self) -> bool
§Stability
This API is marked as unstable and is only available when the unstable
crate feature is enabled. This comes with no stability guarantees, and could be changed
or removed at any time.
Trait Implementations§
Source§impl From<Flex<'static>> for OutputSignal
impl From<Flex<'static>> for OutputSignal
Source§impl From<OutputSignal> for InputConnection
impl From<OutputSignal> for InputConnection
Source§fn from(output_signal: OutputSignal) -> Self
fn from(output_signal: OutputSignal) -> Self
Source§impl From<OutputSignal> for OutputConnection
impl From<OutputSignal> for OutputConnection
Source§fn from(signal: OutputSignal) -> Self
fn from(signal: OutputSignal) -> Self
Source§impl<P> From<P> for OutputSignalwhere
P: OutputPin,
impl<P> From<P> for OutputSignalwhere
P: OutputPin,
Source§impl Peripheral for OutputSignal
impl Peripheral for OutputSignal
Source§type P = OutputSignal
type P = OutputSignal
Source§unsafe fn clone_unchecked(&self) -> Self::P
unsafe fn clone_unchecked(&self) -> Self::P
Source§fn into_ref<'a>(self) -> PeripheralRef<'a, Self::P>where
Self: 'a,
fn into_ref<'a>(self) -> PeripheralRef<'a, Self::P>where
Self: 'a,
PeripheralRef
. Read more