-
Notifications
You must be signed in to change notification settings - Fork 625
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
android 10 support #190
android 10 support #190
Conversation
getBuiltInDisplay (which has been removed) with getPhysicalDisplayToken.
Thank you @pcrepieux, great work as always. I will look into this after work today. |
@pcrepieux, is there an email address I could contact you at? |
Hi @sorccu, the one I use in my git commits is fine. |
Hello, |
Tested, working! Thanks! |
@pcrepieux Can help to compile the x86 armeabi - v7a added two versions ? Thank you very much. |
@pcrepieux, @sorccu Good news we are looking forward for the merge and new stf docker release :). |
May I have your complied files? |
你好,目前android10可以正常使用了吗? |
Thanks @pcrepieux
|
Thanks for the feedback @yimelia Looks like it cannot get a proper display handler. The patch currently calls getPhysicalDisplayToken(int) but there is another way to get it : by using getInternalDisplayToken(). If you know how to compile the lib, you can give it a try. I'll do it anyway but as I only have pixel devices at hand right now, I am not sure I'll be able to reproduce it. |
hi @pcrepieux
to
But the size of the file I compiled is the same as before, and when I push them into my MI 9, I got the same error. It seems that the update: |
It's hard to say remotely but chances are that you didn't actually compiled minicap-shared. Build instructions are described here. It requires quite some setup but is worth the effort. |
Is there any chance to provide the prebuilt library for Android 10 in the source tree? |
I think #199 would be the proper way to share prebuilds for testing purpose.. |
That would be great. I could help to test it out on Pixel 3XL. |
hi @pcrepieux
then I compiled the
|
I may have found an additional issue. We wrap minicap in our framework. When the screen gets rotated we restart it. This works great up to SDK 28:
I tested out the Android 10 prebuilt library I found here. It works on the first start. When it gets restarted it fails to start properly:
It appears that the process fails to clean up ("Destroying virtual display") when it gets killed. |
@rpes could you provide the steps to reproduce this issue with minicap and provide the device model name ? |
We retried with the latest library. It suffers from the same issue. The device is Google Pixel 3XL with Android 10. It's complicated to provide the steps. We call ADB from Java using the DDMLib library which is part of the Android SDK. Restarting minicap from the CLI seems to work well. I believe that the problem is in how the process gets terminated. The DDMLib starts a shell command but it doesn't allow to kill it directly. It is only possible to set the "cancel" flag to terminate the blocking call. The actual code that performs this is in the AdbHelper.executeRemoteCommand() method. When the shell command is cancelled (isCancelled() returns true) it simply breaks the blocking loop and closes the socket channel used to communicate with ADB. Unfortunately I have no visibility of whether the ADB back end kills that process properly in response. For completeness, we can't use "adb shell kill" to kill the process by PID becase of the permissions. We can only use unrooted devices. The interesting point is that it works fine with minicap up to SDK 28. Is it possible that unlike SDK 29 the process terminates properly or that the restarted process performs better cleanup after the previous one? |
@rpes could you try to ensure the process get properly killed by your framework (maybe there's a also a behavior change in another component that you use...). |
我按照@pcrepieux 的修改,成功运行了Android10 (oneplus6) |
@koral-- any updates on the merger of this feature.. |
|
I build minicap.so by command as under, now it work normally. |
@gdbrianlu |
UNISOC‘s engineering machine |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR.
LGTM
hi @pcrepieux |
@pcrepieux Can you please provide us binaries for |
Hi @pcrepieux |
@faisal097 |
@pcrepieux |
hi @pcrepieux
do you know how to solve it? |
@yimelia |
@pcrepieux
my phone is One Plus6, and Pixel 4 |
@yimelia |
Display ids management changed : 0/1 are not internal/external ids like they previously were.
hi @pcrepieux |
@pcrepieux |
"version": "2.3.0", | ||
"description": "Prebuilt binaries of minicap.", | ||
"version": "2.3.2", | ||
"description": "Orange prebuilt binaries of minicap for OpenSTF.", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unintended change, see #203
hi @pcrepieux , do you know if there is any solution for Android 10 running on a LG phone, I'm getting this Seems to be cause be this minicap says: "Vector<> have different types (this=0x7fd288d520, rhs=0x7fd288d670)" Any help will be appreciated, please!! |
are u fix this problem? |
Nope. I managed to overcome this issue on a G6 (API level 28) see here: #169 (comment) |
Android 10 changed SurfaceComposer API. getBuiltInDisplay has been removed but can be replaced by getPhysicalDisplayToken.
This PR has been built with AOSP tag android-10.0.0_r2 and tested on a Pixel 2 XL running QP1A.190711.020
I kept 2 commits so that you can easily see the difference between minicap_28.cpp and minicap_29.cpp