I’m a midi devotee (username makes that obvious I guess) and I’ve used about every style of controller out there on the consumer market. I’m hitting a point, though, where it might be worth investing the time to learn to make my own midi controller.
I’m sensing that I’ll need to go beyond the basic instructables I’ve found, which mostly suggest the pots-and-arcade-buttons-in-a-box kinda designs. I’m hoping for something just a tiny bit more ambitious, with velocity sensitive, silky drum pads (pads that feel like the QuNeo or the Maschine would be a dream) and a spring-loaded potentiometer that I move with my thumb (it’s a long story: basically I’m trying to design a thing that translates my nervous habit of one handed drumming into something that approximates a small drum kit). Given those ambitions, I’m anticipating that this is going to be a protracted learning experience.
I have the most scant of programming experience (like, I vaguely remember how to hand code html markup from my 1998 geocities days) and I have yet to totally wrap my head around navigating github. In terms of basic hardware tinkering, I have a soldering iron and maybe about 20 hours using it, max. But I can get around enough to, for instance, solder up my own guitar cables.
For those of you who have gone down this road, what are the best sources you’ve found for figuring out arduino (which I’m guessing is what I’ll probably use, right?), figuring out the best way to source parts in small batches, figuring out whether or not FSRs are the way to go for drum pads, etc.?
For DIY MIDI controllers, I greatly like the Teensy - you can write in the Arduino IDE for it, it behaves out-of-the-box as a USB HID device, and there’s good sample code available. I’ve made some foot controllers with it. It has lots of digital pins and enough analog ins for most purposes.
Sourcing parts in small batches: well, go to people who’ll sell them in small batches - in the US, Sparkfun/Adafruit/Small Bear, for instance. Beyond them, Digikey/Mouser/Farnell and so forth, though be wary of minimum quantities.
For spring loaded pots, remember that the “spring-loaded” element can be totally separate to the actual pot. For instance, a pitch bend wheel might be a spring-loaded lever (mechanical engineering) promptly connected to a fairly regular potentiometer. Or it could be an all-in-one thing. But you have flexibility there.
Pads are complex, though again, you’re perhaps looking to go down a route of separating out pad design/material from the way the pad is detected. I’ve used FSRs that are very sensitive, but also very, very expensive; the trick will be finding the sweet spot of price / implementation / feel.
Yeah, Teensy seems to be the popular choice for DIY MIDI.
I only built one mini FSR controller way back at the start of grad school, but it was insanely easy. I used an Arduino Uno back then, and it was pretty plug-and-play. The hardest part would likely be building the case, honestly. It was literally two of these plugged into an Arduino:
Back then, I had to use PD to convert the Arduino messages to MIDI. Nowadays, the Teensy (and some of the Arduinos) can do MIDI-over-USB out of the box.
Speaking of which, the Axoloti is another great way to go. It’s fairly cheap, and it comes with a lot of the stuff that you would typically want for audio and MIDI (USB over MIDI, 5-pin ports, etc.). On top of that, there are a lot of modules in the User Library that can be used to create very complex MIDI behavior, like holding a button to activate an arpeggiator or trigger pattern. http://www.axoloti.com/
(Plus, you could upload a patch that keeps all of the MIDI functionality while simultaneously generating audio on the outputs…)
You don’t necessarily need to use Tom’s AxoControl, either. You could build your own control scheme and enclosure. The great thing is that Tom’s project is totally open source, so it at least gives you a map.
Thanks for these links! I love hearing from people who were vary much beginners when they got into this. The pics are great. I might hit you up as I move forward!
Aside from hardware, you’ll also need programming skills. The two books I read to begin with were Accelerated C++ by Koenig and Moo, as well as The AVR Microcontroller and Embedded Systems by Mazidi et al. I really enjoyed the hands on approach of the former book (write as much code as possible while reading the book and make it run if you can). The latter book includes a lot of general information about computers, and mostly uses AVR assembly language for the examples. I actually found this extremely useful, as it really solidified my understanding of how computers work and what they are capable of doing. Even as a beginner (maybe especially as a beginner) I think learning a little bit about assembly language is worth while, even if you never actually write any of it. A book on ARM might be more useful than one on AVR though; ARM is a lot more powerful, and is what’s used in e.g. more modern Teensy boards, Axoloti, Raspberry Pi, many Mutable Instruments modules, and surely many other examples.
After reading these books and making some simple and some not so simple projects I started reading the source code for the Arduino libraries, which I highly recommend doing at some point of you use Arduino a lot.
+1 for Teensy; the built in USB MIDI capabilities are stupendous for making a DIY MIDI controller, and the documentation on the Teensy website is pretty good.
That’s all quite helpful and I’ll definitely take note of those books as good resources for coming to terms with c++
How much of that is really needed to make a midi controller with teensy, though?
I’m all for learning things the “hard way”: if someone asked me how I learned to learn produce electronic music, I’d tell them that it’s been a long journey of listening to everything I could get my hands on, brushing up on my music theory, practicing drumming, learning midi, muddling through a bit of reaktor, and getting to know Ableton like it’s my life partner, more or less.
But to get them started and fuel their excitement, I could also direct them to a handful of iOS apps and, with some creativity, they could make something pretty decent without learning how to, say, do crazy midi routings in Ableton.
So while I support the deep dive into c++ and assembly language, can I get some serviceable results by struggling through the Teensy documentation, cribbing some code, and trial and error?
In my day job i’m working on a PhD, so while re-teaching myself recursion and while loops would be a great way to procrastinate the thesis, I’m not sure I want to open up the procrastination can THAT widely just to make a custom drum controller…
Yes. The Instructable tutorials feature most of the code that you need, which consists of polling the various pot/sensor inputs.
More advanced topics…
-Keeping track of endless potentiometers. You’ll receive deltas instead of direct values.
-Filtering noise from analog inputs. This is typically not much of a problem with low-resolution MIDI controllers, though.
-Notes instead of CC values. With notes, you have to make sure that Note On and Note Off messages are kept track of, or else you’ll get hanging notes.
-Bluetooth/wireless performance (if desired)
Hey @midilifestyle! If you’ve never done much programming before, a good place to start to start is Learn Python the Hard Way (https://learnpythonthehardway.org). There’s other getting started for a total newbie type of e-books out there, just Google: Learn [insert language here] the Hard Way. I don’t know much Python myself, but developers I know seem to think it’s a good language. It’s supposedly simple to pick up too. Arduino uses some kind of abstraction of C/C++, and there is a Learn C the Hard Way out there if you want as well.
Basically what I’m getting at is these types of e-books / guides are good for beginners because they make no assumptions about your skillset. This can be annoying for anyone with coding experience, because they go as far as walking you through every banal activity, like having you download and install a text editor.
Good luck! I tried learning to build a MIDI foot controller for my guitar once, but lost interest in that project: http://blog.welense.com/1075842
Teensy/*duino code isn’t C++, it’s at best a subset of common old C. You don’t need to learn assembly right now. These things will still be there for you later if you’re interested. But I think at a sensitive time in anyone’s experience of programming, recommending assembler is… risky, to say the least. You might find that if you start by thinking-through-playing, you’ll join up with the other train of thought in the middle.
For now, you’re fine. Depending on how far you go, you might need to return to these.
Starting with some assembly worked well for me, but I can definitely understand why that might not be the case for everyone. If you prefer your trial by a different kind of fire (I like mine particularly hot), you can definitely dive in and achieve good results very quickly with Teensy. Most of what you might need to know to make many kinds of MIDI controllers is contained in the first two example files located at File Menu>Examples>Teensy>USB MIDI in the Arduino IDE after you install the Teensy add on.
If you’re specifically interested in making a drum controller, you might be interested in the open source firmware for the Linnstrument. The velocity calculation is done in ls_touchInfo.ino calcVelocity(), and the author explains the algorithm in plain language in the latest (bottom) post on this topic on the Linn Design forum.
I’m looking for solutions to build custom MIDI controllers that would include:
one or more buttons/LED grids (my current needs are one 8x8 and one 4x4),
encoders,
potentiometers.
All of these controls would be connected to a computer via a single USB cable.
Until today, for these needs I have mostly used the Elements and Builder systems from Livid Instruments, which have never failed me.
Unfortunately, since Livid is no longer in business and spare parts are becoming hard to find (Brain V2, Elements modules and Omni / Omni RGB Boards), it seems that I need to find another solution if I want my system to be “future proof”.
So I’m looking for all kinds of boards/kits/platforms that could achieve similar goals as those easily achieved with Livid Instruments’ systems.
Raspberry Pi and Arduino are probably the first platforms to explore, but will very likely require a lot more work than just soldering a few semiconductors and electromechanical components.
For the buttons/LED grids, I looked at the ones from Neotrellis, but the buttons are too small for my needs. I wonder if larger buttons (a la Launchpad MK1 / MK2) can be purchased in small quantities.
Thanks for the suggestion. I’ve never had a look at the Teensy, it seems like it might be the right time!
After exploring the previous posts in the current thread, it appears to be a popular solution for these types of applications.
Also, as I continued my research I discovered the OpenDeck platform from Shantea Controls: https://shanteacontrols.com/
I wonder if the combination of existing buttons / LEDs grids (mostly, LaunchPad from previous generations) and a platform that can accommodate other electromechanical components would be better than an all-DIY solution, in terms of labour time and overall cost.
(I also like the idea of giving a new use to an easy to find device on the second hand market, already considered obsolete.)
i recently went down the rabbit hole of diy midi controllers aswell, and will probably use this library in the end: Control Surface: Control Surface
works with most arduino, and seems to be pretty easy to set up.
using an old launchpad also sounds interesting, but not quite sure how you would integrate that with other control elements in a way that makes it appear as one device? but on the other hand is that even necessary?
Encoders and pots are straightforward on the Teensy. The 3.6 especially has loads of pins and ADC channels.
Personally, I made a commitment to myself this time last year to stop making custom hardware for as long as possible (using off the shelf stuff instead) and unfortunately I’m much happier for it.
I’ve been looking at the Pedalino Mini open source foot controller platform recently. Posted about it here, but it should probably be moved to this thread.
This looks like a great resource when using an Arduino!
Neat and effective. Thank you for the link.
I think there is a start of a solution here:
This would allow to use only one USB port on the computer, possibly making the use of a hub unnecessary.
However, if it’s technically too complex / cumbersome / a possible source of problems, I’ll have to abandon this idea.
Good to hear, that’s a hopeful statement!
I can understand that.
Time is precious.
I myself am willing to use anything that precisely fits my needs (kind of).
If nothing exists that is exactly what I need, then I have to build it or modify something that comes close enough (and can be modified easily).
I saw this in the other thread and am very interested… though this will have to wait until other, higher priority devices have been completed!