Using MonoBrick Communication Library On Mac OS

This guide describe how to get the LEGO Mindstorms NXT brick to work with the MonoBrick communication library under Mac OS.

Installing Mono and MonoDevelop

First you need to install the Mono Runtime or the Mono SDK. Install the SDK and MonoDevelop only if you are planning to write your own programs using MonoBrick communication library. All three files can be downloaded from the Mono website. Once the Runtime/SDK has been downloaded unpack the file and install the PKG file.

Once this is done you should be able to run C# programs.

Bluetooth Communication

To communicate with the EV3/NXT over Bluetooth a partnership between Mac OS and the brick has to be established. This requires the following five steps

  1. Search for a new bluetooth device
  2. Connect to EV3/NXT brick
  3. Enter 1234 as the pairing code on the EV3/NXT
  4. Enter 1234 as the pairing code on the Mac
  5. Wait for pairing to be established

Once these steps are done you should be able to communicate with the brick using Bluetooth. Below is a step by step image guide for the NXT…

Once you are done the brick will appear as something like /dev/tty.EV3-SerialPort where EV3 is the name of the brick.

USB Communication

The installers for MonoBrick Remote and MonoBrick Tunnel  installes the necessary files for USB support. For development purposes the MonoBrick communication library download and the MonoBrick communication library test project includes pre-compiled libusb and HID API files for use with USB communication. These files should be placed in the same folder as the exe file that you want to run. Alternatively you can install or compile libusb and HID API using homebrew or something similar and use these files.

Make a donation