/ˌdʒiːˌpiːˌoʊ/

noun — "programmable pins for general hardware control."

GPIO, short for General-Purpose Input/Output, is a type of digital signal pin found on microcontrollers, embedded systems, and some CPUs that can be configured by software to act either as an input or an output. These pins provide a flexible interface for interacting with sensors, switches, LEDs, and other hardware components without dedicated communication protocols. GPIO pins are widely used in prototyping, embedded applications, and low-level hardware control where simple digital signaling is sufficient.

Technically, a GPIO pin can be set to an output mode, where it drives a voltage high or low to control external devices, or to input mode, where it reads the voltage state presented by a sensor or switch. The direction, pull-up/pull-down resistors, and drive strength are typically configurable via registers in the microcontroller or through an operating system interface.

Example in a Linux embedded system controlling an LED:


# export GPIO pin 17
echo 17 > /sys/class/gpio/export
# set pin as output
echo out > /sys/class/gpio/gpio17/direction
# turn LED on
echo 1 > /sys/class/gpio/gpio17/value
# turn LED off
echo 0 > /sys/class/gpio/gpio17/value

Operationally, GPIO allows programs to monitor and control hardware at a very low level. As inputs, pins can detect digital signals from switches, motion sensors, or communication status lines. As outputs, they can drive LEDs, relays, or trigger external circuits. Because GPIO is generally unbuffered and non-protocol-specific, timing and electrical characteristics must be managed carefully to avoid damage or incorrect readings.

In embedded systems, GPIO is often multiplexed with other functions such as UART, SPI, I²C, PWM, or analog-to-digital conversion. Configuration determines whether the pin operates in general-purpose mode or as part of a specialized peripheral interface.

Conceptually, GPIO pins are like programmable switches or signals on a circuit board. Software can turn them on or off or read their state, giving a direct but controlled connection between the digital world of the processor and the physical world of electronics.

See Microcontroller, Embedded Systems, SPI, I²C, PWM.