March 28, 2014
The latest version of raspi-config allows you to enable the SPI drivers without having to edit raspi-blacklist.conf file yourself.
In LXTerminal start raspi-config by type:
Select the advance menu option and chose enable SPI devices. Exit the menu and reboot your Pi.
We’ll program our example in Python, so we’ll start by downloading the SPIdev driver library.
We can use Python Installer to get install it:
sudo pip install spidev
A quick python example is shown below:
# ADC Channel
ADCCHAN = 1
# Open SPI, use Chip Select 0
spi = spidev.SpiDev()
adc = spi.xfer2([1,(8+ADCCHAN)<<4,0])
data = ((adc&3) << 8) + adc
print ('ADC CH1 =', data)
The MiniPIIO Uses a Microchip MCP3004 (or MCP3204) which are from the same ADC familily as the MCP3008
You can find the MiniPIIO AIN4 at our Tindie store:
March 21, 2014
MiniPIIO Breakout! is our newest add-on board for the Raspberry Pi.
It breaks out (hence its name) all the Pi’s expansion I/O into four neat little groups.
UART is broken out into a 6-Way and 4-way pin header. The 6-Way is FTDI USB Cable compatable.
SPI is broken out into two 6-way headers, each with it’s own SPI chip select.
I2C is borken out into two 4-way headers.
GPIO is broken out into two 10-way headers. GPIO4/17/18/22/23/24/25/27 and 3.3V and 0V.
You can buy it at our Tindie store here
March 7, 2014
RPi-X ELab101 is the second of my RPi-eXperimeter boards.
RPi-X ELab101 is a mini electronics lab for the Pi.
It is dominated by a 170-pin bread boarding area for prototyping and construction your circuits on. Next to this, there are 3x tactile switches, 3x LED’s, 2x potentiometers and a buzzer circuit which make up the input and output devices. These are connected to female headers allowing them to be quickly interfaced with the Pi’s GPIO’s using simple male-male jumper wires.
For analogue measurements, a 4-channel 0V to 10V, 10-bit ADC is included and it’s inputs are also available via a female header connector.
Finally, all the signals from the Pi’s expansion header are brought out to female headers, giving access to all the Pi’s expansion signals, including the GPIO’s, SPI, I2C, UART and PWM.
More to come….