Analog to Digital to Analog

The Gertboard has an MCP3002 dual-channel 10-bit, analog to digital converter. This is connected to the SPI bus as device number 0, as well as an MCP4802 dual-channel, 8-bit digital to analog converter. These can be used from your own … Continue reading

On-board SPI Devices

The Gertboard has 2 SPI device on-board and there are connected to the jumper block so that they can be directly connected to the Raspberry Pi’s SPI bus. The Pi has one SPI bus with two enable pins – this … Continue reading

Higher Current Drivers

The Gertboard has 6 outputs that are driven from a ULN2803 darlington driver chip. This is an open-collector output and is capable of sinking a maximum of 500mA in total. You can connect the outputs to a higher voltage than … Continue reading

12 LEDs

The Raspberry Pi has 17 GPIO pins (plus 4 more on the Rev 2, but we can’t easily use these with the Gertboard). Some of these pins are dual-purpose. The only ones that are normally set to an alternative mode … Continue reading

Buttons

The Gertboard has 3 buttons and if we want to use the buttons then (as odd as this may seem!) we need to leave the corresponding 3 buffer In/Out selector jumpers either removed or set to Output mode. To understand … Continue reading

Blink

Blink is the “Hello World” of the microcontroller world. It usually does nothing more than flash an LED or 2. So, assuming that you have your Pi connected to your Gertboard as described in the last page then we can … Continue reading

Analog In/Out

The Gertboard has an on-board Digital to Analog (DAC) converter and an Analog to Digital (ADC) converters. These are connected via the SPI bus back to the Raspberry Pi host. Each of the DAC and ADC chips has 2 channels. … Continue reading

Initial setup of the ATmega

Before we can start to program the ATmega, we need to initialise the chip. The chip itself needs to be told about various parameters such as it’s clock speed, how much flash to reserve for the bootloader (none in our … Continue reading

The GPIO utility

WiringPi comes with a separate program to help manage the GPIO. This program, called gpio, can also be used in scripts to manipulate the GPIO pins – set outputs and read inputs. It’s even possible to write entire programs just … Continue reading