gpio peripherals


Are GPIO peripherals in a mcu? How come they have a separate clock signal that you can enable/disable?


Because in most modern semiconductor technologies, any clocked logic will consume less power if you turn off its clock. GPIO ports need to involve some clocks in order to synchronize external pin states with the internal logic, and frequently have other more complex functions that also need clocks (for example, the GPIO ports on the Arduino Due can support debouncing logic.)

The AVR mcus used on the most popular Arduinos do not have enable/disable logic on their GPIO ports clocks.

Many thanks