Arduino I/O Expander

In this post, a GPIO expansion circuit for arduino pro mini with integrated power regulator is presented.

The circuit is designed to provide 32 input and 32 output extra pins but can be easily modified to provide an arbitrary number as it uses cascaded shift registers for both inputs and outputs.

The integrated 5V voltage regulator (D2PAK package) powers the whole circuit (that includes the arduino) and its input is conveniently exposed via a screw terminal located on the edge of the PCB.

Arduino IO expander schematic diagram

Inputs

Four 74HC165 8-bit parallel-in serial-out shift registers are daisy chained to provide the inputs while using only three pins of arduino(D9,D12,D13). Arduino provides hardware support for SPI protocol on these pins. All the 32 input pins are pulled-up to 5V with 10KΩ resistors. If no pull-up function is required, resistor networks rn0-rn7 can be omitted.

Outputs

The circuit was designed to be able to directly drive medium loads, hence, the power shift register IC TPIC6B595/TPIC6B596 (they are interchangeable) from Texas Instruments was adopted. This IC has a relatively high current sink capacity (outputs are DMOS transistors in open-drain configuration with Rds(on) of 5Ω) and can directly drive relays, solenoids, power leds etc. .The shift registers are cascaded and connected to arduino on pins D3(clock), D5(latch), D6(data). Their communication protocol is compatible with the 74HC595 IC so it is very easy to send them data with arduino’s shiftOut() built-in function.

3D representation of the fully populated PCB

eagle project files

Silo Emulator

a special purpose emulator circuit Continue reading

WoL++

Published on May 22, 2017

RPi Identification System

Published on April 16, 2017