Author Topic: Impulse response player/hardware  (Read 13274 times)

MetalGuy

Impulse response player/hardware
« on: May 14, 2016, 04:09:40 PM »
Someone please explain (or provide links) what does it take to build a standalone impulse response player like this one for example:

http://www.thomann.de/gb/amt_pangaea_cp_100.htm

This is a gutshot (I can see an STM32 ARM Cortex MCU and an ANALOG DSP?):

https://fbcdn-sphotos-g-a.akamaihd.net/hphotos-ak-xpa1/t31.0-8/10942326_865322753510008_5707148019255959078_o.jpg


I did some search in the net however except few RPi projects with terrible latency I couldn't find anything else similar.
And let's keep it simple. What I need is to be able to load a certain number of impulses and choose one of them.
Thanks.
« Last Edit: May 14, 2016, 04:40:22 PM by MetalGuy »

markseel

Re: Impulse response player/hardware
« Reply #1 on: May 15, 2016, 11:51:42 PM »
I'm building one now with 50 ms of IR capability (at 48 kHz), USB audio class 2.0 for direct in recording, single guitar input, stereo line level output, EQ, and USB MIDI for IR loading (like on the Axe FX). All DSP is performed on the board for ultra low latency.  No user interface - I figure one could use a raspberry pi or something like that for user interfacing.  Any reason why you want to build your own rather the buy the unit you referred to in your post?
« Last Edit: May 15, 2016, 11:53:30 PM by markseel »

MetalGuy

Re: Impulse response player/hardware
« Reply #2 on: May 16, 2016, 03:58:59 PM »
One of the reasons is to learn something more about this the other is I'm building a reactive load attenuator/load box and I thought such device would be a nice feature.
Could you explain briefly (if possible) how the whole thing works?

markseel

Re: Impulse response player/hardware
« Reply #3 on: May 16, 2016, 07:55:15 PM »
Do you how do IR's work (i.e. how are they created and how are they used to simulate a system response) or how does my board work?

http://wiki.fractalaudio.com/axefx2/index.php?title=Impulse_Responses_(IRs)
http://wiki.fractalaudio.com/gen1/index.php?title=Axe-Fx_SysEx_Documentation&oldid=3738#MIDI_SET_IMPULSE_RESPONSE

My board does the following: When plugged into a USB host (Mac, PC, raspberry pi, etc.) enumerates as a USB audio class 2.0 device (stereo record and playback at 192 kHz) and also enumerates as a USB MIDI device.  Accepts midi data via USB using the standard USB/MIDI class.  Accepts MIDI commands (via USB MIDI) to set cab sim FIR coefficients (with the impulse response data), equalizer settings, and audio routing configuration.  Supports mixing of ADC (guitar input) samples and USB audio samples before being sent to cabinet simulator (IR).  Supports mixing or USB audio samples and cabinet sim output before being sent to the DAC (line out) so you can 'play' along with audio from USB host.  Supports recording either ADC (guitar) input or cab sim output via USB audio.  Has 192 kHz audio ADC/DAC for guitar input and line outputs.  Down/up samples 192 kHz to/from 48 kHz before and after cab simulation (FIR with coefficients set to IR response). One could play guitar through effects (stomp boxes or multi-effects unit) and then use this board and a powered monitor or PA as the 'amp' while recording. 

Digital Larry

Re: Impulse response player/hardware
« Reply #4 on: May 17, 2016, 09:16:44 AM »
Mark are you doing this just for fun, or looking to shop it to someone, or ... ?  Built on Xmos?

rgds,

DL
Digital Larry
DSP tinkerer and former transistor twister

markseel

Re: Impulse response player/hardware
« Reply #5 on: May 17, 2016, 11:00:47 AM »
Hi DL.  Wanted it for myself then thought it would make a good foundation for a USB/MIDI controlled effects pedal since the board is the same (XMOS, USB, ADC, DAC) for cab sim or effect - accept for the analog output circuitry which would be line-level for the cab sim and instrument level for the effects.  Would love to turn this into a product and I'll probably try that at some point after bugs are worked out.  Yes it uses XMOS - I benchmarked the FIR for 32/64-bit fixed point and have enough compute to do 50 msec of IR (2400 tap FIR at 48K Fs) while still supporting stereo EQ, input/output mixing, USB and MIDI.  I'm open to making a few extra boards for minimal cost (cost of parts) for those who want to add value in some way - provide feedback or create PC / USB host SW for loading IR data (Axe FX MIDI format or WAVe file) over USB MIDI.  There's really not much to the board since the XMOS part (16 cores, 8 of which are used for DSP) handle both USB and DSP tasks - no other MCU needed.  I added a AK4556 CODEC, oscillator, and analog input/output circuitry. So should be easy to make and relatively inexpensive.  The board is designed to be placed in a 1550P size case: http://www.ebay.com/itm/Alpinetech-P-CNC-Milled-Aluminum-Enclosure-1550P-Box-Mod-Hidden-Magnet-Holes-/221896756673

MetalGuy

Re: Impulse response player/hardware
« Reply #6 on: May 17, 2016, 04:01:17 PM »
Sounds like a very useful project. I would be interested in an unboxed board but as user not developer.

markseel

Re: Impulse response player/hardware
« Reply #7 on: May 17, 2016, 06:27:44 PM »
OK MetalGuy - I'll ship you one when ready.  Might be a month or two until then though.  I'll have a way to push IR data to it via USB but it won't be very fancy.  There's a lot of cabinet simulation IR's (for free and for $) out there so this will be interesting :-)

MetalGuy

Re: Impulse response player/hardware
« Reply #8 on: May 18, 2016, 04:29:13 AM »
As I already mentioned I need it simple - to be able to load IRs via USB and use it as a cabinet simulator in addition to my reactive load.

Quote
I'm building one now with 50 ms of IR capability (at 48 kHz)...

I guess this is not the latency while playing?

markseel

Re: Impulse response player/hardware
« Reply #9 on: May 18, 2016, 08:53:39 PM »
50 msec is the duration of the impulse response.  Input to output audio latency is around 1 msec.

Digital Larry

Re: Impulse response player/hardware
« Reply #10 on: May 19, 2016, 10:20:06 AM »
Mark it sounds really cool.  I'd love to assist but I'm already neck deep in real work and side projects and pie in the sky and so on.  Keep us posted!

DL
Digital Larry
DSP tinkerer and former transistor twister

markseel

Re: Impulse response player/hardware
« Reply #11 on: May 19, 2016, 11:13:58 AM »
OK DL.  This board could be used as an effects processor too.  Lots of DSP - two to three times a Cortex M4 and about half of a SHARC - so plenty for preamp and amp modeling (overdrive, distortion, chorus, EQ, phasing, etc).  I was thinking of putting together a programming framework that just requires the programmer to implement DSP stuff (hiding the USB, MIDI, ADC/DAC control, and up/downsampling and data flow details).  An effects API of sorts.  Each board has audio in and out but there's no parameter/bypass controls on this board - just analog audio, USB audio and USB MIDI.  So one could plug a bunch of these boards into a USB hub and control all of them via MIDI.  Someone could build a controller out of a raspberry pi that senses pots and foot switches and controls multiple effects boxes via MIDI commands generate from pot or foot-switch changes.  For me I'll look to use one box for cabinet simulation and output to a mixing console or powered monitors, one box for effects, and my PC controlling them via USB/MIDI.

markseel

Re: Impulse response player/hardware
« Reply #12 on: May 20, 2016, 11:15:00 PM »
Here's the board so far minus ESD protection on the USB D+/D-/Vbus signals.  This board supports up to two processors and two USB connectors although only one of each needs to be populated for it to work.  A single processor can perform USB audio, USB MIDI, EQ, and IR processing for 50 msec of cabinet simulation.  Two processors yields 2000 MIPs - a lot of processing power - and would support all features (USB audio/MIDI, cab sim, EQ, mixing, plus audio/guitar effects) on a single board.  Two USB's allow for flexibility; for example power and USB audio on the left connector and separate USB MIDI on the right - so the audio host (a PC, mixer, DI or DAW for recording) and the MIDI controller (cab sim and audio effects control via a Raspberry Pi or Arduino) can be separate units.  Both USB's can support audio and or MIDI depending on how the processors are programmed but power must be supplied using the left connector.


Ice-9

Re: Impulse response player/hardware
« Reply #13 on: May 21, 2016, 05:33:16 PM »
Wow, Mark this looks pretty damn impressive. I will be watching this thread to see how you progress.
www.stanleyfx.co.uk

It's fairly straight forward, if you want to start it , press start. You can work out the rest of the controls for yourself !

markseel


MetalGuy

Re: Impulse response player/hardware
« Reply #15 on: May 22, 2016, 02:14:10 PM »
How do you power the unit when the USB port/s are not in use (for example when it's on your pedalboard for a live gig)?

markseel

Re: Impulse response player/hardware
« Reply #16 on: May 22, 2016, 02:39:47 PM »
http://www.cablestogo.com/product/22335/ac-to-usb-mobile-device-charger-5v-2a-output?utm_source=Google&utm_medium=Shopping&utm_campaign=SEM&gclid=CM2hheKn7swCFVE0aQodiWIDEA

or via a powered USB hub.

Being USB powered would be more convenient for home use (just plug it into the PC or laptop).  But maybe I could replace one of the USB connectors with a standard 9V power jack.  But then you'd always have to use the 9V adapter regardless USB connection.  A 9V source would likely be cleaner than USB power (for powering the analog and ADC/DAC section) so that'd be a plus.

Thoughts welcome :-)

Digital Larry

Re: Impulse response player/hardware
« Reply #17 on: May 22, 2016, 03:07:50 PM »
My FV-1 dev board is way cleaner on a 9V wall wart than power over USB.  So I vote for external power.
Digital Larry
DSP tinkerer and former transistor twister

markseel

Re: Impulse response player/hardware
« Reply #18 on: May 24, 2016, 10:16:53 PM »
It's now designed to be powered from 9V.  Removed one USB connector to make room for a panel mounted 9V power jack.  Reworked the other power supplies/regulators accordingly.


markseel

Re: Impulse response player/hardware
« Reply #19 on: May 25, 2016, 04:22:19 PM »
Hmm I wonder if I should add a MIDI jack to this (even though it already supports USB MIDI).  Then it could be controlled by MIDI controllers.  Thought of this after seeing this post: http://www.diystompboxes.com/smfforum/index.php?topic=112424.0.  Would bump the board up in size from a 1550P case to 1590B case - seems like no big deal though.  These cases are really nice: http://www.ebay.com/itm/like/221917939717?lpid=82&chn=ps&ul_noapp=true