scrcpy: Mouse clicks do not work
I am using Xiaomi max 2 on macOS High Sierra 10.13.3
scrcpy v1.0
dependencies:
- SDL 2.0.8
- libavcodec 57.107.100
- libavformat 57.83.100
- libavutil 55.78.100
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 10
- Comments: 79
I find the reason of the issue,switch below option for obtain the permission of simulating Input
Thanks you @imkkdev I am using Xiaomi Mi11t Lite MIUI13/ Android 12 Phone, I can confirm it works after set the USB debug security settings and reboot, reboot is must!
@izayl Thank you very much! I added a question in the FAQ.
on XiaoMI Phone ,also need to reboot
why my android OPPO R15 no USB debugging(Security settings) option? so I cannot click my simulating screen .
In MIUI you are locked behind Mi Account link in order to enable ADBinput for keyboard and mouse. To bypass that (with root):
setprop persist.security.adbinput 1
I dont believe root-less solution is possible because MIUI permission service will block any user-app trying to do the same.
Solved, enable the permission of simulating Input work for me
Thanks all
On Android 14, use the latest version (v2.1.1 currently)
Everyone using a Xiaomi device -
@Mixterix-AL @ahmedsallam544
There is a way to enable keyboard input that is much easier than rooting your device, but you might be adverse to this for privacy reasons.
Others have discussed rooting your device, which, in my opinion, unless you really want root for other reasons, is probably overkill, and likely exposes your device to more threat vectors & vulnerabilities.
Easy fix - Do as they say & sign into your Mi account
The simple solution is to do what your manufacturer is telling you - “Sign in with your Mi account”.
Personally, I find the constraint odd - If I’m activating devtools & running adb, chances are I have a good idea of whatever it is I want to do, and I’ve already dismissed one or two warning dialogues already- but, personally, I take it on good faith that the manufacturer is trying to protect me from myself.
It’s odd, however, since this is maybe the only setting I’ve encountered that’s locked behind a Xiaomi account.
Pros and cons for using a Mi account instead of rooting
I don’t think anyone in this thread has explained why they are reluctant to follow the “easy” fix, and make an account
All this being said, your mileage may vary. You’re essentially making a series of Security/Convenience tradeoffs in activating the settings that allow
scrcpy
to function.adb
for convenience of screen mirrroring at the cost of security.adb
for the convenience of keyboard input at the cost of securityPersonally, I signed into a Mi account, activated the setting, and signed out of the account again & everything seems to be working just fine. There was no consent screen when I used Google’s SSO, so it appears that I may have already made an account in the past (I don’t remember).
I’m not clear on how much data was collected from me, what of that data is retained
@vajra108 Thank you, I just mentioned it in the doc: 21df2c240e544b1c1eba7775e1474c1c772be04b
omg so much time lost because I didn’t reboot, thank you!
Thanks for the tip, I’ll just add when I tried to turn it on, they asked me to log into my mi community account. After that everything worked.
Cant un-upload all the personal data they already fetched from your phone on the sign-up process.
thanks this works for me!
Then it should work. What’s the output in the console?
Xiaomi Mi 6 has the same issue