Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Viewing your phone while in OTG mode #4369

Open
Missingpng opened this issue Oct 22, 2023 · 2 comments
Open

Viewing your phone while in OTG mode #4369

Missingpng opened this issue Oct 22, 2023 · 2 comments

Comments

@Missingpng
Copy link

I am on Windows 10, and I am using OTG to use a HID mouse, but as you might know it doesn't show you the phone's screen unlike normal scrcpy.

Is there a way to view your phone while using OTG? Thanks

@Jon8RFC
Copy link

Jon8RFC commented Oct 23, 2023

I just tested and setup wireless adb on my phone, then connected my USB mouse to my phone using the included google OTG adapter that comes with Pixels, then ran scrcpy successfull and could see the mouse cursor moving on scrcpy on my computer.
https://www.genymotion.com/blog/open-source-project-scrcpy-now-works-wirelessly/

You could use a batch file to have adb switch to wireless more easily if there's not a flag to have scrcpy switch itself like scrcpy.exe -wireless:

@echo off
adb kill-server
adb tcpip 5555
adb connect JPB-Phone
exit /b

I use kill-server first, and maybe you won't need to since I do some funky stuff. But it sometimes won't connect wirelessly because of a previous wireless connection, I think, so kill-server resets on the computer, then it connects fine for me.

@yume-chan
Copy link
Contributor

Or you can connect to the device via both USB and TCP, so you can run two Scrcpy instances, one for OTG over USB and one for screen mirror over TCP. See #4028

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants