Can the Arduino Micro be configured as a USB MIDI host, or do I need a shield? I thought the ATmega32U4 could be a MIDI host or MIDI device
The ATmega32U4 is device-only. You'll need a different microcontroller, or mess with separate USB host chips/shields.
Thanks. I have to say that this really irks me, no fault of yours. The Micro marketing page says “… the ATmega32U4 has built-in USB communication, eliminating the need for a secondary processor.”
This lead me to believe that this board could do all the MIDI USB tasks.
Thanks for all your help. I’ll have to research a board that can act as a USB host.
I agree that the Micro page could be clearer, although the “Communication” FAQ section does mention
The chip also acts as a full speed USB 2.0 device
As a rule of thumb, if the documentation does not explicitly mention host support, assume that it doesn't support it.
A USB Host is significantly more involved than a USB Device: a host needs to drive all communication, parse descriptors, implement drivers for the different device classes, deal with USB hubs, etc., generally requiring a beefier chip with more memory.
Thanks for the info. Ug, I really didn’t want to get this deep I guess. I have a Source Audio C4 Synth pedal that has 128 presets. I want something simple to control it, but I guess it ain’t gonna be simple.
The Teensy 3.6 and Teensy 4.1 generally have good USB host support, and many MIDI devices just work out of the box. But you might want to search for your specific pedal on the PJRC forum before ordering.
Thanks again for your help and time!
Try getting one of these. You can buy it ready made or just the chip with the software on it and make it on your own strip board.
USB host MIDI to serial converter
Thanks a lot! So maybe my Arduino Micro is not a complete loss for this project? That would make me happy.
Absolutely.
I am assuming that your
Would normally plug into the sort of socket you find on a laptop and is sending MIDI messages.
It will not work if you are sending audio sounds.
Thanks! The pedal definitely receives MIDI, it’s how the myriad synth presets are created via a Mac or PC app.
OK, yes I downloaded bits of the manual, it seems to come in small bits for each preset. It looks like you would be good to go, I just wasn't sure how the sound got out of it. It looks like there is a mixer that takes two audio inputs and has two audio outputs, so I think it is MIDI driven.
What are you thinking of doing, making a stand alone system that will not involve a laptop is my guess.
That pedal can hold 128 presets, six can be accessed from the pedal. I’m building a simple MIDI host pedal to step through all 128 presets. There’s no other way to access those presets without a computer or phone connection.
I’ve got the Arduino built to do the step through, I now know I have to hook it into the host board (somehow!) to control the pedal.
Looking into this further and this video:
Seems like my Arduino MIDI controller can just plug into the host board, then connect a USB cable to the host board's ground, Rx and Tx. Sound right?
Hi!
I've put together a diagram because the people at Hobby Tronics didn't really understand what I was trying to do. Or maybe I can't explain it!
When you get a sec can you look at this and see if you think this will work?
Thanks!
Michael
Sorry but no.
It is all back to front.
The USB socket on the HobbyTron board should be connected to your effects peddle via a normal USB lead. Then the TX from it should be connected to the hardware RX of the Micro. With the RX from the HobyTron board connected to the hardware TX of the Micro.
Of course the grounds from HobyTron and Arduino must be connected together.
Now you have to consider how you are going to power this. Ultimately you want this to be stand alone so you will need an external 5V power supply. But just while you are developing the code it might be useful to connect the Arduino to a computer. This will allow the Arduino to supply the power and let you see anything your code prints for debugging purposes. So connect the 5Vpin on the Arduino to the 5V pin on the HobbyTron.
Note your code will receive and send the MIDI on Serial1, and set this up for MIDI speed.
You can view the results for debugging by using simply Serial at a fast speed. There is no need to make the Arduino look like a USB client.
A final word of caution, the HobbyTron produces its RX signal at 3V3, that should work but is slightly below what is needed. It could possible you will have to add buffer to boost up this signal. but we will worry about this later.
Hope that helps
Wow thanks. So this board WILL do what I need, I just have it entirely backwards?
The reason I thought this would work was because of this video…
Bitluni plugs a MIDI keyboard into the USB jack of the host board then connects the host board to a little synth. I saw my Arduino controller as the keyboard and the pedal as the synth.
Anyway thanks again. I’ll pick up one of these and try to steer clear of the magic smoke!
Don't know why, only watched the first few minutes but it looks entirely consistent with what I said.
No.
While the peddle does act as a synth it presents a USB MIDI interface to any computer it is connected to. The HobbyTron converts that interface into a logic level serial signal.
So
Yes.
YEAH!
Thanks again! I will post any successes.
BTW, I followed your suggestion about searching PJRC forums and there is a person who built a MIDI controller for the C4! It's on Teensy so I can't use it right now but there's still a lot of good information: