Microchip MCP230S17 GPIO (SPI)
Summary
SPI-controlled GPIO expander with 16 channels organized in two banks (A and B), configurable as inputs or outputs with optional pull-up resistors.
Description
The **MCP230S17** component provides 16 GPIO channels accessible over SPI, split into bank A and bank B. Each channel can be individually configured as a digital input or output, with optional pull-up resistors. This component is useful for expanding the number of digital I/O pins on a microcontroller and controlling LEDs, buttons, or other digital devices.
Diagram:
Categories
- File:TArduinoSPICategory.png Category SPI – Components controlled via SPI bus.
- File:TArduinoDigitalCategory.png Category Digital – Components handling digital logic signals.
Properties
- SPISpeed – SPI communication speed in Hz (default 8,000,000).
Channel Properties
Each channel (A[0]–A[7] and B[0]–B[7]) has the following properties:
- Auto Config – Automatically configure channel at startup.
- Initial Value – Default digital value (boolean).
- Is Output – Configure the channel as digital output (otherwise input).
- Is Pull Up – Enable internal pull-up resistor for the channel.
Pins
Channel | Digital Input | Digital Output |
---|---|---|
A[0] | In (Digital) | Out |
A[1] | In (Digital) | Out |
A[2] | In (Digital) | Out |
A[3] | In (Digital) | Out |
A[4] | In (Digital) | Out |
A[5] | In (Digital) | Out |
A[6] | In (Digital) | Out |
A[7] | In (Digital) | Out |
B[0] | In (Digital) | Out |
B[1] | In (Digital) | Out |
B[2] | In (Digital) | Out |
B[3] | In (Digital) | Out |
B[4] | In (Digital) | Out |
B[5] | In (Digital) | Out |
B[6] | In (Digital) | Out |
B[7] | In (Digital) | Out |
SPI Pins
- Out (SPI) – SPI communication pin.
- Chip Select (digital) – SPI chip select pin for selecting the MCP230S17 device.