"... and no one shall work for money, and no one shall work for fame; But each for the joy of the working, and each, in his separate star, shall draw the thing as he sees it, for the god of things as they are"

-Kipling

 

BBBCSIO - A C# I/O Library for the Beaglebone Black

Summary

BBBCSIO is a free and open source .NET v4 library which provides a comprehensive C# input/output solution for the Beaglebone Black Mono environment. Using BBBCSIO, you can easily read and write to the GPIO pins (and trigger interrupt events from state changes), launch and interact with PRU programs and control SPI, I2C, PWM, UART and A2D devices. BBBCSIO is intended to be a comprehensive solution for I/O on the Beaglebone Black. At the current time only a few minor OCP devices remain to be implemented. Besides the downloadable DLL library and source code the BBBCSIO contains complete Help Files and Examples . There is also a Notes section which provides more information on numerous topics such as the Device Tree and the PinMux.

Note: In order to use the BBBCSIO library, C# and Mono must be installed on the Beaglebone Black. A separate project documents that installation procedure.

Example BBBCSIO Code which Toggles a GPIO Pin at 1Hz

 

Example BBBCSIO Code which Toggles a GPIO Pin at 1Hz

Capabilities

What BBBCSIO Does Not Do

Help Files and Manual

The Help Pages discuss the usage of the BBBCSIO software and calling conventions for the classes it contains. The BBBCSIO software zip files (below) also contain these help files.

Sample Code

The BBBCSIO help pages contain an Example Code section which illustrates the usage of the BBBCSIO library.

Source Code

A web browsable version of the BBBCSIO Source Code is available.

Installation

If you download only the BBBCSIO.dll (rather than the source) you can use it like any other .NET dll library. Either place the BBBCSIO.dll in the same directory as the exe file or copy the dll into the /usr/lib directory where it will be available to all programs that need it. Of course, you will need to reference it in the .NET solution just as you would any other library.

If you download the source code you can include the BBBCSIO.proj into your .NET solution in the usual way and the software should compile.

Note: There is a separate project on this website which describes how to set up a remote compilation and debugging toolchain for Mono on the Beaglebone Black.

License

The contents of the BBBCSIO web pages, the help pages, the downloadable executables and the source code are are provided "as is" without any warranty of any kind and without any claim to being error free or complete. Please be aware that the documentation, executables or source code provided may be out-of-date, incomplete, erroneous or simply unsuitable for your purposes. Any use you make of the BBBCSIO documentation, source code and executables is entirely at your discretion and any consequences of that use are entirely your responsibility.

All source code and executable libraries are provided under the terms of the MIT License.

Download