Author Topic: Blackaddr/Teensy based pedal build  (Read 1578 times)

audioartillery

Blackaddr/Teensy based pedal build
« on: April 06, 2018, 12:16:10 AM »
A friend and I have been talking about getting into DSP effects for a while and recently picked up a couple of Blackaddr's "Teensy Guitar Adapter" boards (I'm just going to refer to them as "Blackaddr boards").  I figured I'd do a build thread as we go along since I don't think many people know about the Blackaddr boards.

This pedal is primarily intended to be a developer platform for our needs.  So it's big, has lots of knobs, and a small OLED display.  We settled on the Hammond 1550G enclosures (roughly 8.5" x 5.75").  They're huge but I didn't want to get backed into a corner since the Blackaddr boards while electrically quite sound aren't really designed to cram into tight spaces.

Here's what I've modeled up so far:





I opted to put the Blackaddr board upside down since it's got quite a bit on its underside (which I haven't modeled in any detail) and mount it by its 1/4" jacks.

With 7 knobs, 6 switches (the knob by the display is also a button), and an I2C display we are way, way out of bounds from what the Blackaddr board brings out to its headers.  It has 8 pins that it exposes from the Teensy and only one of those is an analog input.  So I'm going to use an analog mux for sampling all those inputs.

I found some Neopixel type LED's in a standard 5mm "hat" LED form factor which I'll be using for the indicators since we would otherwise be short one pin.  I may throw some more LED's on there somewhere.

[Note:  there are lots of pins on the Teensy that aren't exposed, we could tap those if needed. Im trying to make this easy plug together. ]

Well that's all for starters. Oh, well, one concern I have is the Teensy will be quite busy doing audio processing. Im a little worried about it driving Neopixel protocol which also has a real time requirement. Worst case I think I just drop another Arduino of some type in the box and hook it up on the I2C lines.
« Last Edit: April 06, 2018, 12:22:55 AM by audioartillery »

ElectricDruid

Re: Blackaddr/Teensy based pedal build
« Reply #1 on: April 06, 2018, 05:57:21 PM »
Crazy stuff! I shall keep an eye on this. Good luck!

Tom

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #2 on: April 09, 2018, 09:23:07 PM »
Some minor progress while I wait for our enclosures.  I've been wanting to build up some skills designing PCB's so I've designed this fairly simple board to route the various inputs from an analog mux to the BlackAddr board.



One of these analog mux boards will socket into this.  I haven't decided on a clean way of mounting this, but I think I can just 3d print a bracket that mounts in there somewhere convenient.

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #3 on: April 14, 2018, 03:51:50 PM »
PCB's should be arriving next week.  In the mean time, did a little test with these programmable LED's.  If you aren't familiar with them, they're usually referred to as NeoPixel type LED's (WS2812 is the underlying chip/protocol).  You can get them in flex circuit strands, grids, rings, etc.  For this project I'm just using them for the foot pedal indicators.

They use a single wire protocol so they just get chained together.  I'll probably cram a few more of them in there some place just because they're cool.

Here's one of mine in action:


Blackaddr

Re: Blackaddr/Teensy based pedal build
« Reply #4 on: April 15, 2018, 09:33:57 PM »
This is looking pretty cool!

If you find that you want to separate the control processing (switches, knobs, leds, etc.) from interfering with the audio processing, take a look at the Teensy LC. Dirt cheap, very small, ideal for handling low-speed stuff that needs interrupts or polling that might interfere with the main Teensy doing DSP work as smoothly as possible.

If you don't mind my asking, what software are you using for the modelling?
« Last Edit: April 15, 2018, 09:40:26 PM by Blackaddr »
Blackaddr Audio
Digital Modelling Enthusiast
www.blackaddr.com

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #5 on: April 15, 2018, 10:34:28 PM »
Fusion 360 for the 3d modeling, KiCAD for the PCB.

Yeah my fallback plan is to put down another board/processor to handle I/O and leave the Teensy just for audio processing. My understanding is the Teensy has a DMA based neopixel library which is the only real-time thing I need to do besides process audio.

The Teensy LC looks super tiny. Id probably use a Blue Pill board since Ive got a few of them and theyre like $2.

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #6 on: April 20, 2018, 12:45:02 AM »
Got the PCB's back today.




I spent some time trying to get an I2C device talking on the SCL2/SDA2 lines that are brought out to the BlackAddr external header (which I've broken out on this PCB).  Can't seem to get the Teensy advanced scanner to work with the Wire2 bus, it just times out.  I'm pretty new to the Teensy ecosystem so it may be something I've overlooked... seems like it ought to work though.

Blackaddr

Re: Blackaddr/Teensy based pedal build
« Reply #7 on: April 29, 2018, 11:33:35 AM »
I spent some time trying to get an I2C device talking on the SCL2/SDA2 lines that are brought out to the BlackAddr external header (which I've broken out on this PCB).  Can't seem to get the Teensy advanced scanner to work with the Wire2 bus, it just times out.  I'm pretty new to the Teensy ecosystem so it may be something I've overlooked... seems like it ought to work though.

Obviously it's not shown in your pictures but I presume you've got pullup resistors on our SDA/SCL lines and you've used the commands to correctly set the pin numbers for SDA and SCL? If you are using EXT1 and EXT2 on the TGA schematic the logical pin numbers 3 and 4 for SCL2/SDA2 respectively (not 5 and 6 which are physical pin numbers) .

I suggest posting some code over on the PJRC forums. Lots of people there familiar with the Wire library and using the Wire2 bus extensions. I've not tried any I2C devices myself beyond the CODEC on the TGA board which is on the regular Wire bus.
Blackaddr Audio
Digital Modelling Enthusiast
www.blackaddr.com

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #8 on: May 01, 2018, 10:19:28 AM »
I was able to get the OLED to scan on i2c2 once I sorted out the fuse issue you and I have been discussing and enabled internal pullups.

I then ran into the giant mess that is Arduino's i2c ecosystem.  The Adafruit SSD1306 OLED library, like most Arduino i2c libraries, is tied to using "Wire" (the i2c0 bus on Teensy).  Of the suggestions I've seen the most straightforward is to copy the library and replace Wire with Wire2 everywhere.  My first pass of that didn't work but I may be missing something...

It might have been friendlier for users to route the default i2c bus out to external pins and use one of the others internally, but I'm sure I'll sort this out eventually.

My Hammond enclosures are finally here so I need to get off my butt and prove out all the peripherals before we start drilling holes...

Blackaddr

Re: Blackaddr/Teensy based pedal build
« Reply #9 on: May 04, 2018, 12:46:28 PM »
The default was chosen so the BA enhanced version of the WM8731 control codec would be pin compatible with the base one proved by the Teensy Audio Library.

To get yourself up and running, you could trying adding a second device to the Wire bus by fly-wiring to the default pins. You should be able to have more than one i2C device on the same bus. Once you have your display working, you can port it over to using Wire2 and the expansion headers.
Blackaddr Audio
Digital Modelling Enthusiast
www.blackaddr.com

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #10 on: May 04, 2018, 02:01:53 PM »
The default was chosen so the BA enhanced version of the WM8731 control codec would be pin compatible with the base one proved by the Teensy Audio Library.

Makes sense.

After a LOT of whacking at the Adafruit SSD1306 library to make it use Wire2:



What a mess though!  But this morning was able to test with the midi app and see the values change on the display when I tweak them in the app.  Very cool!  Not sure what exactly I'm going to do with the display but it's good to have it working.

Blackaddr

Re: Blackaddr/Teensy based pedal build
« Reply #11 on: May 06, 2018, 07:13:13 AM »
Looks freakin' cool.
Blackaddr Audio
Digital Modelling Enthusiast
www.blackaddr.com

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #12 on: May 24, 2018, 04:21:34 PM »
Made a little bracket to hold the PCB in the enclosure.  Having a dirt cheap 3d printer comes in handy now and then.




I think I've got all the parts and pretty much just need to spend an evening in the garage drilling holes and wiring things up.  Will be nice to get back to writing effects.

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #13 on: July 02, 2018, 12:09:10 AM »
My buddy and I drilled out the first enclosure and Ive just been too busy to start mounting things... at least got the pots and switches in place tonight. Starting to look like a pedal.



Insides:



Lots of wiring to do!
« Last Edit: July 03, 2018, 12:30:44 AM by audioartillery »

Blackaddr

Re: Blackaddr/Teensy based pedal build
« Reply #14 on: July 07, 2018, 07:56:34 AM »
looking very cool. Have you got any plans for painting the enclosure when it's all said and done?

When I first tried painting enclosures I ended up applying a base coat, then used masking tape to make some very primitive geometric designs while layering different colour coats. I later upgraded to color printing some custom graphics on translucent sticker paper that covers then entire face of the pedal, then putting as sh*t-ton of clear coats over it to seal it in. If you're curious here's an example of what the later looked like.
Blackaddr Audio
Digital Modelling Enthusiast
www.blackaddr.com

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #15 on: July 10, 2018, 04:40:37 PM »
looking very cool. Have you got any plans for painting the enclosure when it's all said and done?

We've kicked a few ideas around.  Since this is intended to use just for our own internal development I'm not too worried about what it looks like.  I sort of wish I'd grabbed the pre-powder-coated variant instead since it will probably be a while before we take this all apart and paint it.

I've got a CNC milling machine so we could paint it and then engrave stuff on it.  My partner in crime has some drawing skills and I think wants to do this all octopus themed which I'm down with.

Blackaddr

Re: Blackaddr/Teensy based pedal build
« Reply #16 on: July 14, 2018, 07:01:35 AM »
looking very cool. Have you got any plans for painting the enclosure when it's all said and done?
I've got a CNC milling machine so we could paint it and then engrave stuff on it.

Never thought of that. I've seen people chemically etch a design into it then polish the hell outta the aluminum but engraving would be pretty original!
Blackaddr Audio
Digital Modelling Enthusiast
www.blackaddr.com

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #17 on: September 14, 2018, 01:26:40 AM »
I'm not dead!  Got thru some summer project madness and finally got back to this tonight.  Got the 6 pots wired up to the analog mux:



And got those working as control inputs just like the midi inputs from the BAGuitar library.  You can still override with the midi inputs.



Need to wire up the switches next, and then the neopixel LED's, and then get back to writing effects.  I think I'm punting on the OLED for now as I haven't decided on a clean way to mount it on the enclosure yet.

audioartillery

Re: Blackaddr/Teensy based pedal build
« Reply #18 on: September 15, 2018, 01:06:44 PM »
Got the foot switches and Neopixel LED's hooked up!  It's now a usable effects development kit.



The effect I'm using in this video is sort of a envelope-generated noise effect.  It's not super useful but it was easy to port from another platform that I was using before.
« Last Edit: September 15, 2018, 01:09:10 PM by audioartillery »