This is an old revision of the document!


Alternate Functions (GPIO)

  • The output buffer can be enabled (open drain or push-pull).
  • The output buffer is controlled by connected peripheral.
  • The Schmitt trigger input is active.
  • The pull-up and -down resistors are active, according to PUPDR.
  • Input data is sampled every AHB clock.
  • Input data register holds I/O state.




Mode register




Pinx01Output mode (reset state)

Alternate function register (low / high)







Pin x0000AF0: RTC, MCO, Tamper, SWJ, Trace
0001Timer 1, Timer 2
0010Timer 3..5
0011Timer 8..11
0100I²C 1..3
0101SPI 1,2,4..6
0110SPI 3, SAI 1
0111USART 1..3, I²S 3 Ext
1000UART 4..8
1001CAN 1..2, Timer 12..14
1010USB OTG HS/FS
1011Ethernet
1100FMC, USB OTG HS/FS, SDIO
1101DCMI
1110LTDC
1111Event Out

Push-up / pull-down register




Pin x00No pull-up, pull-down (reset state)
01Pull-up
10Pull-down
11Reserved

Output type register




Pin x0Output type: push-pull (reset state)
1Output type: open-drain

Output speed register




Pin x00Speed: 2 MHz (reset state)
01Speed: 10 MHz
10Speed: 50 MHz
11Speed: 100 MHz

There are no data registers available in alternate function mode.




  • stm32/peripherals/gpio_alternate.1456390079.txt.gz
  • Last modified: 2016/02/25 08:47
  • by feur