fun with Intents on Android

Dirk Hohndel dirk at hohndel.org
Sun Aug 5 20:47:46 PDT 2018


I had wanted to push this for a while but never got around to it.

I did the first baby steps of better Android device integration. If the user plugs in a device that we have registered our interested in (like an FTDI dive computer), Subsurface-mobile actually gets notified.
The easiest thing we can do is at least log the information, duh. That's what I have implemented so far. But the next step could be to switch to the download screen (unless the user was doing something useful like editing / adding a dive) and select the device that was plugged in (assuming we can figure out what it is).
Hopefully this will also be the first tiny step to the much more important work of allowing Subsurface-mobile on Android to access serial devices even on modern phones that don't allow us access to the /dev directory. My first simplistic brute force way of doing that predictably failed. This will require a bit more careful thought and modification of the libraries that we use - which simply assume that it's ok to access '/dev'...

Anyway, for those who are curious and want to take a look - I didn't push this into master, yet, it's in the androidIntent branch on GitHub.
Anton, I'd love to hear what you think about the work so far and if you think this is the right direction, we can merge this into master.

/D


More information about the subsurface mailing list