Table of Contents

Slice of Pi/O

rpipio.jpg

slipi.jpg

The Slice of Pi/O is an I2C expansion board for the Raspberry Pi.

Power

The Slice of Pi/O may be configured in 3V3 or 5V modes of operation via a jumper.

Power may be taken from the board on PWR and GND if a suitable 4-pin header is fitted.

RPi I2C

Without device tree
sed -i 's/^blacklist/#blacklist/g' /etc/modprobe.d/raspi-blacklist.conf
With device tree
echo "device_tree_param=i2c1=on" >> /boot/config.txt
With and without device tree
echo 'SUBSYSTEM=="i2c-dev", MODE:="0666"' >> /etc/udev/rules.d/10-local.rules
echo "options i2c_bcm2708 baudrate=400000" >> /etc/modprobe.d/modprobe.conf
echo 'i2c-dev' >> /etc/modules
reboot

For the MCP23017 a baudrate of 900000 has been tested and appears to work satisfactorily. You should experiment with this value.

I/O

RPi revision I2C device Default MCP Address
1 /dev/i2c-0 0x20
2 /dev/i2c-1 0x20

Pickle Microchip PIC ICSP

Low Voltage Programming with VPP at 3V3 or 5V

Separate data I/O connections (only supported option)

Wiring
SLICE OF Pi/O                     PICMicro
=============                     ========

PWR-------------------------------VDD

GND-------------------------------VSS

A0--------------------------------VPP

A1--------------------------------PGC

A2--------------1000R--------+----PGD
                             |
A3---------------------------+

A4--------------------------------PGM (1)
  1. Not used by all LVP compatible devices.
Config
VPP=0     # A0
PGC=1     # A1
PGDO=2    # A2
PGDI=3    # A3
PGM=-1
DEVICE=MCP230XX
IFACE=/dev/i2c-1
ADDR=0x20
SLEEP=0
#VPP_RUN + PGD_IN_PULLUP
BITRULES=0x1010

Resources

Assembly manual