Skip to content

Mates Controller Libraries

Introduction

Mates Studio's Commander and Architect environments allow Breadboard Mates display modules to be used with any host controller as long as it supports or can connect via TTL level UART. To easily interface with, several software libraries are made available to use.

Software Libraries

Here are the libraries available to use.

Arduino

This is developed for the Arduino platform and should provide full compatibility with AVR devices. Other Arduino devices are also supported with no modification. In case of incompatibility, please raise an issue through the GitHub repository.

C Library

This is developed for the any platform that can be programmed with C programming language. This is provided as a simple starting point since C can be used with a wide variety of devices that may not be covered with the other libraries provided.

Python

This is developed for the any platform that can be programmed with Python. This is used as the base of all other Mates Controller Python libraries provided.

  • RPi Python: developed specifically to control BBM devices using Raspberry Pi through the GPIO pins.
  • BBM Python: developed specifically to control BBM devices through a Mates Programmer (BBM-PROG) from a computer. This can also be used with Linux computers such as Raspberry Pi as long as the connection is through USB connection.

Note

It is recommended to use the libraries listed if the host controller is applicable. Otherwise, the base Python library can be used. Everyone is welcome to create support for other Python programmable devices.

MicroPython

This is developed for the any platform that can be programmed with MicroPython.

Error Codes

The table below lists the possible errors after running a function/method from the libraries.

Error Value Description
MATES_ERROR_NONE 0 Last command was completed successfully
MATES_ERROR_COMMAND_FAILED 1 The display failed to perform the last command
MATES_ERROR_COMMAND_TIMEOUT 2 The display didn't acknowledge the command in time
MATES_ERROR_RESPONSE_TIMEOUT 3 The display didn't send a return value in time
MATES_ERROR_NOT_INITIALIZED 4 The library hasn't been initialized yet
MATES_ERROR_SYNC_TIMEOUT 5 The synchronization attempt reached specified timeout
MATES_ERROR_SYNC_ERROR 6 Invalid active page or no reply received after sync