Custom matrix size


#1

Hello,

I am building a MIDI-Controller with RGB LEDs and would like to use the SmartMatrix library.
Is it possible to control RGB matrices with different sizes?
My matrix is 20x20 on a custom PCB, the interface is the same as the normal matrices.

Sorry if this is a stupid question, I am new to SmartMatrix.

Thanks for your help,
Moritz


#2

Hi Moritz, what type of RGB LEDs are you using? I’m guessing WS2812s. SmartMatrix is designed to support multiplexed LED matrix displays, these have driver chips on the back of the board, not within the LEDs themselves.

Take a look at FastLED, they have a great library for driving ws2812s and other integrated LEDs and a great community too.


#3

Hi Louis,
no I am not using WS2812, they are nice, but to big and power hungry for my project.
I know the way of driving matrices and my PCB will be designed to be compatible with them.

My question is: Can I modify the code to drive a Matrix with other dimensions?
I am using two MBI5026 (32 outputs, 20 used)
The best way to scan the matrix would be 1/10th scanning, is this possible? (maybe with 3 demultiplexers)

Which DMA channels does SmartMatrix use?

Thanks for your help,
Moritz


#4

OK, sounds like you know what you’re doing. The new SmartMatrix Library 3.0 is more configurable and you can add custom configurations without changing too much code:

I think 1/10 scanning would be possible, but I haven’t tested the library on anything but the standard HUB75 16x32 and 32x32 panels.

It uses the first four channels assigned by the Teensy DMAChannel class, usually 0-3, but if you are using the Teensy Audio library for example, it would run on 1-4.

Interested in hearing more about your project.

Louis


#5

Thanks Louis, I am looking into the library and it looks like I can do it.

I am building a MIDI controller with a 20x20 RGB button grid and three OLED displays. I am using Adafruit Trellis buttons.

I created a custom PCB with the circuitry for controlling the LED and button matrices.
Everything is controlled by a Teensy 3.1 and talks via USB to Ableton live.

This is an early rendering:
(I can’t upload images) http://imgur.com/owCrmU8


#6

Very cool, lmk if you have any questions about the library as you’re looking into the code, or tweaking for your application.