[−][src]Struct alt_stm32f30x_hal::gpio::PB6
Pin
Methods
impl<PT: PullType, PM: PinMode> PB6<PT, PM>
[src]
pub fn downgrade(self) -> PBx<PT, PM>
[src]
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
pub fn pull_type<NPT: PullType>(self, pt: NPT) -> PB6<NPT, PM>
[src]
Sets pull type: Floaing, PullUp, PullDown
pub fn input(self) -> PB6<PT, Input>
[src]
Sets io_mode to input
pub fn analog(self) -> PB6<PT, Analog>
[src]
Sets io_mode to analog
pub fn output(self) -> PB6<PT, Output<PushPull, LowSpeed>>
[src]
Set io_mode to output
pub fn alternating<AFN: AltFnNum>(
self,
af: AFN
) -> PB6<PT, AltFn<AFN, PushPull, LowSpeed>>
[src]
self,
af: AFN
) -> PB6<PT, AltFn<AFN, PushPull, LowSpeed>>
Set io_mode to altfn and set alternating function
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> PB6<PT, Output<OT, OS>>
[src]
pub fn output_type<NOT: OutputType>(self, ot: NOT) -> PB6<PT, Output<NOT, OS>>
[src]
Set output type
pub fn push_pull(self) -> PB6<PT, Output<PushPull, OS>>
[src]
Set output type to PushPull
pub fn open_drain(self) -> PB6<PT, Output<OpenDrain, OS>>
[src]
Set output type to OpenDrain
pub fn output_speed<NOS: OutputSpeed>(self, os: NOS) -> PB6<PT, Output<OT, NOS>>
[src]
Set output speed
impl<PT: PullType, AFN: AltFnNum, OT: OutputType, OS: OutputSpeed> PB6<PT, AltFn<AFN, OT, OS>>
[src]
pub fn output_type<NOT: OutputType>(
self,
ot: NOT
) -> PB6<PT, AltFn<AFN, NOT, OS>>
[src]
self,
ot: NOT
) -> PB6<PT, AltFn<AFN, NOT, OS>>
Set output type
pub fn output_speed<NOS: OutputSpeed>(
self,
os: NOS
) -> PB6<PT, AltFn<AFN, OT, NOS>>
[src]
self,
os: NOS
) -> PB6<PT, AltFn<AFN, OT, NOS>>
Set output speed
pub fn alt_fn<NAFN: AltFnNum>(self, af: NAFN) -> PB6<PT, AltFn<NAFN, OT, OS>>
[src]
Set altfn
Trait Implementations
impl<PT: PullType, PM: PinMode> GPIOPin for PB6<PT, PM>
[src]
impl<PT: PullType, PM: PinMode> I2cExt<I2C1, PB6<PT, PM>, PB7<PT, PM>, PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PB7<PT, AltFn<AF4, PushPull, HighSpeed>>> for I2C1
[src]
fn i2c<F>(
self,
pins: (PB6<PT, PM>, PB7<PT, PM>),
freq: F,
clocks: Clocks
) -> I2c<I2C1, (PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PB7<PT, AltFn<AF4, PushPull, HighSpeed>>)> where
F: Into<Hertz<u32>>,
[src]
self,
pins: (PB6<PT, PM>, PB7<PT, PM>),
freq: F,
clocks: Clocks
) -> I2c<I2C1, (PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PB7<PT, AltFn<AF4, PushPull, HighSpeed>>)> where
F: Into<Hertz<u32>>,
impl<PT: PullType, PM: PinMode> I2cExt<I2C1, PB6<PT, PM>, PB9<PT, PM>, PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PB9<PT, AltFn<AF4, PushPull, HighSpeed>>> for I2C1
[src]
fn i2c<F>(
self,
pins: (PB6<PT, PM>, PB9<PT, PM>),
freq: F,
clocks: Clocks
) -> I2c<I2C1, (PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PB9<PT, AltFn<AF4, PushPull, HighSpeed>>)> where
F: Into<Hertz<u32>>,
[src]
self,
pins: (PB6<PT, PM>, PB9<PT, PM>),
freq: F,
clocks: Clocks
) -> I2c<I2C1, (PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PB9<PT, AltFn<AF4, PushPull, HighSpeed>>)> where
F: Into<Hertz<u32>>,
impl<PT: PullType, PM: PinMode> I2cExt<I2C1, PB6<PT, PM>, PA14<PT, PM>, PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PA14<PT, AltFn<AF4, PushPull, HighSpeed>>> for I2C1
[src]
fn i2c<F>(
self,
pins: (PB6<PT, PM>, PA14<PT, PM>),
freq: F,
clocks: Clocks
) -> I2c<I2C1, (PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PA14<PT, AltFn<AF4, PushPull, HighSpeed>>)> where
F: Into<Hertz<u32>>,
[src]
self,
pins: (PB6<PT, PM>, PA14<PT, PM>),
freq: F,
clocks: Clocks
) -> I2c<I2C1, (PB6<PT, AltFn<AF4, PushPull, HighSpeed>>, PA14<PT, AltFn<AF4, PushPull, HighSpeed>>)> where
F: Into<Hertz<u32>>,
impl<SP: OutputSpeed, PT: PullType, PM: PinMode, CM: ChMode> PwmExt<SP, Channel<CH1, CM>, AF2> for PB6<PT, PM>
[src]
type OutputPin = PB6<PT, AltFn<AF2, PushPull, SP>>
type
type Output = PwmBinding<Self::OutputPin, Channel<CH1, Pwm1>>
binding
fn to_pwm(self, channel: Channel<CH1, CM>, sp: SP) -> Self::Output
[src]
impl<PT: PullType, PM: PinMode> SerialExt<USART1, PB6<PT, PM>, PA10<PT, PM>, PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PA10<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART1
[src]
fn serial(
self,
pins: (PB6<PT, PM>, PA10<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PA10<PT, AltFn<AF7, PushPull, HighSpeed>>)>
[src]
self,
pins: (PB6<PT, PM>, PA10<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PA10<PT, AltFn<AF7, PushPull, HighSpeed>>)>
impl<PT: PullType, PM: PinMode> SerialExt<USART1, PB6<PT, PM>, PB7<PT, PM>, PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PB7<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART1
[src]
fn serial(
self,
pins: (PB6<PT, PM>, PB7<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PB7<PT, AltFn<AF7, PushPull, HighSpeed>>)>
[src]
self,
pins: (PB6<PT, PM>, PB7<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PB7<PT, AltFn<AF7, PushPull, HighSpeed>>)>
impl<PT: PullType, PM: PinMode> SerialExt<USART1, PB6<PT, PM>, PC5<PT, PM>, PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PC5<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART1
[src]
fn serial(
self,
pins: (PB6<PT, PM>, PC5<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PC5<PT, AltFn<AF7, PushPull, HighSpeed>>)>
[src]
self,
pins: (PB6<PT, PM>, PC5<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PC5<PT, AltFn<AF7, PushPull, HighSpeed>>)>
impl<PT: PullType, PM: PinMode> SerialExt<USART1, PB6<PT, PM>, PE1<PT, PM>, PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PE1<PT, AltFn<AF7, PushPull, HighSpeed>>> for USART1
[src]
fn serial(
self,
pins: (PB6<PT, PM>, PE1<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PE1<PT, AltFn<AF7, PushPull, HighSpeed>>)>
[src]
self,
pins: (PB6<PT, PM>, PE1<PT, PM>),
baud_rate: Bps<u32>,
clocks: Clocks
) -> Serial<USART1, (PB6<PT, AltFn<AF7, PushPull, HighSpeed>>, PE1<PT, AltFn<AF7, PushPull, HighSpeed>>)>
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> OutputPin for PB6<PT, Output<OT, OS>>
[src]
impl<PT: PullType, AN: AltFnNum, OT: OutputType, OS: OutputSpeed> OutputPin for PB6<PT, AltFn<AN, OT, OS>>
[src]
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> StatefulOutputPin for PB6<PT, Output<OT, OS>>
[src]
fn is_set_high(&self) -> bool
[src]
fn is_set_low(&self) -> bool
[src]
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> Default for PB6<PT, Output<OT, OS>>
[src]
impl<PT: PullType> InputPin for PB6<PT, Input>
[src]
impl<PT: PullType, OT: OutputType, OS: OutputSpeed> Default for PB6<PT, Output<OT, OS>>
[src]
Auto Trait Implementations
impl<PT, PM> Unpin for PB6<PT, PM> where
PM: Unpin,
PT: Unpin,
PM: Unpin,
PT: Unpin,
impl<PT, PM> Send for PB6<PT, PM> where
PM: Send,
PT: Send,
PM: Send,
PT: Send,
impl<PT, PM> Sync for PB6<PT, PM> where
PM: Sync,
PT: Sync,
PM: Sync,
PT: Sync,
Blanket Implementations
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<P> ToggleableOutputPin for P where
P: Default,
P: Default,
fn toggle(&mut self)
Deprecated since 0.2.2:
Deprecated because the methods cannot return errors. Users should use the traits in digital::v2.
Toggle pin output
impl<T> OutputPin for T where
T: OutputPin,
T: OutputPin,
type Error = ()
Error type
fn set_low(&mut self) -> Result<(), <T as OutputPin>::Error>
fn set_high(&mut self) -> Result<(), <T as OutputPin>::Error>
impl<T> StatefulOutputPin for T where
T: StatefulOutputPin + OutputPin,
T: StatefulOutputPin + OutputPin,
fn is_set_low(&self) -> Result<bool, <T as OutputPin>::Error>
fn is_set_high(&self) -> Result<bool, <T as OutputPin>::Error>
impl<P> ToggleableOutputPin for P where
P: Default,
P: Default,
type Error = <P as OutputPin>::Error
Error type
fn toggle(&mut self) -> Result<(), <P as ToggleableOutputPin>::Error>
Toggle pin output
impl<T> InputPin for T where
T: InputPin,
T: InputPin,