Closed Kimi1860 closed 1 month ago
The vendor rom calls an internal "Sky-something", which fails.
Could you please post your framework.jar?
adb pull /system/framework/framework.jar
framework.jar.zip Here's the framework.jar
Thanks
Hi, I've post the framework.jar. Just wonder if there's any chance that my devices could be available to connect with this.
It's weird, your framework.jar is almost empty, it doesn't contains the expected classes.
The OS provider is called Coocaa, maybe they did some tricks reconstructed the framework
Same issue. Also happen at Skyworth TV, Looks like it's common issue on Skyworth TV
My Skyworth Coocaa TV is the same issue.I tried to downgrade to scrcpy v1.19 and resolved the issue.But its maximum resolution can only be set to 1920 x 1080, and its HDMI channel is black screen (appears to have DRM protection?)
I tried to downgrade to scrcpy v1.19 and resolved the issue.
With the latest version, does it work if you disable audio (scrcpy --no-audio
)? What is the exact error you get (the full console output)?
I tried to downgrade to scrcpy v1.19 and resolved the issue.
With the latest version, does it work if you disable audio (
scrcpy --no-audio
)? What is the exact error you get (the full console output)?
I just tried, but this error still persists.
C:\Users\Hins\Downloads\scrcpy-win64-v2.5>scrcpy --no-audio
scrcpy 2.5 <https://github.com/Genymobile/scrcpy>
INFO: ADB device found:
INFO: --> (tcpip) 192.168.31.22:5555 device 7T872_P60P
C:\Users\Hins\Downloads\scrcpy-win64-v2.5\scrcpy...ed, 0 skipped. 86.8 MB/s (69624 bytes in 0.001s)
[server] INFO: Device: [skyworth] Coocaa 7T872_P60P (Android 10)
[server] ERROR: Exception on thread Thread[video,5,main]
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Object android.content.Context.getSystemService(java.lang.String)' on a null object reference
at android.media.MediaCodec.getCurProcessName(MediaCodec.java:1913)
at android.media.MediaCodec.setSkyMediaStatus(MediaCodec.java:1927)
at android.media.MediaCodec.release(MediaCodec.java:1949)
at com.genymobile.scrcpy.SurfaceEncoder.streamCapture(SurfaceEncoder.java:95)
at com.genymobile.scrcpy.SurfaceEncoder.lambda$start$0$com-genymobile-scrcpy-SurfaceEncoder(SurfaceEncoder.java:257)
at com.genymobile.scrcpy.SurfaceEncoder$$ExternalSyntheticLambda0.run(D8$$SyntheticClass:0)
at java.lang.Thread.run(Thread.java:919)
INFO: Renderer: direct3d
ERROR: Controller error
same here and my framework.jar.zip
for 1.19 is OK
D:\scrcpy\scrcpy-win64-v1.19>scrcpy.exe
INFO: scrcpy 1.19 <https://github.com/Genymobile/scrcpy>
D:\scrcpy\scrcpy-win64-v1.19\scrcpy-server: 1 file pushed, 0 skipped. 28.1 MB/s (37330 bytes in 0.001s)
[server] INFO: Device: Skyworth 1AA03_BC20 (Android 9)
INFO: Renderer: direct3d
INFO: Initial texture: 1920x1080
for 1.20 is error
D:\scrcpy\scrcpy-win64-v1.20>scrcpy.exe
INFO: scrcpy 1.20 <https://github.com/Genymobile/scrcpy>
D:\scrcpy\scrcpy-win64-v1.20\scrcpy-server: 1 file pushed, 0 skipped. 33.9 MB/s (37139 bytes in 0.001s)
[server] INFO: Device: Skyworth 1AA03_BC20 (Android 9)
[server] ERROR: Exception on thread Thread[main,5,main]
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Object android.content.Context.getSystemService(java.lang.String)' on a null object reference
at android.media.MediaCodec.getCurProcessName(MediaCodec.java:3885)
at android.media.MediaCodec.setSkyMediaStatus(MediaCodec.java:3898)
at android.media.MediaCodec.<init>(MediaCodec.java:1810)
at android.media.MediaCodec.createEncoderByType(MediaCodec.java:1787)
at com.genymobile.scrcpy.ScreenEncoder.createCodec(ScreenEncoder.java:176)
at com.genymobile.scrcpy.ScreenEncoder.internalStreamScreen(ScreenEncoder.java:74)
at com.genymobile.scrcpy.ScreenEncoder.streamScreen(ScreenEncoder.java:65)
at com.genymobile.scrcpy.Server.scrcpy(Server.java:80)
at com.genymobile.scrcpy.Server.main(Server.java:255)
at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:351)
ERROR: "adb reverse --remove" returned with value 1
ERROR: Could not retrieve device information
D:\scrcpy\scrcpy-win64-v1.20>
for 2.5
D:\scrcpy\scrcpy-win64-v2.5>scrcpy.exe --tcpip=192.168.89.145
scrcpy 2.5 <https://github.com/Genymobile/scrcpy>
INFO: Connecting to 192.168.89.145:5555...
INFO: Connected to 192.168.89.145:5555
D:\scrcpy\scrcpy-win64-v2.5\scrcpy-server: 1 file pushed, 0 skipped. 92.5 MB/s (69624 bytes in 0.001s)
[server] INFO: Device: [Skyworth] Skyworth 1AA03_BC20 (Android 9)
[server] WARN: Audio disabled: it is not supported before Android 11
[server] ERROR: Exception on thread Thread[video,5,main]
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Object android.content.Context.getSystemService(java.lang.String)' on a null object reference
at android.media.MediaCodec.getCurProcessName(MediaCodec.java:3885)
at android.media.MediaCodec.setSkyMediaStatus(MediaCodec.java:3898)
at android.media.MediaCodec.<init>(MediaCodec.java:1810)
at android.media.MediaCodec.createEncoderByType(MediaCodec.java:1787)
at com.genymobile.scrcpy.SurfaceEncoder.createMediaCodec(SurfaceEncoder.java:208)
at com.genymobile.scrcpy.SurfaceEncoder.streamCapture(SurfaceEncoder.java:53)
at com.genymobile.scrcpy.SurfaceEncoder.lambda$start$0$com-genymobile-scrcpy-SurfaceEncoder(SurfaceEncoder.java:257)
at com.genymobile.scrcpy.SurfaceEncoder$$ExternalSyntheticLambda0.run(D8$$SyntheticClass:0)
at java.lang.Thread.run(Thread.java:764)
ERROR: "adb reverse --remove" returned with value 1
ERROR: Could not retrieve device information
ERROR: Server connection failed
Between 1.19 and 1.20, this is probably due to this commit 8df42cec82cb5856e6c10a4089e6b2953310da6e.
Let's try with this quick&dirty change:
diff --git a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
index 448e7099f..db0d72789 100644
--- a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
+++ b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
@@ -74,6 +74,9 @@ public final class Workarounds {
mustFillAppContext = true;
}
+ mustFillAppInfo = true;
+ mustFillAppContext = true;
+
if (audio && Build.VERSION.SDK_INT == Build.VERSION_CODES.R) {
// Before Android 11, audio is not supported.
// Since Android 12, we can properly set a context on the AudioRecord.
Replace this file in your v2.5 release:
scrcpy-server
SHA-256: 55926d71d45aef83d989bf0fcd25801f8886307efe933eb8d4200807890080a
Replace this file in your v2.5 release:
scrcpy-server
SHA-256: 55926d71d45aef83d989bf0fcd25801f8886307efe933eb8d4200807890080a
This is an effective modification, thank you very much!
Oh great!
Could you then test this new one and confirm that it works:
scrcpy-server
SHA-256: 7cb3bc939c91e23788ed3f2801f71b9cc8f258e85bed7b60fc98ece9721bbe1
Here is the diff:
diff --git a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
index 448e7099f..3f86f892b 100644
--- a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
+++ b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
@@ -63,7 +63,7 @@ public final class Workarounds {
// - <https://github.com/Genymobile/scrcpy/issues/940>
// - <https://github.com/Genymobile/scrcpy/issues/994>
mustFillAppInfo = true;
- } else if (Build.BRAND.equalsIgnoreCase("honor")) {
+ } else if (Build.BRAND.equalsIgnoreCase("honor") || Build.BRAND.equalsIgnoreCase("skyworth")) {
// More workarounds must be applied for Honor devices:
// - <https://github.com/Genymobile/scrcpy/issues/4015>
//
Could you then test this new one and confirm that it works:
scrcpy-server
SHA-256: 7cb3bc939c91e23788ed3f2801f71b9cc8f258e85bed7b60fc98ece9721bbe1
Oh no, the NullPointerException error has occurred again.
C:\Users\Hins\Downloads\scrcpy-win64-v2.5>scrcpy
scrcpy 2.5 <https://github.com/Genymobile/scrcpy>
INFO: ADB device found:
INFO: --> (tcpip) 192.168.31.22:5555 device 7T872_P60P
C:\Users\Hins\Downloads\scrcpy-win64-v2.5\scrcpy-server: 1...ile pushed, 0 skipped. 111.2 MB/s (164344 bytes in 0.001s)
[server] INFO: Device: [skyworth] Coocaa 7T872_P60P (Android 10)
[server] WARN: Audio disabled: it is not supported before Android 11
INFO: Renderer: direct3d
WARN: Demuxer 'audio': stream explicitly disabled by the device
INFO: Texture: 1920x1080
ERROR: Controller error
[server] ERROR: Exception on thread Thread[video,5,main]
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Object android.content.Context.getSystemService(java.lang.String)' on a null object reference
at android.media.MediaCodec.getCurProcessName(MediaCodec.java:1913)
at android.media.MediaCodec.setSkyMediaStatus(MediaCodec.java:1927)
at android.media.MediaCodec.release(MediaCodec.java:1949)
at com.genymobile.scrcpy.SurfaceEncoder.streamCapture(SurfaceEncoder.java:95)
at com.genymobile.scrcpy.SurfaceEncoder.lambda$start$0$com-genymobile-scrcpy-SurfaceEncoder(SurfaceEncoder.java:257)
at com.genymobile.scrcpy.SurfaceEncoder$$ExternalSyntheticLambda0.run(D8$$SyntheticClass:0)
at java.lang.Thread.run(Thread.java:919)
Device: [skyworth] Coocaa 7T872_P60P (Android 10)
Oh in your case, the manufacturer is still skyworth,
but the brand is Coocaa
. Let's test the manufacturer instead:
diff --git a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
index 999f6a714..c9a26d787 100644
--- a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
+++ b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java
@@ -63,7 +63,7 @@ public final class Workarounds {
// - <https://github.com/Genymobile/scrcpy/issues/940>
// - <https://github.com/Genymobile/scrcpy/issues/994>
mustFillAppInfo = true;
- } else if (Build.BRAND.equalsIgnoreCase("honor") || Build.BRAND.equalsIgnoreCase("skyworth")) {
+ } else if (Build.BRAND.equalsIgnoreCase("honor") || Build.MANUFACTURER.equalsIgnoreCase("skyworth")) {
// More workarounds must be applied for Honor devices:
// - <https://github.com/Genymobile/scrcpy/issues/4015>
// and Skyworth devices:
scrcpy-server
SHA-256: 7753a5d077bb8b4c808adedaee4c129ba37f52cfa8bb6d7ea707330d4a7d068
Oh in your case, the manufacturer is still
skyworth,
but the brand isCoocaa
. Let's test the manufacturer instead:
Congratulate, it works successful again.
:+1:
Merged into dev
: b50f9eb41d1bd7b75a77e2c388b0144365e3cd5f :rocket:
Environment
Describe the bug
On errors, please provide the output of the console (and
adb logcat
if relevant).Please do not post screenshots of your terminal, just post the content as text instead.