Sure, when you connect a SFOS device to a computer you see it via MTP. However in my situation, I have no computer at hand and just want to connect the GARMIN GPS device , which also uses MTP to my SFOS phone via USB OTG. However I cannot see the GARMIN in the file manager on the phone.
No, you’ll have to do the operation from your Garmin, if possible. I don’t have a garmin so I couldn’t tell for sure. I just thought that there was some import option.
Otherwise you could possible go phone to PC to Garmin workaround.
Unfortunately, I think the Garmin also has only a client site implementation (if that is the right term) for MTP. The only (inconvenient) way, I found is plugging the micro SD Card out of the GARMIN and plug it into the phone and copy the file to the SD card. This is quite a hassle, because I need to get the SIM tray out of the phone.
Wouldn’t it be nice if the SFOS phone could also act like the MTP server (like a computer does). This way you could also plug e.g. also two SFOS phones together via USB OTG and move files back an forth?
So you can’t export from PC to Garmin?
Edit:
Sorry, somehow I missed that you do not have a PC.
I have a PC. I just don’t take it with me on a hiking trip. I download a GPX track from the internet with the phone and want to put it on the GPS device. Surely I could also use the GPX track file with e.g. Puremaps and use my phone for navigation. The GARMIN device however has a much better battery life compared to the phone.
Not that I know anything about Garnin devices, but maybe there’s another way to get stuff off it?
E.g. Connecting to the device’s wifi, like you can do with many digital cameras?
The spec page lists both Wifi and ‘app’ connectivity (which I assume is bluetooth, which is complicated).
The device can connect via Wifi as well as BT. For an Android or iOS phone, there is a dedicated “Garmin connect” app to transfer data. This App however doesn’t work with the Android App Support under SFOS due to the well known Bluetooth restrictions. I couldn’t figure out how the app communicates with the device.
Yes, what I meant is can it offer a wlan conection (access point) for the phone to connect to?
If so there’s a good chance there’s some kind of web-based API one could use to get what you want using e.g. a python script. In the easiest case just connect via Browser.
@kraemera
Maybe it is possible to connect an USB-Stick with SD-Card reader via USB OTG cable to your phone.
I checked, it doesn’t offer an access point. It can connect to WLAN access points and you enter the SSID and password on the device.
Thanks, I will try this out.
Well, I was successful with transfer photos and remotely control digital camera from Xperia 10 II via USB OTG cable. TimeLapse tools is using gphoto library for that…
So, I believe that everything you need is to find command line tool / library that is able to communicate with Garmin via MTP protocol and compile it for phone. GPhoto2 may be enough, but I have no Garmin device to try it. Or libmtp possibly…?
Thanks very much for the hint. I will look into it. I however did not yet compile anything for the phone.
One question: In your case with the camera. Do you think, that you could mount the MTP share of the camera, so it appears in the file browser? Something in the direction of this article:
?
Looks promising. On it!
Well, it compiles…
Completely and utterly untested:
https://build.sailfishos.org/package/show/home:nephros:devel:packaging/jmtpfs
and the lib dependency:
https://build.sailfishos.org/package/show/home:nephros:devel:packaging/libmtp
Please play with it, and report any findings!
Compiling should not be neccessary for a quick test. I just pulled jmtpfs_0.5-3_armhf.deb and libmtp9_1.1.17-3_armhf.deb from a Debian repository, extracted them and moved libmtp.so.9.4.0 and jmtpfs into a subdirectory of my XA2. After renaming/linking libmtp.so.9.4.0 to libmtp.so.9 and setting LD_LIBRARY_PATH to point to the work directory, jsmtpfs could be started.
Unfortunately I havent got a wire to link USB-C to the socket of my Zumo, but jsmtp from my pc to the Garmin Zumo works.
I will try it out, when I find some time. Thanks a lot.
I have aUSB-C OTG adapter, but I think connecting it should work also with any USB-C dock … for example from a laptop.
Be aware of
This https://together.jolla.com/question/217634/bugxperia-10-crash-bug-with-usb-otg/ is still an issue with 3.4.(EA) albeit tracked by Jolla. Is here hope to get this fixed in the release version?
however (and a couple of related reports).
At first I was surprised that libmtp
wasn’t packaged with SFOS.
But it turns out that - how else could it be - the systemd/udev guys encroached it and have their own implementation.
Therefore that build of libmtp does not package udev-related stuff. Hopefully that does not cause problems.