atsushieno / managed-midi

[Past project] Cross-platform MIDI processing library for mono and .NET (ALSA, CoreMIDI, Android, WinMM and UWP).
MIT License
195 stars 26 forks source link

MidiAccess inputs sometimes have incorrect devices #57

Open allendotson opened 5 years ago

allendotson commented 5 years ago

There is no recipe for this one. Sometimes the devices are right, sometimes they are wrong. If I run the program enough times, the correct devices will show up and connect.

I'm on macOS. Sometimes they just show up as Source0 and Source1. I am wondering if these names are gathered when the application is ran. I have tried resetting the MidiAccessManager on an interval to refresh the device IDs, but that didn't seem to work.

atsushieno commented 5 years ago

On which framework are you on? Xamarin.Mac, or other .NET desktop (mono net4x or netcoreapp) ? I'm asking because non-XamMac implementation is kind of hack that I wrote by myself to mimic XamMac API.

allendotson commented 5 years ago

Thank you for getting back to me. Actually, this is just a .NETCore console app. The only framework that is showing is "Microsoft.NETCore.App (3.0.0)". Tomorrow I am going to try to develop this in windows and see if I get the same result or not.

allendotson commented 5 years ago

You're right. The Xamarian one works flawlessly. I guess I will just learn this instead :-)

atsushieno commented 5 years ago

Cool. I just noticed that Xamarin.Mac.dll can be used on mono net4x environment https://docs.microsoft.com/en-us/xamarin/mac/app-fundamentals/console so I will be adding that support at some stage. It does not resolve your problem on .NET Core at all though :p