IO Exception happened while getting device screenshot
I got tons of error messages as below:
[ScreenCaptureRunnable.java:58]2017-08-21 00:56:57,952 [Screen Capturer] [31mWARN [0;39m com.github.xsavikx.androidscreencast.api.injector.ScreenCaptureRunnable - IO Exception happened while getting device screenshot. Will try again in 100 ms. [ScreenCaptureRunnable.java:87]2017-08-21 00:56:58,062 [Screen Capturer] [34mINFO [0;39m com.github.xsavikx.androidscreencast.api.injector.ScreenCaptureRunnable - Failed to get device screenshot
They are just repeated again and again.
Platform is Android-x86 running in Hyper-V VM hosting on WS2016.
It's appreciated if you give me some advises to solve this.
@lesca Hi, are you able to get a screenshot via adb directly?
I haven't tested the app against any VMs.
@xSAVIKx What's the command to take screenshot with "adb" ? I'd like to have a try.
To get screenshot via adb
adb shell screencap /sdcard/screen.png && adb pull /sdcard/screen.png
@xSAVIKx Hi, i get this problem for AndroidScreencast 0.0.13s on Win7 wiht JDK 13.0.1
[ScreenCaptureRunnable.java:58]2019-11-24 14:22:43,775 [Screen Capturer] [31mWARN [0;39m com.github.xsavikx.androidscreencast.api.injector.ScreenCaptureRunnable - IO Exception happened while getting device screenshot. Will try again in 100 ms.
[ScreenCaptureRunnable.java:87]2019-11-24 14:22:43,876 [Screen Capturer] [34mINFO [0;39m com.github.xsavikx.androidscreencast.api.injector.ScreenCaptureRunnable - Failed to get device screenshot
This warning shows in console around one/two times per second.
@4EPHblN do you have the AndroidScreencast.log file? There should be more detailed logs.
Also, can you try to grab the screenshot manually?
The other suggestion is to use Java8 instead.
@xSAVIKx I have the same warning on JDK 8u231. Manually the screenshot grabs without any problems. ASUS PC Link which use similar technology works fine. AndroidScreencast.log
@4EPHblN yeah, the logs were not helpful here :-( Can you please try the new v0.0.16s version? I've updated some dependencies and the logs should be more reliable now.
@xSAVIKx You link shows 404.
Yeah, looks like draft releases are not publicly available :-(
Here are the bundles. androidscreencast-0.0.16s-linux.tar.gz androidscreencast-0.0.16s-macosx.tar.gz androidscreencast-0.0.16s-windows.zip
@xSAVIKx An update solves this issue for me. AndroidScreencast.log
@4EPHblN that's great to hear! I've also released this version and it's now available here.