So you have a new board, that you want to get working with Blinka, our CircuitPython library compatibility layer for Single Board Computers, or SBCs. Adding a board to Blinka is a 2-part process with the first step being to add it to PlatformDetect so that Blinka knows what board it is working with.

In our PlatformDetect guide, we went over the steps needed to get your chip and board correctly detected so that Blinka knew what it was working with. In this guide, we will go over the second part to get your board functioning on Blinka.

This guide goes over everything that's left to get your board working with Blinka including:

  • Adding the Chip and Board files
  • Getting GPIO working
  • Getting I2C, SPI, and UART working

Along with some additional resources.

The way that Blinka works is it combines multiple techniques to access the parts of the board that it needs. For GPIO, libraries such as RPi.GPIO or libgpiod are used. For I2C, the PureIO Python library is used, and for SPI, we are using the spidev Python library.

When it comes to Blinka itself, there are two main components that need to be defined.

  • First there is the chip, the microprocessor definition.
  • Second, there is the board definition.

The chip defines which pins of the microprocessor are used by the GPIO library and the board defines which physical pin on the board maps to the pins defined by the chip file. There can be multiple boards that all use the same chip, but the specific implementation may be slightly different.

The overall layout of the way these files are accessed looks like this:

In this guide, we will be picking up where we left off in the PlatformDetect guide and going over what steps are needed to add a board such as the Pine A64 to Blinka.

Parts

USB to TTL Serial Cable - Debug / Console Cable for Raspberry Pi

PRODUCT ID: 954
The cable is easiest way ever to connect to your microcontroller/Raspberry Pi/WiFi router serial console port. Inside the big USB plug is a USB<->Serial conversion chip and at...
$9.95
IN STOCK

FTDI Serial TTL-232 USB Type C Cable

PRODUCT ID: 4364
Just about all electronics use a UART serial port with RX and TX pins for debugging, bootloading, programming, serial output, etc. But it's rare for a computer to have a serial...
$19.95
IN STOCK

Diffused Blue 10mm LED (25 pack)

PRODUCT ID: 847
Need some big indicators? We are big fans of these huge diffused blue LEDs. They are really bright so they can be seen in daytime, and from any angle. They go easily into a breadboard...
$9.95
IN STOCK

Tactile Switch Buttons (12mm square, 6mm tall) x 10 pack

PRODUCT ID: 1119
Medium-sized clicky momentary switches are standard input "buttons" on electronic projects. These work best in a PCB but
OUT OF STOCK

Adafruit BME280 I2C or SPI Temperature Humidity Pressure Sensor

PRODUCT ID: 2652
Bosch has stepped up their game with their new BME280 sensor, an environmental sensor with temperature, barometric pressure and humidity! This sensor is great for all sorts...
OUT OF STOCK

Thermocouple Amplifier MAX31855 breakout board (MAX6675 upgrade)

PRODUCT ID: 269
Thermocouples are very sensitive, requiring a good amplifier with a cold-compensation reference. The MAX31855K does everything for you, and can be easily interfaced with any...
$14.95
IN STOCK

Thermocouple Type-K Glass Braid Insulated

PRODUCT ID: 270
Thermocouples are best used for measuring temperatures that can go above 100 °C. This is a bare wires bead-probe which can measure air or surface temperatures. Most inexpensive...
OUT OF STOCK

Adafruit Ultimate GPS Breakout - 66 channel w/10 Hz updates

PRODUCT ID: 746
We carry a few different GPS modules here in the Adafruit shop, but none that satisfied our every desire - that's why we designed this little GPS breakout board. We believe this is...
$39.95
IN STOCK
This guide was first published on Apr 01, 2020. It was last updated on Apr 01, 2020.
This page (Overview) was last updated on Oct 25, 2020.