Status: work in progress. Not exactly noob friendly just yet.
Code to use a set of Adafruit NeoTrellis boards as a monome grid clone.
Tested mostly using a Teensy 3.2 microcontroller.
There is code for using an Adafruit ItsyBitsy M0 (and by extension the Feather M0/M4), but this requires some changes to the underlying libraries (replacing the Adafruit_USBD_Device library deep in the adafruit/arduino core libraries).
Compiled firmware for Feather M4 and ItsyBitsy M0 coming soon.
At the time of writing, this code works as expected with the neotrellis-grid connected to a computer with Max running monome patches.
Does not work. Don’t ask (unless you know C well and can help me make changes to libavr32).
Officially unsupported. Hacking required. Proceed at your own risk. May void your warranty. Prohibited in some states.
Unfortunately this code will not work right off the shelf with the stock norns codebase (norns and norns shield) due to some USB device management stuff.
But... there is a hack workaround, but it does require changes to the norns C code. It’s not hard, but steps will need to be repeated after updates, etc. Contact me for instructions.
For Fates devices , I have a script in my repo which will run the fix.
8 Adafruit NeoTrellis driver boards [alt Mouser | Digikey ]
8 Button keypads [alt Mouser | Digikey ]
1 Adafruit micro B USB Breakout [alt Mouser | Digikey ]
1 Teensy 3.2 [alt Adafruit ]
- Test each neotrellis board individually using the Adafruit examples in the
File>Examples>Adafruit seesaw Library>Neotrellis
menu. The Basic sketch is good for testing individual boards. Themultitrellis>basic
sketch is good once you have all the boards connected and addresses assigned.
-
Review the Adafruit tutorial on the neotrellis boards.
-
see this video for an example of how to join the boards together
-
see this graphic for a default layout of addresses and jumper positions for 8 neotrellis boards.
-
new default address order in the code for 16x8 layout (NOTE the address are in reverse order in the code - as compared to the graphic above):
{ Adafruit_NeoTrellis(0x32), Adafruit_NeoTrellis(0x30), Adafruit_NeoTrellis(0x2F), Adafruit_NeoTrellis(0x2E)}, // top row
{ Adafruit_NeoTrellis(0x33), Adafruit_NeoTrellis(0x31), Adafruit_NeoTrellis(0x3E), Adafruit_NeoTrellis(0x36) } // bottom row
-
see this neotrellis i2c address chart if you want to define your own addresses
-
Don't worry about the INT pin - it's not used in the grid software.
For the Teensy firmware - be sure you have Arduino settings Tools -> USB Type
set to Serial
Not critical, but set Tools -> CPU Speed
to 120 MHz (overclock)
For reference: here's a forum post on how to flash Teensy firmware
-
Be sure you have the Adafruit Seesaw libraries installed and are up to date (via the Arduino Library Manager)
-
Be aware - the multitrellis array will fail to initialize if the addresses are wrong, or the wrong number of boards are attached.
-
There are Teensy specific i2c_t3 example sketches which can be used to double check your i2c addresses. See
File>Examples>i2c_t3>basic_scanner
for more. -
use multitrellis_test sketch to test fully assembled grid before flashing neotrellis_monome_teensy.
see this thread on the lines forum for assistance.
https://github.com/oldmanfury/neotrellis-grid-paletted
If you're on norns shield with 200218 do the following (if you're on another version, update first).
NOTE - Be aware this is a hack/workaround and is not officially supported. Proceed at your own risk
cd ~/
sudo apt-get update
sudo apt-get install libncurses5-dev libncursesw5-dev
wget https://raw.githubusercontent.com/okyeron/fates/master/install/norns/files/device/device_monitor.c
cd ~/norns
git pull
git submodule update --init --recursive
sudo cp -f /home/we/device_monitor.c /home/we/norns/matron/src/device/device_monitor.c
rm /home/we/device_monitor.c
./waf clean
./waf configure --enable-ableton-link
./waf build
sudo reboot
If you already have serialosc installed/running, you may need to unload serialosc to get arduino to properly flash the teensy, then load serialosc to get Max to recognize the grid.
launchctl unload /Library/LaunchAgents/org.monome.serialosc.plist
launchctl load /Library/LaunchAgents/org.monome.serialosc.plist
Max apps for testing:
Monome Home
test-grid
The mext protocol is used for serial communication - same as what is used in most recent monome devices.
serialosc
is required for serial communication with MacOS/Windows computers and OSC devices. Linux may use serialosc
or libmonome
depending on the application. libmonome
is basically driver code which also facillitates monome serial communication.
You can get both serialosc
and libmonome
code from monome github page, and building them is well documented on official linux docs (they work for macOS as well), read part 2 Preparing your system: serialosc (ignoring the sudo apt-get
- I was missing liblo
, but it's available on homebrew): monome.org/docs/linux/.