Struct alt_stm32f30x_hal::gpio::PB4
source · [−]Expand description
Pin
Implementations
sourceimpl<PT: PullType, PM: PinMode> PB4<PT, PM>
impl<PT: PullType, PM: PinMode> PB4<PT, PM>
sourcepub fn downgrade(self) -> PBx<PT, PM>
pub fn downgrade(self) -> PBx<PT, PM>
Erases the pin number from the type
This is useful when you want to collect the pins into an array where you need all the elements to have the same type
sourceimpl<PT: PullType, OT: OutputType, OS: OutputSpeed> PB4<PT, Output<OT, OS>>
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> PB4<PT, Output<OT, OS>>
sourcepub fn output_type<NOT: OutputType>(self, ot: NOT) -> PB4<PT, Output<NOT, OS>>
pub fn output_type<NOT: OutputType>(self, ot: NOT) -> PB4<PT, Output<NOT, OS>>
Set output type
sourcepub fn open_drain(self) -> PB4<PT, Output<OpenDrain, OS>>
pub fn open_drain(self) -> PB4<PT, Output<OpenDrain, OS>>
Set output type to OpenDrain
sourcepub fn output_speed<NOS: OutputSpeed>(self, os: NOS) -> PB4<PT, Output<OT, NOS>>
pub fn output_speed<NOS: OutputSpeed>(self, os: NOS) -> PB4<PT, Output<OT, NOS>>
Set output speed
sourceimpl<PT: PullType, AFN: AltFnNum, OT: OutputType, OS: OutputSpeed> PB4<PT, AltFn<AFN, OT, OS>>
impl<PT: PullType, AFN: AltFnNum, OT: OutputType, OS: OutputSpeed> PB4<PT, AltFn<AFN, OT, OS>>
sourcepub fn output_type<NOT: OutputType>(
self,
ot: NOT
) -> PB4<PT, AltFn<AFN, NOT, OS>>
pub fn output_type<NOT: OutputType>(
self,
ot: NOT
) -> PB4<PT, AltFn<AFN, NOT, OS>>
Set output type
sourcepub fn output_speed<NOS: OutputSpeed>(
self,
os: NOS
) -> PB4<PT, AltFn<AFN, OT, NOS>>
pub fn output_speed<NOS: OutputSpeed>(
self,
os: NOS
) -> PB4<PT, AltFn<AFN, OT, NOS>>
Set output speed
Trait Implementations
sourceimpl<PT: PullType> InputPin for PB4<PT, Input>
impl<PT: PullType> InputPin for PB4<PT, Input>
sourceimpl<PT: PullType, OT: OutputType, OS: OutputSpeed> OutputPin for PB4<PT, Output<OT, OS>>
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> OutputPin for PB4<PT, Output<OT, OS>>
sourceimpl<PT: PullType, AN: AltFnNum, OT: OutputType, OS: OutputSpeed> OutputPin for PB4<PT, AltFn<AN, OT, OS>>
impl<PT: PullType, AN: AltFnNum, OT: OutputType, OS: OutputSpeed> OutputPin for PB4<PT, AltFn<AN, OT, OS>>
sourceimpl<PT: PullType, PM: PinMode> SerialExt<USART2, PA14<PT, PM>, PB4<PT, PM>, PA14<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
impl<PT: PullType, PM: PinMode> SerialExt<USART2, PA14<PT, PM>, PB4<PT, PM>, PA14<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
sourceimpl<PT: PullType, PM: PinMode> SerialExt<USART2, PA2<PT, PM>, PB4<PT, PM>, PA2<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
impl<PT: PullType, PM: PinMode> SerialExt<USART2, PA2<PT, PM>, PB4<PT, PM>, PA2<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
sourceimpl<PT: PullType, PM: PinMode> SerialExt<USART2, PB3<PT, PM>, PB4<PT, PM>, PB3<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
impl<PT: PullType, PM: PinMode> SerialExt<USART2, PB3<PT, PM>, PB4<PT, PM>, PB3<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
sourceimpl<PT: PullType, PM: PinMode> SerialExt<USART2, PD5<PT, PM>, PB4<PT, PM>, PD5<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
impl<PT: PullType, PM: PinMode> SerialExt<USART2, PD5<PT, PM>, PB4<PT, PM>, PD5<PT, AltFn<AF7, PushPull, HighSpeed>>, PB4<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART2
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI1, PA5<PT, PM>, PB4<PT, PM>, PA7<PT, PM>, PA5<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PA7<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
impl<PT: PullType, PM: PinMode> SpiExt<SPI1, PA5<PT, PM>, PB4<PT, PM>, PA7<PT, PM>, PA5<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PA7<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI1, PA5<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PA5<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PB5<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
impl<PT: PullType, PM: PinMode> SpiExt<SPI1, PA5<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PA5<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PB5<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI1, PB3<PT, PM>, PB4<PT, PM>, PA7<PT, PM>, PB3<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PA7<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
impl<PT: PullType, PM: PinMode> SpiExt<SPI1, PB3<PT, PM>, PB4<PT, PM>, PA7<PT, PM>, PB3<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PA7<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI1, PB3<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PB3<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PB5<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
impl<PT: PullType, PM: PinMode> SpiExt<SPI1, PB3<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PB3<PT, AltFn<AF5, PushPull, HighSpeed>>, PB4<PT, AltFn<AF5, PushPull, HighSpeed>>, PB5<PT, AltFn<AF5, PushPull, HighSpeed>>> for SPI1
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI3, PB3<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PB3<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PB5<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
impl<PT: PullType, PM: PinMode> SpiExt<SPI3, PB3<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PB3<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PB5<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI3, PB3<PT, PM>, PB4<PT, PM>, PC12<PT, PM>, PB3<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PC12<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
impl<PT: PullType, PM: PinMode> SpiExt<SPI3, PB3<PT, PM>, PB4<PT, PM>, PC12<PT, PM>, PB3<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PC12<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI3, PC10<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PC10<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PB5<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
impl<PT: PullType, PM: PinMode> SpiExt<SPI3, PC10<PT, PM>, PB4<PT, PM>, PB5<PT, PM>, PC10<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PB5<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
sourceimpl<PT: PullType, PM: PinMode> SpiExt<SPI3, PC10<PT, PM>, PB4<PT, PM>, PC12<PT, PM>, PC10<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PC12<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
impl<PT: PullType, PM: PinMode> SpiExt<SPI3, PC10<PT, PM>, PB4<PT, PM>, PC12<PT, PM>, PC10<PT, AltFn<AF6, PushPull, HighSpeed>>, PB4<PT, AltFn<AF6, PushPull, HighSpeed>>, PC12<PT, AltFn<AF6, PushPull, HighSpeed>>> for SPI3
sourceimpl<PT: PullType, OT: OutputType, OS: OutputSpeed> StatefulOutputPin for PB4<PT, Output<OT, OS>>
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> StatefulOutputPin for PB4<PT, Output<OT, OS>>
sourcefn is_set_high(&self) -> bool
fn is_set_high(&self) -> bool
👎 Deprecated since 0.2.2:
Deprecated because the methods cannot return errors. Users should use the traits in digital::v2.
Is the pin in drive high mode? Read more
sourcefn is_set_low(&self) -> bool
fn is_set_low(&self) -> bool
👎 Deprecated since 0.2.2:
Deprecated because the methods cannot return errors. Users should use the traits in digital::v2.
Is the pin in drive low mode? Read more
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> Default for PB4<PT, Output<OT, OS>>
Auto Trait Implementations
impl<PT, PM> RefUnwindSafe for PB4<PT, PM> where
PM: RefUnwindSafe,
PT: RefUnwindSafe,
impl<PT, PM> Send for PB4<PT, PM> where
PM: Send,
PT: Send,
impl<PT, PM> Sync for PB4<PT, PM> where
PM: Sync,
PT: Sync,
impl<PT, PM> Unpin for PB4<PT, PM> where
PM: Unpin,
PT: Unpin,
impl<PT, PM> UnwindSafe for PB4<PT, PM> where
PM: UnwindSafe,
PT: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more