The Pi-SPi Series of building blocks for the Raspberry Pi now have sample test code written in Python available for download.
Each Module has test code written in "C" using the Geany Compiler and tested on the RPi 3.
Each Module has test code written in Python and tested on the RPi 3, using the SPI output. Each Module has a dedicated Chip Select line.
Pi-SPi-8AI is available here.
(8 analog inputs, 4 x 4-20mA, 4 x 0 to 6.6 VDC Input, MCP3208 AD COnverter)
Pi-SPi-2AO is available here.
(2 analog 4-20mA Outputs, 2 x 0-10 VDC Output, MCP4922 Dual DA Convert)
Pi-SPi-8DI is available here.
(8 x Isolated Digital input, MCP23S08 IO Expander.)
Pi-SPi-8KO is available here.
(2 x 10A SPDT Relay, 6 Signal Level Outputs, 74HC595 Serial Shift Register)