-
-
Notifications
You must be signed in to change notification settings - Fork 10.5k
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
Using another android device as client #100
Comments
As is, the client would require SDL and FFmpeg ARM versions, and wrap SDL stuff into an Android application. But IMO it would be better to write a specific Android client, which would use the Android APIs instead of SDL and FFmpeg. |
+1 Would also like to see this turn into a feature. |
Hi @rom1v ! |
@tailcode The name should not be confusing about what application it is, so the very same name is not a good idea. |
@rom1v Thank you. Considering basic functionality of scrcpy, I think my app is ready but not perfect. This is my first app. I want you to take a look at my app and provide me with suggestions. So if you are okay with it please provide me with an email or any other medium to send the apk. And if possible kindly suggest some "wordplay" for the app name. |
Hey, sorry for bothering, but is there any plans to make it so there's almost no latency on the android app @tailcode is developing? |
Sure. Publish the code somewhere and I'll take a look when I have some time 👍 |
@rom1v Here is the code. Thanks in advance. |
@rom1v Thank you very much. I agree with you. But I have made small changes to AdbCrypto.java file of adblib. I will see if I can isolate those changes. Meanwhile one issue that I came upon while using the app is, I am unable to open items in gallery and file manager of remote device. When I click on an image or video thumbnail, instead of opening, they are being selected. Please enlighten me if I am missing something. |
@tailcode Hey, I just tested, that works great 👍 Good job! Is it possible to quit from the client? (I only see the remote fullscreen, so I can't control the client device) Also, if the devices have a different aspect ratio (typically if I force the navbar to be displayed), the video aspect-ratio is not preserved.
I think there is a similar problem with VLC: if I click quickly while a video is playing, it should display the control bar, but it does not. |
@rom1v Thank you very much for the feedback.
Yes, when you exit from the app, socket pipe breaks and server terminates. Cleaning of remote device is handled in server code.
You mean input events are not working ? I have tested on few devices and they worked for me. Please let me know what device you are using and I will try to test on it if I can find it in my circle. One hurdle I have encountered on a Samsung device is, it doesn't have curl or wget binaries in it and the server cannot be downloaded to it by the current implementation. I don't know if all samsung devices are so. I have worked on a new method to push server to remote device which I am testing. I will push them to git once I think it is ready. |
How do you do that? The whole client screen displays the remote screen.
Yes, input events are workings: they are forwarded to the remote device. |
@rom1v Sorry, I mistook your question.
Just swipe from bottom edge of screen. You will see android navigation bar. |
srccpy-android works really well for me, especially after changing my phone's aspect ratio to match my tablet's with Even with just a wifi connection, the latency is low enough to type without any lag on my bluetooth keyboard, scroll webpages, and watch videos. Maybe a link could be added in scrcpy's README? |
@tailcode thanks for android client, having problem with landscape device, more info: https://gitlab.com/las2mile/scrcpy-android/issues/3 |
It works only wiressly, no USB OTG support ? |
Any APK for scrcpy-android? Would love to try it out. |
@parkerlreed It works pretty well for me over wifi, but would have lower latency I think if USB connections were supported. |
Cheers! Working quite well with Pixel 3 XL host and Fire HD 8 as client |
Scratch that ^ Shield was on ethernet whilst phone was on Wifi. Works when both on wifi. |
This issue has been open for almost 2 years. I hope we approach towards a resolution soon. |
There are no plan to develop and maintain an Android client of scrcpy. You can test the prototype from @tailcode here: #100 (comment) |
Chrome Remote Desktop app works perfectly for this |
Maybe also rustdesk works also but I'm not sure about the server part of the process... |
Hi @tailcode,, i have tryed your app and work perfectly !! |
Can't believe this hasn't been mentioned. WebADB includes a port of scrcpy that you can use straight from a web browser. https://yume-chan.github.io/ya-webadb/ @mouedarbi It allows cropping as well :) |
@parkerlreed: thanks for pointing to the webdemo of ya-webadb! Just to highlight again what is not directly apparent from those screenshots: ya-webadb allows using scrcpy (and more) over the USB cable to another Android device! That's what I was desperately looking for (i.e., not needing any network connection whatsoever, apart from initially loading the demo). Kudos to @yume-chan. |
Can you share how you manage to connect two phones via USB cable? Are you using ya-webadb via browser? Is there a way to run it locally not from browser. |
@bladyle: Yes, exactly: I used the mobile browser and surfed to yume-chan.github.io/ya-webadb/scrcpy. Not sure how it should run without a browser. 🤷♂️
|
@mherrmann3 Thanks, manage to connect two phone, but still as you wrote you need newer phone with supported browser. |
Would it be possible to create an official fundraiser for @rom1v to add an Android client? Looking at the fact that there is a lot of interest, only 10 USD from 100 people would be enough to collect an interesting amount. It's $1,000, but it's possible more people would have cashed out or more. A huge request from me is that the creator of the collection is @rom1v as the trusted owner of this product. I saw that there are ready projects that enable such fundraising that are integrated with github. |
Genymobile's current Linux version (at this date, v2.1.1) is ported to Android in termux-x11. After initially "authorizing -- always Allow" the Android server (your device) on the Android client (mirrored) device (with a USB cable), you can use either USB or TCPIP (TCP enables remote connections: issue "termux-adb tcpip 5555", or another port_number). I find that a cellular IPv6 connection is most reliable for remote handling, because it disregards potential issues with router forwarding (accordingly, an important Developer option in Android 13|14 on the client is "Mobile data always active", alongside "Disable adb authorization timeout", etc.). Assumptions: both ISP APNs use IPv6 by default, and that the ISPs or devices don't filter or block outgoing/incoming connections. My prerequisites: My procedure: It works: video, audio, everything ... Most of the above can be scripted. For a remote connection, the "trick" (and the rub) is to learn or know the client's IP address! In practice, assuming both Android devices are truly mobile (acquiring short-term IP addresses), the client must report (using http, curl, wget, ssh, etc) its current address(es) periodically to a third party device with a known or static IP, mutually accessible by both server and client. For example, the third party might employ a simple PHP routine (using, e.g., $_SERVER["REMOTE_ADDR"]) to detect the address of an incoming connection, store it in an array or file, and report it if queried. If server wants to use the client's cellular address, an unrooted,client must disable WiFi; if rooted, the client can detect it's IPv6 cellular address from rmnet in "ifconfig -S" and post that to the third party, while WiFi remains "up". |
Hello, Any news on this ? Thanks |
@tailcode I've been using your app and it works flawlessly, can't thank you enough for building this. I use it to remotely connect to my another android device within the same network. I have noticed an issue though - sometimes while I'm away from home (the other android is a stay-at-home android device), I want to remotely connect and control it from my phone while on LTE/4G/5G - using Tailscale I was able to connect both devices in same network but entering the tailscale IPv4 address in your app opens up a blank black screen and nothing more. Can you please help with this? Thanks in advance! |
Thank you! Is there a way to specify the display id? |
I have a similar issue. Connecting from the same WiFi network works fine, but if I connect my phone to Zerotier while on cellular data and try to connect via a Raspberry Pi also connected to Zerotier and on the same network as the device I want to connect to I only get a black screen. Pinging the device from my phone works though, and with the same setup I can successfully connect from my PC using the desktop scrcpy,so it must be some problem with the scrcpy-android app. |
@tailcode I was unable to connect to my Pixel 7 using your app. Got the authorization prompt on the host but on the client a black screen with an oscillating º symbol. I went to ensure I could connect over WiFi from my desktop and found that I needed to update scrcpy to support Android 14. I wonder if the same is true for your Android app? Are you able to update please? Let me know if you need any logs. Thank you. |
Hello guys, I found an app called 甲壳虫ADB助手 (Beetle ADB Assistant). This app runs very smoothly on my device and perfectly solves my problem. However, the app is only available in Chinese and is not open-source software. If needed, you might consider giving it a try. |
Thanks for this amazing project.
Is it possible to mirror one android screen to another android device using scrcpy-adb connect method? I found adb clients compiled for arm devices and also java implementation of adb client on github. What are your thoughts?
The text was updated successfully, but these errors were encountered: