Reading And Decoding USB MIDI Messages With An Arduino

Поделиться
HTML-код
  • Опубликовано: 15 янв 2025

Комментарии • 24

  • @MMMMMMMMMMBALLS
    @MMMMMMMMMMBALLS 6 месяцев назад +1

    The first and only in depth vid on this topic. THANKS!

    • @eleneasy
      @eleneasy  6 месяцев назад

      You are very welcome.

    • @eleneasy
      @eleneasy  6 месяцев назад

      You are very welcome

  • @wonkastudio-johnny
    @wonkastudio-johnny День назад

    hello, do you have the sketch for this somewhere for download ??

    • @eleneasy
      @eleneasy  13 часов назад

      Certainly. Sorry if the content of the video was not clear enough to get the sketch. Please follow the following link and download the latest archive. In there, you will find a folder related to the MIDI module. You can use the whole content of the folder as a reference for this video. It is not exactly this video contents, but it is actually even more detailed, since it is part of my analog synth project. eleneasy.com/the-analog-synthesizer-project/

  • @nimaesmaeil9318
    @nimaesmaeil9318 11 месяцев назад +1

    Thanks ❤

  • @oflittleconsequence
    @oflittleconsequence 7 месяцев назад +1

    Fantastic video. Thank you for the in-depth information. Is there a way you know of to poll or query a MIDI device to find out the current value of a specific control parameter?
    I would like to build a controller that has some kind of feedback mechanism to not just capture and show CC messages to change a parameter value, but be able to read what a value is set at, so I can show the value on a meter/lights/OLED scribble strip, or whatever element, before it is changed.
    Imagine a controller that has rotary encoders and multiple banks... When I change the bank, I would need the display value to change to reflect the set value of what those encoders are assigned to now.

    • @eleneasy
      @eleneasy  7 месяцев назад +2

      Hi "oflittleconsequence". The MIDI 1.0 specification doesn't have a built-in mechanism to directly retrieve the value of a parameter from one device to another. It's designed primarily for sending control messages that trigger actions or set specific values, not for querying information.
      The only workaround that I can think of to solve your problem, is to store in the controller memory the value of every parameter that has been changed. And this can be done with a separate block of memory for each bank. This way, when you switch bank, rather than retrieving the info from the other MIDI device, you would retrieve the information locally, from the memory block of the controller itself used for that bank.

    • @oflittleconsequence
      @oflittleconsequence 7 месяцев назад

      Thanks for your quick response!
      Is there some way to poll all the parameters at once, so I can "initialize" the controller by parsing through that dump and reading it all into memory when it is first connected?

    • @eleneasy
      @eleneasy  7 месяцев назад +2

      Unfortunately, no. The only thing you can do is to store locally a parameter every time you change it. That way, when you move to another bank and then you come back, all the parameters you previously changed are already available in memory. But it is not possible to query the device you are connecting to for reading the parameters already set in there.

  • @poupdujour
    @poupdujour 2 месяца назад

    Great video. I want to use this as an interpreter to read midi signals but would also be interested in using this to pass what it reads through to another midi receiver, possibly modifying what comes out to another key. Do you think that would be possible?

    • @eleneasy
      @eleneasy  2 месяца назад

      Certainly. The Arduino DUE should be perfect for that. You can use the USB port on the Host shield 2.0 from the video as MIDI input and the native USB of the Arduino DUE as MIDI out. Since the MIDI out work as a device, not as a host, it is possible to use the DUE native port. Also the native port and the port on the shield can be used simultaneously, so one single Arduino DUE and one USB host shield put together can do exactly what you need.

  • @shidqi100
    @shidqi100 9 месяцев назад

    Great video dude, had a few question though. In this video you're using adruino due because it has feature USB port as Host so other adruino boards such as uno, mega, etc can't read and decode USB Midi Messages? as context I want to build digital piano using adruino and I'm really new to adruino

    • @eleneasy
      @eleneasy  9 месяцев назад +1

      Hi! I am using Arduino DUE because it has two USB ports, one of which, the so-called native port, I can use in the future to add new features to the MIDI module. The Host USB is provided by the USB Host Shield, not the Arduino DUE. The Arduino DUE does not have this capability, as far as I was able to discover.
      However, I decided to use the Arduino DUE also for other reasons: its speed (84MHz clock), its big amount of memory, and the availability of several I/O ports, both digital and analog.

  • @nimaesmaeil9318
    @nimaesmaeil9318 11 месяцев назад

    14:40

  • @Gratiman
    @Gratiman 9 месяцев назад

    This cant be done without the shield?

    • @eleneasy
      @eleneasy  9 месяцев назад

      Unfortunately not. The native usb port works only as device, not as host, as far as I was able to figure out.

    • @Gratiman
      @Gratiman 9 месяцев назад

      @@eleneasy thank you

  • @minkloco619
    @minkloco619 10 месяцев назад

    What arduino is best for this?

    • @eleneasy
      @eleneasy  10 месяцев назад +1

      The one tha worked for me was the Arduino DUE.

    • @minkloco619
      @minkloco619 10 месяцев назад

      Thanks 🙏🏾 Can I get the data to display on a 1602 lcd from Logic Pro X?

    • @eleneasy
      @eleneasy  10 месяцев назад +1

      Unfortunately the 1602 is not directly compatible with the arduino due. The arduino due has a logic running at 3.3V, while the 1602 works at 5V. I am currently working on a solution to make the two circuits work together. Stay tuned. A video on that will come out soon.

    • @minkloco619
      @minkloco619 10 месяцев назад

      Thanks I’m trying to build a drum machine midi controller with 8 faders 8 drum pads and a 1602 lcd. I’m trying to figure it out

    • @eleneasy
      @eleneasy  10 месяцев назад +1

      If that is your intent, probably you can try using the Arduino Mega, or even the Arduino UNO, if it has enough programming memory in it for you. They are both compatible with the 1602. My choice of the Arduino DUE was because it is the only way to use the USB port as Host, as far I was able to figure out. But since you are making a controller, you will use the USB port as a device, not host, so you should be able to use any Arduino that ha a 5V logic and, therefore, compatible with the 1602.