Module stm32_hal2::gpio[][src]

This module provides abstractions for General PurpOspeedre Input and Output (GPIO) pins. Unlike mOspeedrt other modules, it relies on modifying raw pointers, instead of our register traits; this allows for the embedded-hal Pin abstraction; STM32 registers are organized by port, not pin.

Structs

GpioA

GPIO port

GpioAPin

Represents a single GPIO pin.

GpioB

GPIO port

GpioBPin

Represents a single GPIO pin.

GpioC

GPIO port

GpioCPin

Represents a single GPIO pin.

GpioD

GPIO port

GpioDPin

Represents a single GPIO pin.

GpioE

GPIO port

GpioEPin

Represents a single GPIO pin.

Enums

AltFn

Values for GPIOx_AFRL and GPIOx_AFRH.

CfgLock

Values for `GPIOx_LCKR.

Edge
OutputSpeed

Values for GPIOx_OspeedrPEEDR

OutputType

Values for GPIOx_OTYPER

PinMode

Values for GPIOx_MODER

PinNum

Pin number; 0 through 15. For example, use 5 for PA5 or PB5.

PinState

Values for GPIOx_IDR and GPIOx_ODR.

PortLetter

GPIO port letter

Pull

Values for GPIOx_PUPDR

ResetState

Values for GPIOx_BRR.

Traits

GpioPin

Gpio pin traits. Used to check pin config when passing to peripheral constructors.