Is there anyway to detect pc usb connection (not through charger) to Firefox OS device at Gaia layer?
Any callback in Gaia layer also works for me.
The reason I do this because I need to handle some events once the device connects to pc through USB. However, so far I did not find any clue about it.
Certified apps probably have a better way to do this but for a privileged app one approach may be to use a change listener on the sdcard - This will only work if the USB storage option has been enabled in settings.
Make sure to add the device storage permission to the manifest