Skip to content

bertrandmartel/metec-braille-driver

Repository files navigation

Metec Braille cell driver

Build Status Build status NuGet License

Driver for Metec Braille-line 20 Cell standard module for Arduino & Raspberry PI

This module is composed of 20 B11 Metec Braille cells driven by piezo-actuators which also feature one interaction button per cell (eg 20 buttons for this module). The module also needs a DC/DC converter (5V to 200V)

This library is compatible with :

  • Arduino (tested on Uno & Mini)
  • Raspberry PI Linux & wiringPi library
  • Rapsberry PI Windows IoT core OS

This repo also includes an example using this driver and liblouis altogether on Raspberry PI (Linux/wiringPi)

Wiring

Arduino Uno

arduino Uno breadboard view

Arduino Mini

arduino Mini breadboard view

Raspberry PI

Raspberry PI breadboard view

Setup

git clone git@github.com:bertrandmartel/metec-braille-driver.git
cd metec-braille-driver
git submodule update --init --recursive

Project structure

.
├── src                              # library source
├── include                          # library includes
├── arduino      
│   ├── arduino-makefile             # makefile for arduino (build environment)
│   ├── examples                     # examples containing one folder per example
│   └── Makefile                     # library Makefile (each sample call this Makefile)
├── raspberry      
│   ├── linux-wiringpi               # Linux build with wiringPi library folder
│   │   ├── examples                 # examples folder
│   │   ├── raspberry-dev            # toolchain & wiringPi build using cmake
│   │   ├── out                      # library output directory
│   │   ├── out_liblouis             # liblouis output directory
│   │   ├── CmakeList.txt            # cmake config for building MetecDriver and liblouis
│   │   ├── liblouis_install.sh      # liblouis table install script (to run on Raspberry PI)
│   │   ├── run.sh                   # build script
│   │   └── clean.sh                 # clean raspberry pi folder (remove cache, output dir etc...)
│   ├── windows-iot                  # Windows IoT core folder
│   │   └── MetecDriver 
│   │       ├── MetecDriverLibrary   # library project compiling C++/CX into Windows Runtime Component
│   │       ├── ExampleButtonSimple  # buttons input example in C#
│   │       ├── ExampleButtons       # buttons input + write pattern example in C#
│   │       ├── ExamplePatternChange # change pattern every x sec example in C++
│   │       ├── MultiCellsExample    # write multiple pattern example in C++
│   │       └── SingleCellExample    # write single pattern example in C++
│   └── liblouis                     # liblouis submodule build folder
├── 8pin-adapter                     # KiCad files for 2.00mm to 2.52mm 8 pin adapter
└─── fritzing                        # Fritzing sketch for wiring pictures

Library Usage

8 Pin Adapter

The 8 pin adapter 2.00mm to 2.54mm was created on KiCad EDA, files are available under 8pin-adapter :

8 Pin Adapter

8 Pin Adapter

Protocol

Braille pattern

3 signals are used :

  • STRB (OUTPUT)
  • CLK (OUTPUT)
  • DIN (OUTPUT)

A shift register is used to write the Braille pattern, the data is written to DIN between each clock transition (data is written on CLK falling edge). All bit are latched on STRB falling edge.

The bit order for the Braille cell is the following XORed :

bit order

You can use this tool to test values

For example the following write letter "V" aka ⠧ which is BRAILLE-1236 in unicode :

braille pattern

explanation for above : ⠧ gives 11000011 (XORed), bit order is 6/7/2/1/0/5/4/3 so it gives : 11011000, and XORed : 00100111

Interaction buttons

3 signals are used :

  • STRB (OUTPUT)
  • CLK (OUTPUT)
  • DOUT (INPUT)

The buttons can be read when strobe is high between each clock transtion (falling edge). B11 module can have 2 buttons so we need to read 20 * 2 times each time we check for button state :

button interaction

explanation for above: the 2 last bit read are 01 which means the first button has been pressed

More resources

License

The MIT License (MIT) Copyright (c) 2018 Bertrand Martel