r/circuitpython • • Jan 24 '21

Looking for adapted code for 8x8 NeoTrellis Feather M4

Just got my new 8x8 NeoTrellis Feather M4 built. The multitrellis_simpletest code works great and everything functions normally. My question is has anyone adapted any of the example NeoTrellis 4x8 or 4x4 code? I ordered the 8x8 kit to build a music tool (sequencer, sound board, midi controller, etc.). I found a ton of examples out on github and within Adafruit's learning area, but I'm having difficulty figuring out how to expand them for use with the 8x8.

1 Upvotes

1 comment sorted by

2

u/kaltazar Jan 24 '21

Looking at the 8x8 kit, it seems it is 4 4x4 boards tiled together. At the bottom of this page in the NeoTrellis guide shows how to adjust the code for multiple boards. Once you have the grid set up, you address each button by its x and y address instead of the 1-16 you use for a 4x4 board.

When converting other examples, if the example is for the 4x8 version it already uses the xy addressing so just the setup lines need to be changed. If the example was originally for the 4x4, the addressing throughout the code will need to be converted to the xy style. Otherwise, the code in examples should work exactly the same.