Skip to content
steve-bate edited this page Oct 14, 2012 · 13 revisions

Welcome to the ChibiOS-RPi wiki!

This is an experimental port of ChibiOS to the Raspberry Pi platform.

Getting Started Guide

Current Status

Device Driver Status Notes
Port (GPIO) Implemented
Serial (mini-UART) Implemented
I2C Implemented
SPI Implemented LoSSI not supported yet
System Timer Implemented Thread preemption
GPT (General Purpose Timer) Implemented
Real-time Clock (RTC) Implemented Requires external device (DS1307)
Watchdog Timer Implemented Supports software reset.
PWM Work in Progress

Several devices have been tested with the device drivers. If you have successfully used other devices with ChibiOS/RT on the Pi, please send me a note and I'll add it to the list.

Device Protocol Description
TMP102 I2C Digital Temperature Sensor Breakout
MCP4725 I2C 12-Bit Digital to Analog Converter (DAC)
MCP3008 SPI 8-Channel 10-Bit Analog to Digital Converter (ADC)
DS1307 SPI Real Time Clock (RTC)
FTDI Serial Adapter Serial Mini-UART access via the pin header
Onboard LED (green) Port Also used with external LEDs.

Running the Code

An example application is in demos/demos/ARM11-BCM2835-GCC. This example creates one thread to blink the onboard LED and another thread to support a very simple command shell.

Assuming you have a suitable cross compiler installed, you can just run the make file in the application directory and it will build the application (build/ch.bin). Adding EXTENDED_SHELL=yes to the make command line will compile in several extra commands for the ChibiOS shell but will also increase the bin file size from about 11 kb to about 45 kb.

You can run the application from the SD card, but I prefer to use David Welch's bootloader05 (code) with an FTDI breakout board (https://www.sparkfun.com/products/9873).

Near Term Objectives

Clone this wiki locally