UKBouldering.com

Arduinoesque solution to building a MIDI controller (Read 3977 times)

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
Is it a fair assumption to guess some users here will be electronically tech savvy in the use of Arduino and other such systems?

I really want to create a custom rotary MIDI controller with 32 knobs but am struggling to find many sites detailing the make up of such a device with UK-based component suppliers. Given my scant knowledge of electrical engineering, is this too ambitious a project to have?

Basically, this is exactly the look and feel that I'd like to emulate:

http://diyproaudio.blogspot.co.uk/2014/01/how-to-build-midi-controller-diy.html

Thanks in advance!

nik at work

Offline
  • *****
  • forum hero
  • Posts: 3589
  • Karma: +312/-2
I don't really know what a MIDI controller is but arduino is very easy to pick up the basics. I've done a couple of reasonably complex control system projects for bespoke installations and they were the first things I made with arduino beyond the "I've turned on an LED check me out" first go everyone has.
So I would say it's probably worth having a go, even if it doesn't work if you're "that" type of person you'll probably enjoy it.

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
Thanks Nik, you have me intrigued! Basically the controller is used to alter a variety of parameters in music production software. I'm currently using two separate ones but fell in love with the aesthetics of the one shown in the link. Reminds me a bit of the MasterSounds Radius 4 analogue rotary mixer. Weird that there seem to be so few (if any) digital controllers with a similar aesthetic.

This site is exactly what you'd need to get all the components! https://www.mouser.co.uk/ProductDetail/TE-Connectivity-Alcoswitch/PKES60B1-4/?qs=sGAEpiMZZMuiwDVLTMm01RBF36R1YJ5gyGD943vIllk%3d

That's even the knob from the Radius I think.

 

Serpico

Offline
  • *****
  • forum hero
  • Posts: 1229
  • Karma: +106/-1
    • The Craig Y Longridge Wiki
I built a 10 button Arduino midi footswitch. Actually building the thing is easy, the difficult bit is writing the code to load onto it; it took an epic amount of searching to find something that was close enough to what I wanted to achieve for me to modify with my limited coding skills.
My advice would be to source and understand the code first before investing in the bits.
For the Arduino board I bought a £5 copy from eBay which works fine.

danm

Offline
  • ****
  • junky
  • Posts: 829
  • Karma: +112/-1
Proper geeks live code by typing in command lines, just sayin'.

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
I built a 10 button Arduino midi footswitch. Actually building the thing is easy, the difficult bit is writing the code to load onto it; it took an epic amount of searching to find something that was close enough to what I wanted to achieve for me to modify with my limited coding skills.
My advice would be to source and understand the code first before investing in the bits.
For the Arduino board I bought a £5 copy from eBay which works fine.

Cheers Serpico. There seems to be a fair amount of code out there for simple rotary controllers and I wonder if it'll be fairly simple to edit it to cater for extra knobs. Liverpool (where I live) has quite a big maker community so perhaps it'd be worth popping down there to mingle.

nik at work

Offline
  • *****
  • forum hero
  • Posts: 3589
  • Karma: +312/-2
I'm at home now on the laptop (rather than the phone) so have read through the article you linked to. I'm still largely unsure of what a MIDI controller actually does in terms of what it interacts with at the "other side". I.e. the Pots will change as you twist 'em, the arduino will process this in some way and spit out some bleurgh to something else, I have no idea what this bleurgh needs to be or what it needs to be sent to. Don't worry you don't need to explain, I am happy in my ignorance. Just be aware that the following is written with this lack of knowledge.

As Serpico says making a circuit is pretty easy, and conecting up an Arduino board to it is also pretty straightforward (use a shield and it's even easier). Just make sure you're aware of things like pull-up and pull-down resistors, smoothing capacitors, getting everything grounded that needs to be etc. Frying components is aledgedly easy to do, I've never managed it though (that is not a claim of great skill on my part, more blind luck) luckily they are generally pretty cheap. Also be good at soldering. Looking at the number of inputs your after I'm guessing you'll need an Arduino Mega (you can get a non-original for ~£10 on amazon).

Programming an Arduino is also pretty straightforward, certainly for simple if input A is value y make output B value z type stuff. Although as with all things it can get significantly more complicated. Without knowing what you need the Arduino to do in terms of processing I can't really add specific advice, but the idea of chatting to a friendly local group of geeks is a good 'un.

Boring "look at MEEEEEE" bit...
NSFW  :
If you're interested this is the project that is the first time I used Arduino (in the interests of full disclosure I have had some experience of web-development style programming back in the day so was slightly au-fait with generalised programming syntax/methods but it genuinely isn't that complicated, it's essentially all 1's and 0's)

The project I did using Arduinos grew over time. Initially it was going to be a controller for a "periscope" installed in a new build that was going to control a rooftop camera with left and right buttons on the periscope. So far so simple. Then I had a meeting with the client and we got all excited and came up with a couple of features to add:
The periscope eyepiece needs to move up and down.
It needs some lighting.

So the periscope was redesigned so the eye-piece could move up and down, and I chucked in some electric motors to give a "power-assist" lift and automatic down when the handles are released. And I stuck a ring of LED's round the main body of the periscope and a vertical strip of LED's up the side. All controlled by the Arduino. Then the client and I decided to jazz it up a bit...

So when the handles are released the motors lowers the periscope fully and when the periscope is fully down the LED's glow "dim white". When the handles are lifted the arduino reverses the motors and gives a "power assist" lift to the periscope eyepiece and the LED's change from dim white to Blue.

Then I thought it needed a bit more Funk...
So I put an ultra-sonic distance module inside the body of the periscope that could work out the height of the eyepiece by measuring how far away the counterweight was (there had to be a counterweight as the whole eyepiece assembly was about 60kg) and then mapped that height onto the vertical LED's so a section of the vertical LED's would be blue representing the height of the eyepiece and the rest would be dim white. As the eyepiece moves up and down the blue section also proportionally moves up and down. And I added a theatre chase tot he horizontal ring of LED's, so when the move camera left button was pressed on the handle the LED's would "chase" leftwards and when the move camera right button was pressed the LED's would chase "rightwards". I thought this was the end...

Then the client wanted some outside signage with lighting...
But they wanted the lighting to be colour controllable...
Oh and they wanted the lighting on either side of a glass atrium, which at this stage of the build meant there was no physical way of connecting the wiring of the two sets of lights...
And they wanted a central control panel...
Which could also not have any direct physical wiring connection with either set of lights...

So I built an arduino based wireless lighting slave box for each of the sets of lights and a wireless master control box (with colour touch screen, schwing) to control the colour/pattern/etc of the lights...

And then the client said "could we adjust the colour of the periscope LED's from here as well?"

And (after a bit of head scratching) yes, yes they can.

This is the periscope:



cheque

Offline
  • *****
  • forum hero
  • Posts: 3395
  • Karma: +523/-2
    • Cheque Pictures
Actually building the thing is easy, the difficult bit is writing the code to load onto it;

 :agree: Not that I have any experience of the software bit, but the analogue building and soldering is pretty straightforward if you're determined enough. Particularly if you can solder already. If you can't then you need to know that you'll need either a temperature controlled soldering iron with different bits or a big hot iron and a small cooler one as soldering wires onto pots etc. and soldering onto PCBs need different tools.

If I was building a MIDI controller I'd use digital pots that just rotate endlessly (I think the term is rotary encoder, a bit of Googling reveals that there are, predictably, many different types of how they work) which would probably make it more expensive and complicated but would be way better.

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
Thanks all. My main concern is that while I'm willing to learn and get stuck in, I might very end up with a load of components and no controller (less dosh too!). Going to meet some local heads is probably my first port of call I suspect.

Serpico

Offline
  • *****
  • forum hero
  • Posts: 1229
  • Karma: +106/-1
    • The Craig Y Longridge Wiki
As much as I enjoy making things if I wanted a multiple rotary control surface I'd just buy a behringer bcr2000.

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
I hear you Serpico and that's the obvious logic that I should follow. The irritating aesthete within is the only thing motivating me. Wish I could shut him up!

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
P.S. Nik, you hustler! That's not exactly a chicken thermometer you've built is it!? Who lives in a house like that, Goldfinger!? Fine work!

nik at work

Offline
  • *****
  • forum hero
  • Posts: 3589
  • Karma: +312/-2
Cheers beast, it's the new head office for Microgaming, a big online "gaming" company (gaming = gambling).

Monolith

Offline
  • *****
  • forum hero
  • Straight outta Cronton.
  • Posts: 3955
  • Karma: +218/-6
Fine work Nik!

An aside, but are there any modular synthesizer enthusiasts here? I've started to explore Euroracks and the principles behind their operation. Looks like it becomes a costly interest for some but VCV Rack is a nice Opensource software solution:

https://vcvrack.com/

Version 5 out today and an Ableton VST plugin bridge due at the end of this month.

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal