la-jarre-a-son / midi-jar

MIDI Jar is a tool box for musicians, learners, streamers, that want to route MIDI message between devices, and display a piano or chords while playing, and integrate it on a video or on a Twitch stream.

Home Page:http://midi-jar.ljas.fr/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MIDI Signals when triggered don't stop triggering when letting go of a key.

grantquo opened this issue · comments

OS: Windows
MIDI Controller: Novation Launchkey MK3 MINI (usb)

When my controller is connected to the chord monitor/display, it picks up incoming MIDI signals whenever I press a key correctly. However, it does not stop registering the key being pressed whenever I let go of the key. There is no sustain that should be whenever the key is being pressed. Whenever this happens, I can't get the chord monitor to clear and stop perceiving the keys as being pressed down unless I exit to the settings page and then click back to the display.
The debug text file shows that MIDI Jar keeps picking up some type of "undefined" signal constantly from the keyboad (even when inactive). And whenever I pressed a C, E, and G to make a chord a couple times it will emit an "on" for its signal but never an "off".
debug.txt

@grantquo Thanks a lot for your feedback, and for the debug file.

The timing clock messages are not an issue, we can just ignore them.
But... the issue is definitely the NOTE ON not having any NOTE OFF after release.
Even with a Sustain Pedal you would have those NOTE OFF messages after releasing the notes (only the DAW, or chord-display would consider the notes still playing until the pedal is released).

Did you ever had an issue when recording in a DAW - or is it just an issue you have with MIDI Jar ?

I am bugged with this bug, since i don't find any explaination why the note off message would not be sent wy a keyboard, and not received by MIDI Jar.

In fact, what i fear is, the bug is not in my code.
So it's either the Launchkey configuration/setup that is strange (or the hardware is failing), or it's the MIDI driver that is broken somehow... or the library that is responsible for the MIDI I/O that has some issue with it.

I'll try to dig into this.
If you are willing to help me exclude possible explanation, you could make sure that:

  • The Launchkey setup/configuration has not some strange setting
    • The arpeggiator feature must be disabled (MIDI Jar won't pickup arpegiatted chords anyway)
  • Your driver is up to date
  • Your Launchkey firmware is up-to-date

I'll try to find anything that could lead to NOTE_OFF messages not being handled.

Thanks again (and sorry that you experience this issue).

Also, could you check if you have the same issue with my previous project:
https://chord-display.rednet.io/

It's the same chord detection library, but i reworked the whole thing to make it more accurate (and maintainable).
It only works on Google Chrome (so WebMIDI instead of the MIDI Jar MIDI I/O library), and won't let you use some MIDI devices one multiple software (thus the rework as a standalone app with routing).

I looked into the device settings as best as I could through the Novation Components software that can access custom modes/scripts for the keyboard. So far as I've found, there isn't much of any settings that can be changed so it's doubtful that that is the problem. I found out I did have a firmware update due for the device, but after installing it, it's still doing the same thing in MIDI Jar. Drivers are up to date as well.

After looking at your web browser version of chord display, I noticed that it was working just fine with my keyboard. The highlighted notes whenever I pressed them would only be triggered when I held a note and wouldn't when I let go. The MIDI device that it was receiving from is the same MIDI device I am trying to route to MIDI Jar: "Launchkey Mini MK3 MIDI".

As far as DAW issues I haven't been having any problems with MIDI except for one thing that I think might be more of an FL Studio problem. I have been lately having this problem where whenever FL Studio has a change in MIDI devices connected, or boots up, I get this random, unnamed, blank MIDI output device that keeps trying to connect to the same port as my audio interface's MIDI port. And then until I turn the blank output device off and disconnect it from the "214" port, it will come up with this message saying "A device ID that has been used is out of range for your system."
I've been trying to tackle this problem for a while and have taken to forums seeing what's up, but haven't gotten a response/fix yet. Though since I read on your notice about Windows systems having trouble with multiple MIDI routes, I've tested out MIDI Jar handling my Launchkey without my DAW being open entirely.

Here's a screenshot of what I see on my MIDI settings regarding the random MIDI output:
FL64_M9w3Olx5Z6

@grantquo Thanks for your reply, and for having tested as much as possible any solution on your side.

Unfortunately, i starting to run out of explanation, if your sure that:

  • The arpeggiator is disabled on your Launchkey => it's not a strange hardware setup
  • Your firmware is up-to-date => it's not a hardware bug.
  • Chord-display works well => it should work the same with handling midi messages that are correctly received
  • Your DAW is disconnected => it's not a DAW side effect.

My last explanation is that the library i use has some bug on your OS, and that... i cannot even try to debug it without being able to reproduce.

Are you on Windows 10 ?

I tested MIDI Jar with no issue on many devices, on MacOS and Windows 10.

  • An AKAI MPK Mini (very similar to the Novation Launchkey Mini)
  • An Arturia KeyLab
  • FL studio plugged to MIDI Jar through loopMidi
  • rtpMidi session, with messages from a computer to another.

If i have a new idea, i'll try to ping here, but i have no clue why you would receive some MIDI message, but not others.

Concerning your DAW issues, i have a few remarks though:

  • Why do you need MIDI Out from FL studio ?
  • Is there anything plugged to your AudioBox midi out plug in the back of the sound card ?
  • Why do you send the Midi clock to it ? (the sync - Send master sync is checked on out AudioBox MIDI OUT)
  • Why such ports like 214 / 236 ? those are internal MIDI ports in FL Studio

If you want to output Midi message for instance, you would add a "MIDI OUT" Channel, so that your patterns will by outputted to the midi output designated by the port you chose (generally, you won't need more that 1 or 2 ports if you have physical synthetisers).
For instance, with loopMidi, you can have a MIDI OUT in FL studio that would send midi messages to a Loopback device, that can be routed to MIDI Jar's chord display.

I suggest that if you don't use MIDI OUT you just disable them in FL Studio (port set to "...").

For your blank Midi device, you may have a software that created it, or a bugged driver, i could not help you on that.
Sometimes starting from a fresh install can help you get rid of junk softwares (like the one that led you to have Waves SoundGrid...).

Sorry that you have these issues with MIDI Jar anyway.

If you are still searching for a solution to display chords, i can recommend you to check on https://chordieapp.com/.
This is a paid equivalent of the chord-display module of MIDI Jar, and you may not have the issues you have with my solution (can't know, i never tried it).

I am on Windows 10 so honestly I think that and a mix of weird MIDI drivers and stuff is causing the bug. The only trick is how I am going to tackle that.

As far as your questions with my MIDI settings, I never really mess with the ports on my MIDI devices, and it has been a while since I have got both my audio interface. So my best guess is FL Studio assigned those ports?...maybe? I've deactivated my MIDI stuff with my audio interface entirely since I use it primarily as a sound card.

Are there any suggestions for how I should set my MIDI settings overall? I think that running my FL Studio into MIDI Jar somehow would be the best approach for my setup. Since FL can definitely tell when I trigger and don't trigger a note, having it handle my MIDI messages from my Launchkey could be a good middle man before MIDI Jar starts its processes. How do you route your MIDI starting from keyboard to MIDI Jar using FL? I can try and recreate a similar setup on mine and see how that works. It would also be beneficial since the whole point of me wanting to use MIDI Jar is for the convenience of having a Chord Display on FL, since FL doesn't have it built in.

To route MIDI i use https://www.tobias-erichsen.de/software/loopmidi.html
It enabled creating multiple virtual devices, that can then be used by multiple softwares.
So MIDI Jar can act like a proxy (when working correclty) by connecting directly to my keyboard, and then forwarding it to as many virtual devices as i want (here, "Piano Out" is what i plug to any software, currentlly Kontakt is always running on my computer).

Here how you can MIDI OUT from FL studio to MIDI Jar:
image

  • DAW OUT is on port 1 and is a the virtual device (added in loopMIDI) that is routed to Chord-display
  • In FL Studio, i have a MIDI OUT configured on port 1, so that anything that plays on it is loopbacked into MIDI Jar.

For the example i created a Layer in FL, assigned to both MIDI OUT and on an FL Keys.
But since your keyboard is working, you can put a "Receives notes from..." your keyboard on multiple channels in your project, including the MIDI OUT so that you can also see your chords.

Since MIDI Jar is working for me, i routed my Keylab through MIDI Jar, to the virtual device "Piano Out" that is a Midi Input in FL.

But if you succeed to have MIDI Jar workin, normally, all you need is to Route your keyboard to a virtual device, so that you can always have the chord-display running (it's literally my Desktop Wallpaper), and the PIANO OUT useable in any software (multiple & you would never have to always change MIDI IN because of exclusive usage of midi inputs on Windows).

The FL Studio routing worked where I used the loopMIDI and Layer trick! The MIDI Jar stops registering my keys when I let go of them like it should. It's a couple extra steps to do to get it all working, but steps I am willing to take for it to at least work correctly. And I can get a set up going the layer and proper routing is in my default blank FLP.

Thanks so much for the help! I really appreciate it all and it goes a long way.

I'll close this issue since you found a solution.
Hope that it was an environment specific issue not related to MIDI Jar.