• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Disabling midi notifications/support
#1
Firstly (since this is my first post here) - MobileSheets is great!

However, I've recently been developing/building a midi instrument (a bandoneon) - it's based on Teensy (like Arduino), which is configured to run as a Midi device over USB. Then I can plug it into my phone/tablet, and use that to both power it and run FluidSynth to convert midi to audio using a custom soundfont. 

That's all fine - except every time I plug the device into my phone (plus every time I move my phone and it momentarily drops the USB connection!), MobileSheets pops up a notification prompting me to treat my Teensy as a midi controller, even though MobileSheets is not supposed to be active. This has become so disruptive that I've actually uninstalled MobileSheets from my phone for now - but at some point, I'll probably want to run this through my tablet, too, which is where I mainly use MobileSheets.

So - is there any way to disable MobileSheets from attempting to do anything with Midi (over USB)? I couldn't find anything in the settings. 

Thanks - Danny
Reply
#2
On Android, no, I don't currently have an option to disable MIDI. I do have that in the Windows version. The problem is that, on Android, MobileSheets isn't actually the one generating that popup - the OS is. MobileSheets registers itself as being able to handle MIDI connections through an intent filter, and so when the OS detects a MIDI connection, it's asking if you want MobileSheets to use that MIDI connection. That's not something the app itself can disable. I should mention that this filter is only needed for the default MIDI library, but it's something that has to be placed in the application manifest, meaning it's not something that can be set up at runtime - it's set up as part of the app installation. On some devices (particularly older ones or ones that don't support the Google MIDI library), the MIDI would stop working entirely without that. So I'm not sure there is an easy solution for this.

Mike
Reply
#3
There is a post here that discusses things surrounding this issue: https://stackoverflow.com/questions/1238...uppression

On most devices, there is a checkbox to indicate that MobileSheets should be used by default which stops the popup from being shown (but it will probably automatically load MobileSheets every time the device is connected).

Mike
Reply
#4
Thanks for the reply and explanation. From the docs, it looks like the alternative would be enumerating USB devices at runtime and requesting permission, but I assume that this is what you have tried as you say it doesn't work for older devices.

As mentioned - I am using the FluidSynth app to connect to and use the connected device using MIDI-over-USB. In that app, I have to trigger it to scan for connected devices, which works fine. It's clearly not using the intent filters, as there are no notifications relating to it if I plug in a USB device. It has basic USB permissions (I forget if it asked for permissions the first time I used it - it certainly doesn't now).

I guess, in my ideal world, MS would work in the same way as FluidSynth in this regard. I do understand, though, that there may be additional things that I'm not aware of (you mentioned the Google MIDI library)!

Thanks - Danny
Reply
#5
I can consider removing the device filter, but I'd need to run through tests to verify that this doesn't cause the MIDI functionality to stop working. 

Mike
Reply
#6
I tested out removing the device filter and the MIDI functionality continued to work. So I'm going to make this change for the next update and we will see if it negatively impacts anyone. I think based on what I'm seeing that it should be fine though.

Mike
Reply
#7
Whoop - thanks for following up on this - that's really great.
Reply
#8
The change is available with version 3.8.36 which is now available. Let me know if that fixes things for you.

Mike
Reply
#9
Small follow-up on this: on Android 14 devices, the "Default" midi library stopped working after making this change. However, I discovered a problem in the code that requests access to the MIDI device, so once I fixed that, it started working again. I pushed out a small update through Google Play for this, so that should be available soon (still version 3.8.36, just a new build).

Mike
Reply
#10
Brilliant - yes it's working nicely now. Thanks so much!
Reply
#11
Glad to hear that! Thanks for letting me know.

Mike
Reply




Users browsing this thread:
4 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2024 MyBB Group.