I am trying to use Vysor to control my Moto G5 which has a broken screen (completely black). It appears to be working otherwise (rings when called etc).

However, I cannot connect to my PC using USB cable when the phone is on, because I cannot change from "Charging only" to MTP or PTP because I cannot see it on the screen. I can connect to ADB via recovery (stock and un-rooted) but all "adb shell" commands fail (error:closed) which I assume is due to not being rooted.

I am trying to change the default USB connection mode to PTP rather than "Charging only" so I can use Vysor when the phone is booted normally, not in recovery. Has anyone got any ideas?

I either need a way to made "adb shell" commands work (to follow the below link), or another way to change the USB default or another bright idea!

How Do I change from PTP to MTP mode? Cannot find options in settings

1 Answer 1


Late as I am to the party the following might be of some help:-


The command svc usb setFunction <mtp|ptp|rndis|midi> is the most likely candidate (alternatively setFunctions is used dependant on the version of Android.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .