Fix #37 Flapi not working on MacOS (ports specifically)#49
Open
gavin2059 wants to merge 2 commits into
Open
Conversation
Owner
|
Thanks so much for this contribution! My main concern is that this may (further) break the logic for the Windows side of things. I don't have time to test it myself currently (plus the |
Author
|
No worries! I think it should be fine because users have to create ports manually on windows anyways so the open_ioport thing shouldn't affect windows? open_port changes should be pretty safe too. The only edge case I can think of is if they somehow had a port named IAC Driver Flapi Request/IAC Driver Flapi Response that isn't used for Flapi. Totally understand where you're coming from tho. Thanks so much for making Flapi! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresses issue #37
2-step fix here, although you only need 1 to get it working:
Fix 1: open_ioport for Auto Port Creation
Fix flapi creating ports itself on mac. We need to use the mido function open_ioport instead of open_input and open_output.
From here, the README instructions should work.
Fix 2: IAC Driver Port Name Matching for Manual Port Creation
For Audio MIDI Setup ports to work, we need to edit the open_port function slightly. The current code assumes that the drivers will be named exactly "Flapi XXX" with a number suffix. However, the mac driver created ports are always detected as "IAC Driver Flapi XXX". So this code will never find IAC Driver ports.
After doing this, I was able to connect to IAC ports, or have FLAPI create its own ports, and produce a healthy heartbeat.