关于 gpio port

来源:互联网 发布:js format 函数 编辑:程序博客网 时间:2024/06/06 13:58

本文转载至:http://leaflabs.com/docs/gpio.html

Normally, you’ll interact with pins using just their number (or aconstant likeBOARD_LED_PIN whichstands for a number). However, behind the scenes, the STM32 microcontroller on your board separatesthe pins into groups called GPIO ports. Each GPIO port is given a letter, so for example,there’s GPIO port A, port B, and so on[1].The pins on a GPIO port are given bit numbers, which go from 0 to 15. In ST’sdocumentation, a pin is given by the letter “P”, followed by its portletter and bit number. For instance, “PA4” is GPIO port A, bit 4.


一个GPIO端口对应的一组引脚。引脚被赋予位值。

1 0