DIYstompboxes.com

DIY Stompboxes => Digital & DSP => Topic started by: audioartillery on April 06, 2018, 12:16:10 AM

Title: Blackaddr/Teensy based pedal build
Post by: audioartillery 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:

(https://i.imgur.com/PjiSzotl.png)

(https://i.imgur.com/US5zm7jl.png)

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. I'm 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. I'm 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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: ElectricDruid on April 06, 2018, 05:57:21 PM
Crazy stuff! I shall keep an eye on this. Good luck!

Tom
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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.

(https://i.imgur.com/QjtNh4D.png)

One of these analog mux boards (https://www.aliexpress.com/item/16CH-Analog-Digital-MUX-Breakout-Board-CD74HC4067-Precise-module-For-Arduino/32816025305.html?spm=a2g0s.9042311.0.0.WSy7MV) 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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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:

(https://i.imgur.com/eWtWM70.gif)
Title: Re: Blackaddr/Teensy based pedal build
Post by: Blackaddr 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?
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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. I'd probably use a "Blue Pill" board since I've got a few of them and they're like $2.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery on April 20, 2018, 12:45:02 AM
Got the PCB's back today.

(https://i.imgur.com/4Alg2C4l.jpg)
(https://i.imgur.com/hNC2oyrl.jpg)

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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: Blackaddr on April 29, 2018, 11:33:35 AM
Quote from: audioartillery on April 20, 2018, 12:45:02 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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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...
Title: Re: Blackaddr/Teensy based pedal build
Post by: Blackaddr 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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery on May 04, 2018, 02:01:53 PM
Quote from: Blackaddr 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.

Makes sense.

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

(https://i.imgur.com/zRupLpKl.jpg)

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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: Blackaddr on May 06, 2018, 07:13:13 AM
Looks freakin' cool.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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.

(https://i.imgur.com/ZGkJbWZl.jpg)
(https://i.imgur.com/va7deDJl.jpg)

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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery on July 02, 2018, 12:09:10 AM
My buddy and I drilled out the first enclosure and I've just been too busy to start mounting things... at least got the pots and switches in place tonight. Starting to look like a pedal.

(http://i.imgur.com/4oY3k1kl.jpg)

Insides:

(http://i.imgur.com/0H493xcl.jpg)

Lots of wiring to do!
Title: Re: Blackaddr/Teensy based pedal build
Post by: Blackaddr 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 (http://blackaddr.com/wp/wp-content/uploads/2017/01/helios.jpg) of what the later looked like.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery on July 10, 2018, 04:40:37 PM
Quote from: Blackaddr 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?

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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: Blackaddr on July 14, 2018, 07:01:35 AM
Quote from: audioartillery on July 10, 2018, 04:40:37 PM
Quote from: Blackaddr 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?
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!
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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:

(https://i.imgur.com/bNbKPqjl.jpg)

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

(https://i.imgur.com/23raNDVl.jpg)

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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery 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.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery on December 09, 2018, 08:53:19 PM
Made a brief demo of a fuzz effect I've been working on. This platform is quite usable at this point, it's going to be a nice long winter of effects prototypes.

Title: Re: Blackaddr/Teensy based pedal build
Post by: GuitarPhil on June 21, 2019, 11:32:45 AM
Hey there!

Did you ever get the OLED added to your project?

I'm asking because in my latest project I hit a problem with the OLED injecting a loud buzz, presumably into the ground line.

The pedal was quiet if it was teh only pedal or if it was running on a separate PSU or when on a true isolated one (I have a Voodoo Labs 4x4) with other pedals but it was unusable if it was running with other pedals on a daisy chain or one of the cheap multi output supplies like the Joyo JP-02 or the many clones.


The solution I have come up with required a 3-stage LCR filter on the OLED supply but even this didn't fully cure the buzz. I finally had to replace the OLED with an LCD like this https://www.ebay.co.uk/itm/1-3-ST7789-240x240-SPI-Colour-IPS-TFT-Screen-Display-Module-for-Arduino/283411111864?hash=item41fc9e5fb8:g:7g8AAOSwoF5chBSN&frcectupt=true (https://www.ebay.co.uk/itm/1-3-ST7789-240x240-SPI-Colour-IPS-TFT-Screen-Display-Module-for-Arduino/283411111864?hash=item41fc9e5fb8:g:7g8AAOSwoF5chBSN&frcectupt=true):


Phil.
Title: Re: Blackaddr/Teensy based pedal build
Post by: audioartillery on August 07, 2019, 12:57:38 PM
Quote from: GuitarPhil on June 21, 2019, 11:32:45 AMDid you ever get the OLED added to your project?

Hmmm, I think I did but it's been a while.  I ended up being more interested in writing effects than doing fancy things with the display.

I definitely didn't try it with audio going thru the pedal so can't comment on the noise issue you're facing.

You should start a thread here on your build, I think the more people see how easy this device is to use the more hobbyists we'll see get into this.
Title: Re: Blackaddr/Teensy based pedal build
Post by: GuitarPhil on August 12, 2019, 12:14:58 PM
The OLED problem was in another project which didn't use BlackAddr's hardware. I've only recently acquired the TGA Pro and the Expansion board so just finding my way around that at the moment!

My first effort is a very basic simulation of a Meazzi Echomatic 2 drum echo from the 1960's as used by Hank Marvin of The Shadows!

I still need to add some EQ and try to simulate the wow and flutter and saturation of the magnetic media but I'm learning a lot along the way, albeit much more slowly than I could when I was a lot younger LOL