custom MIDI controller

Hello

I have decided to build mi own MIDI controller and may need some advice. I have not used arduino before and have very limited knowledge on electronics and coding, but I started by reading stuff on the web and watching some tutorial. At this stage I need to decide what board I need and it appears that arduino uno should be the best place to start. The midi controller I have in mind has the usual potentiometers and push buttons, but I also would like a dual encoder with push button. I would like the encoder to transmit different midi message depending on the way it is turned and whether the push button has been pressed. "for example ch 1 cc 1 if turned left / ch 1 cc2 if turned right, and once the push button has been pressed ch 1 cc3 if turned left / ch 1 cc 4 if turned right). being a dual encoder this means it would send 8 different midi messages.

I know that the arduino uno does not have USB MIDI out of the box but can be hacked to have this function. I also understand that if I add a wifi shield I could have the controller to communicate to my computer via wifi.

The question is: shall I go ahead and order an arduino uno - and possibly a wifi shield for this project or is there a better option? Also is there a specific dual encoder that I will need to purchase?

Many thanks!!!

Andrea

The UNO really isn't suited for this project. First things first, you can do MIDI over USB with the UNO, but it's a hack. It's really cumbersome, you have to flash the ATmega16U2 twice for each change you make, you can't program or debug while it has the MIDI firmware loaded, etc. Stay away from that, get an Arduino that has actual USB support, like the Leonardo. The UNO has only one hardware UART. It's used for programming, and for debugging, and for MIDI, and for communication with a WiFi shield. Of course, it can do only one thing at a time. On a Leonardo, programming, debugging and MIDI all happen over the USB connection, so you have the hardware UART free for WiFi stuff. An added benefit of the Leonardo is that it has 12 ADC channels (analog inputs), compared to only 6 on the UNO. For an encoder, it's a good idea to use interrupt capable pins. The UNO only has 2, so you can use 1 encoder. Polling will probably be fast enough, but it's just something to keep in mind if you have a lot of blocking code in your loop. Pin change interrupts could be used if necessary, but for now, let's assume that it won't be a problem.

Take a look at the Teensy boards, they're really great for building MIDI controllers. They do everything the Leonardo does, and even more, and all that better and faster, but at the same price.

If you want to send MIDI over WiFi, you probably need Apple RTP-MIDI. Your best option is probably to use a dedicated WiFi SoC like the ESP8266. (Look for a WeMos D1 mini development board or something similar.) It can be programmed using the Arduino IDE. This way, you can just keep the Arduino code, send the MIDI messages to the ESP, and let the ESP handle all WiFi and RTP stuff.

Some useful links: MIDI Controller library Arduino MIDI over USB support A Guide to Arduino MIDI Arduino AppleMIDI library A Beginner's Guide to the ESP8266

Pieter

Thank you very much Pieter! That was very helpful. I will have a look at the link you posted. I suppose I need to increase my knowledge quite a bit before I can tackle this challenge. I realise from your post that there were a number of issues I did not consider (i.e ability of arduino to communicate midi and wifi at the same time....).

I will do a bit more research on the boards you suggested!

Andrea