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

LG G7 ThinQ update(android9-sdk28) issue. minicap aborted. #169

Open
judin74 opened this issue Mar 26, 2019 · 54 comments
Open

LG G7 ThinQ update(android9-sdk28) issue. minicap aborted. #169

judin74 opened this issue Mar 26, 2019 · 54 comments
Labels

Comments

@judin74
Copy link

judin74 commented Mar 26, 2019

When you update the LG G7 ThinQ device,
it will be upgraded from Android 8 to Android 9 (sdk 28).

Run minicap,
The following log will be displayed
and it Aborted.
Issues seems to be "Vector<> have different types " of android::SurfaceComposerClient.

shell] adb shell LD_LIBRARY_PATH=/data/local/tmp/minicap-devel /data/local/tmp/minicap-devel/minicap -P 1440x3120@720x1560/0

INFO: Using projection 1440x3120@720x1560/0
INFO: (external/MY_minicap/src/minicap_28.cpp:241) Creating SurfaceComposerClient
INFO: (external/MY_minicap/src/minicap_28.cpp:244) Performing SurfaceComposerClient init check
INFO: (external/MY_minicap/src/minicap_28.cpp:255) Creating virtual display
INFO: (external/MY_minicap/src/minicap_28.cpp:261) Creating buffer queue
INFO: (external/MY_minicap/src/minicap_28.cpp:264) Setting buffer options
INFO: (external/MY_minicap/src/minicap_28.cpp:268) Creating CPU consumer
INFO: (external/MY_minicap/src/minicap_28.cpp:272) Creating frame waiter
INFO: (external/MY_minicap/src/minicap_28.cpp:276) Publishing virtual display
Vector<> have different types (this=0x7ffe25b480, rhs=0x7ffe25b5a0)
Aborted

@alanrigele
Copy link

We are seeing similar issues with a LG G8 ThinQ, android9-sdk28.

2019-05-07T06:21:53.165Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Setting frame producer projection to 562x562
2019-05-07T06:21:53.166Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Requesting frame producer to start
2019-05-07T06:21:53.166Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Launching screen service
2019-05-07T06:21:53.553Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "PID: 32762"
2019-05-07T06:21:53.554Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: Using projection 720x1560@259x562/0"
2019-05-07T06:21:53.554Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:241) Creating SurfaceComposerClient"
2019-05-07T06:21:53.554Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:244) Performing SurfaceComposerClient init check"
2019-05-07T06:21:53.555Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:255) Creating virtual display"
2019-05-07T06:21:53.555Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:261) Creating buffer queue"
2019-05-07T06:21:53.556Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:264) Setting buffer options"
2019-05-07T06:21:53.557Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:268) Creating CPU consumer"
2019-05-07T06:21:53.557Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:272) Creating frame waiter"
2019-05-07T06:21:53.557Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "INFO: (external/MY_minicap/src/minicap_28.cpp:276) Publishing virtual display"
2019-05-07T06:21:53.557Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] minicap says: "Vector<> have different types (this=0x7fc7e0d140, rhs=0x7fc7e0d260)"
2019-05-07T06:21:53.558Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Connecting to minicap service
2019-05-07T06:21:53.634Z WRN/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Shell keeping minicap running ended unexpectedly
2019-05-07T06:21:56.789Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Disconnecting from minicap service
2019-05-07T06:21:56.790Z INF/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Stopping minicap service
2019-05-07T06:21:56.791Z FTL/device:plugins:screen:stream 1938 [LMG820UM4399f6d1] Frame producer had an error FailError: Failure: 'closed'
at /usr/lib/node_modules/stf/node_modules/adbkit/lib/adb/parser.js:183:29
at runCallback (timers.js:810:20)
at tryOnImmediate (timers.js:768:5)
at processImmediate [as _immediateCallback] (timers.js:745:5)
2019-05-07T06:21:56.791Z FTL/util:lifecycle 1938 [LMG820UM4399f6d1] Shutting down due to fatal error
2019-05-07T06:21:56.798Z INF/provider 22228 [] Cleaning up device worker "LMG820UM4399f6d1"
2019-05-07T06:21:56.798Z ERR/provider 22228 [
] Device worker "LMG820UM4399f6d1" died with code 1
2019-05-07T06:21:56.798Z INF/provider 22228 [*] Restarting device worker "LMG820UM4399f6d1"

@sorccu
Copy link
Member

sorccu commented May 7, 2019

We don’t have that device, so there isn’t much we can do. If your company is able to donate one unit to us (or cover the purchase), we may be able to do something.

@damonmonkey
Copy link

$ adb shell LD_LIBRARY_PATH=/data/local/tmp /data/local/tmp/minicap -P 1440x2560@1440x2560/0 -t
PID: 2479
INFO: Using projection 1440x2560@1440x2560/0
INFO: (external/MY_minicap/src/minicap_28.cpp:241) Creating SurfaceComposerClient
INFO: (external/MY_minicap/src/minicap_28.cpp:244) Performing SurfaceComposerClient init check
INFO: (external/MY_minicap/src/minicap_28.cpp:255) Creating virtual display
INFO: (external/MY_minicap/src/minicap_28.cpp:261) Creating buffer queue
INFO: (external/MY_minicap/src/minicap_28.cpp:264) Setting buffer options
INFO: (external/MY_minicap/src/minicap_28.cpp:268) Creating CPU consumer
INFO: (external/MY_minicap/src/minicap_28.cpp:272) Creating frame waiter
INFO: (external/MY_minicap/src/minicap_28.cpp:276) Publishing virtual display
Vector<> have different types (this=0x7fc7d7f700, rhs=0x7fc7d7f820)
Aborted

I alse have this problem, but there is no problem at beginning, after some days it happened, the devices is XIAOMI MI_8 Android 9 (sdk 28)

@varundtsfi
Copy link

varundtsfi commented Aug 28, 2019

Mostly this is happening with all the LG devices. I have tried 6 LG devices and All having the same issue. Common thing is All having android 9 Version.
LM-X420
LM-G850
LM-Q720
LG V30 plus and LG-Thinq .

INFO: (external/MY_minicap/src/minicaps_28.cpp:241) Creating SurfaceComposerClient
INFO: (external/MY_minicap/src/minicap_28.cpp: 244) Performing surfaceComposercitent init check
INFO: (external/MY_minicap/src/minicap_28.cpp:255) Creating virtual display
INFO: (external/MY_minicap/src/minicap_28.cpp:261) Creating butter queue
INFO: (external/MY_minicap/src/minicap_28.cpp:264) Setting buffer options
INFO: (external/MY_minicap/src/minicap_28.cpp:268) Creating CPU Consumer
INFO: (external/MY_minicap/src/minicap_28.cpp:272) Creating frame waiter
INFO: (external/MY_minicap/src/minicap_28.cpp: 276) Publishing virtual display
Vector have different types (this=0x7feb6ade40, rhs=0x7feb6adf60)
I am trying to figure out what the issue is? I have downloaded android 9 aosp.
if I got something, will post here
I think it seems to be "Vector<> have different types " SurfaceComposerClient.
Here is the error which occurred at run time in aosp
https://android.googlesource.com/platform/frameworks/native/+/jb-dev/libs/utils/VectorImpl.cpp

@sorccu Can you give some suggestions so that we can resolve this?

@entomber
Copy link

@sorccu do you need to have the devices physically on hand or would remote adb access work?

@quangola
Copy link

I've observed this issue as well on the following LG devices when Android 9 is either preloaded or installed as an update:

LM-G850
LM-X320
LM-X420
LM-G820

As @varundtsfi observed, this appears to be an LG + Android 9 thing. My devices also show the vector errors like the one below:

minicap says: "Vector have different types (this=0x7feba9fda0, rhs=0x7feba9fec0)"

@quangola
Copy link

@sorccu My team would like to donate a device to help resolve this issue. We've tried reaching out to contact@openstf.io to get shipping details, but have received no response.

@varunkumarct
Copy link

Hi @quangola Do you have any update on this issue

@man4567890
Copy link

Hi @sorccu
Can I donate a device or pay for dev costs to get this sorted, please send me a PM so I can get the ball rolling
regards

@quangola
Copy link

quangola commented Dec 9, 2019

Hi @quangola Do you have any update on this issue

Nope, haven't heard a thing. We've got a device to donate, but haven't got word back on where to send it.

@pcrepieux
Copy link
Contributor

pcrepieux commented Jan 8, 2020

@varundtsfi
I managed to get a G6 running Android 9 and can now reproduce this issue. Will try to identify the root cause.
...
Looks like they somehow made slight changes in libgui.so compared to AOSP. This leads to using type definitions in minicap-shared with different size (or something like this).
I managed to make it work by putting and preloading on the device the libgui.so compiled from corresponding AOSP branch. I doubt this could be a proper fix but it is a start.

@varundtsfi
Copy link

Hi @pcrepieux
Sorry for the delay. I don't have LG G6 right now but I will buy this asap. Right Now I have LG G7 Thinq running on Android 9.
Model Number: LMG710EMW
LG G7 thinq

And Getting the below error.
Vector<> have different types (this=0x7fc7d7f700, rhs=0x7fc7d7f820)

@pcrepieux
Copy link
Contributor

@varundtsfi
Maybe you could give a try to the approach I have experimented with my G6 on your G7. Will post the lib if it can help you. My main concern is that I don't know how to integrate this workaround smoothly.

@varundtsfi
Copy link

Hi @pcrepieux
Please share the lib. I will try on my G7 device and share the results with you

@pcrepieux
Copy link
Contributor

Hi @varundtsfi
Here is the minicap.so I successfully tested on my G6 (API level 28). To overcome the different Vector types issue, the AOSP libgui (Apache v2) has been statically compiled and merged in minicap.so (that's why it is much bigger). To test it, you will have to replace prebuilt/arm64-v8a/lib/android-28/minicap.so with this file.

@quangola
Copy link

@varundtsfi and @pcrepieux:

I tested this new minicap on two versions of the G8 ThinQ (LM-G820 and LM-G850). So far, seems to work great. I didn't have any success on a LM-X320 or LM-X420; but it looks like these are arm-v7 so they don't appear to use the new library.

@chenchen5000
Copy link

@pcrepieux could you please share the minicap.so (arm64-v8a) for android 10?

@varundtsfi
Copy link

varundtsfi commented Jan 24, 2020

@pcrepieux could you please share the minicap.so (arm64-v8a) for android 10?

Hi @chenchen5000 Please take the binaries from here.
https://github.com/varundtsfi/MinicapBinaries/tree/master/aosp/android-29

@varundtsfi
Copy link

Hi @pcrepieux
This minicap-libgui.so file is working for LG G7 Thinq LM-G710 . It's my personal Device.

LG G7 Thinq

I have one doubt the same library is for LG but for **Xiaomi Redmi 7 Note Pro **
[ro.product.vendor.model]: [Redmi Note 7 Pro] screen is coming black. Might be some minor issue Even I can perform actions over the black screen and its happening on real devices on minicap-libgui.so is not giving actual screen.
RedMi Note 7 Pro
But your help is really appreciated sir. Thanks a lot for your valuable information. I want to do it(mincap-libgui.so) changes on my local also can you share that project. so that for Xiaomi Redmi Note 7 Pro I will try to fix. I mean, I want to understand and learn what exactly the issue was.
As earlier you have mentioned that Manufacture might have changed something inside the libgui.so library.

@chenchen5000
Copy link

@varundtsfi sorry for the mistake, i meant the new minicap.so with libgui.a (minicap-libgui.so) for android 10. I want to test on the device: Redmi K20 Pro(MIUI 11.0.2), Android 10 because minicap crashes with the same error as LG devices have.
It's very appreciated if you can provide that library.

@varundtsfi
Copy link

varundtsfi commented Jan 31, 2020

Hi @chenchen5000

Xiaomi MIUI 11 having some issue but LG got fixed by @pcrepieux.

I have Xiaomi Redmi Note 7 Pro with android 9 having MIUI 11.0.6.0 in which its working but screen capture as black.
But I don't have android 10(Xiaomi) devices and One more thing if you tried any device having MIUI 11 you will get the same error.

Have you tried android 10 binaries in your device? is yes what was the output?

@chenchen5000
Copy link

@varundtsfi Yes, I ran minicap on Redmi K20 Pro(android 10, MIUI 11.0.2), minicap crashes with the error:

Vector<> have different types (this=0x......, rhs=0x......)
Aborted

The same minicap can run on other devices(e.g. huawei device) with android 10.

@Ethan-2013
Copy link

@varundtsfi
I managed to get a G6 running Android 9 and can now reproduce this issue. Will try to identify the root cause.
...
Looks like they somehow made slight changes in libgui.so compared to AOSP. This leads to using type definitions in minicap-shared with different size (or something like this).
I managed to make it work by putting and preloading on the device the libgui.so compiled from corresponding AOSP branch. I doubt this could be a proper fix but it is a start.

Hi @pcrepieux

Hi @varundtsfi
Here is the minicap.so I successfully tested on my G6 (API level 28). To overcome the different Vector types issue, the AOSP libgui (Apache v2) has been statically compiled and merged in minicap.so (that's why it is much bigger). To test it, you will have to replace prebuilt/arm64-v8a/lib/android-28/minicap.so with this file.

Hi @pcrepieux

I have tried on LG device working smoothly but on G8 its not working.
You have mentioned that To Overcome the different vector types issue, AOSP libgui has been statically compiled and merged in minicap.so.

Can you please tell us what changes you have done and in which file of A0SP so that we can also try for other architectures(armeabi-v7a)

@pcrepieux
Copy link
Contributor

pcrepieux commented Feb 5, 2020

@Ethan-2013
Sure, will post instruction shortly (didn't find the time to do it earlier...).
That's basically adding a cc_library_static block in libgui's Android.bp file and a few change in minicap-shared Makefile. More or less... stay tuned.
Sorry for the delay.
...
Here you are.

  • in $AOSP/frameworks/native/libs/gui/Android.bp
    • make a copy of the cc_library_shared block and change cc_library_shared to cc_library_static
    • give it another name ... like libgui_s
  • in $MINICAP/jni/minicap-shared/aosp/Android.mk
  • Compile minicap-shared

I only tested on android 9, so you might have to adjust a few things to have it working on Android 10.

@man4567890
Copy link

man4567890 commented Feb 11, 2020

Hi @pcrepieux , I updated stf with the newest git release from https://github.com/Orange-OpenSource/stf, I think the minicap issue is solved, but I'm getting minitouch errors, see below please

2020-02-11T09:03:49.419Z FTL/device:plugins:screen:stream 14563 [LMX420ZD6PNB9P9PHI] Frame producer had an error FailError: Failure: 'closed'
    at /usr/lib/node_modules/stf/node_modules/adbkit/lib/adb/parser.js:183:29
    at runCallback (timers.js:810:20)
    at tryOnImmediate (timers.js:768:5)
    at processImmediate [as _immediateCallback] (timers.js:745:5)
2020-02-11T09:03:49.420Z FTL/util:lifecycle 14563 [LMX420ZD6PNB9P9PHI] Shutting down due to fatal error
2020-02-11T09:03:49.433Z INF/provider 8083 [*] Cleaning up device worker "LMX420ZD6PNB9P9PHI"
2020-02-11T09:03:49.433Z ERR/provider 8083 [*] Device worker "LMX420ZD6PNB9P9PHI" died with code 1
2020-02-11T09:03:49.433Z INF/provider 8083 [*] Restarting device worker "LMX420ZD6PNB9P9PHI"
2020-02-11T09:03:50.435Z INF/device:support:push 20440 [LMX420ZD6PNB9P9PHI] Sending output to "tcp://127.0.0.1:7116"
2020-02-11T09:03:50.442Z INF/device 20440 [LMX420ZD6PNB9P9PHI] Preparing device
2020-02-11T09:03:51.022Z INF/device:support:sub 20440 [LMX420ZD6PNB9P9PHI] Receiving input from "tcp://127.0.0.1:7114"
2020-02-11T09:03:51.023Z INF/device:support:sub 20440 [LMX420ZD6PNB9P9PHI] Subscribing to permanent channel "*ALL"
2020-02-11T09:03:51.094Z INF/device:support:properties 20440 [LMX420ZD6PNB9P9PHI] Loading properties
2020-02-11T09:03:51.209Z INF/device:support:sdk 20440 [LMX420ZD6PNB9P9PHI] Supports SDK 28
2020-02-11T09:03:51.209Z INF/device:support:abi 20440 [LMX420ZD6PNB9P9PHI] Supports ABIs armeabi-v7a, armeabi
2020-02-11T09:03:51.655Z INF/device:resources:minicap 20440 [LMX420ZD6PNB9P9PHI] Installing "/usr/lib/node_modules/stf/node_modules/minicap-prebuilt/prebuilt/armeabi-v7a/bin/minicap" as "/data/local/tmp/minicap"
2020-02-11T09:03:51.656Z INF/device:resources:minicap 20440 [LMX420ZD6PNB9P9PHI] Installing "/usr/lib/node_modules/stf/node_modules/minicap-prebuilt/prebuilt/armeabi-v7a/lib/android-28/minicap.so" as "/data/local/tmp/minicap.so"
2020-02-11T09:03:51.816Z INF/device:resources:service 20440 [LMX420ZD6PNB9P9PHI] Checking whether we need to install STFService
2020-02-11T09:03:51.919Z INF/device:resources:service 20440 [LMX420ZD6PNB9P9PHI] Running version check
2020-02-11T09:03:52.629Z INF/device:resources:service 20440 [LMX420ZD6PNB9P9PHI] STFService up to date
2020-02-11T09:03:52.634Z INF/device:plugins:service 20440 [LMX420ZD6PNB9P9PHI] Launching agent
2020-02-11T09:03:53.882Z INF/device:plugins:service 20440 [LMX420ZD6PNB9P9PHI] Launching service
2020-02-11T09:03:53.883Z INF/device:plugins:service 20440 [LMX420ZD6PNB9P9PHI] using 'start-foreground-service' command for API 28
2020-02-11T09:03:53.942Z INF/device:plugins:service 20440 [LMX420ZD6PNB9P9PHI] Agent says: "Listening on @stfagent"
2020-02-11T09:03:53.946Z INF/device:plugins:service 20440 [LMX420ZD6PNB9P9PHI] Agent says: "InputClient started"
2020-02-11T09:03:54.001Z INF/device:plugins:display 20440 [LMX420ZD6PNB9P9PHI] Reading display info
2020-02-11T09:03:54.054Z INF/device:plugins:phone 20440 [LMX420ZD6PNB9P9PHI] Fetching phone info
2020-02-11T09:03:54.083Z INF/device:plugins:identity 20440 [LMX420ZD6PNB9P9PHI] Solving identity
2020-02-11T09:03:54.094Z INF/device:plugins:solo 20440 [LMX420ZD6PNB9P9PHI] Subscribing to permanent channel "nd66x8UCSNGrUP/+EhJwq7iwpxo="
2020-02-11T09:03:54.098Z INF/device:plugins:screen:stream 20440 [LMX420ZD6PNB9P9PHI] Starting WebSocket server on port 7448
2020-02-11T09:03:54.543Z INF/device:resources:minitouch 20440 [LMX420ZD6PNB9P9PHI] Installing "/usr/lib/node_modules/stf/node_modules/minitouch-prebuilt/prebuilt/armeabi-v7a/bin/minitouch" as "/data/local/tmp/minitouch"
2020-02-11T09:03:54.619Z WRN/device:plugins:data 20440 [LMX420ZD6PNB9P9PHI] Unable to find device data { serial: 'LMX420ZD6PNB9P9PHI',
  platform: 'Android',
  manufacturer: 'LGE',
  operator: null,
  model: 'LM-X420',
  version: '9',
  abi: 'armeabi-v7a',
  sdk: '28',
  product: 'mmh4_f',
  cpuPlatform: 'mt6765',
  openGLESVersion: '3.2',
  marketName: 'LM-X420',
  display: 
   { id: 0,
     width: 720,
     height: 1440,
     xdpi: 281.3529968261719,
     ydpi: 281.3529968261719,
     fps: 60.68000030517578,
     density: 1.75,
     rotation: 0,
     secure: true,
     size: 5.722238476082536,
     url: 'ws://172.28.200.168:7448' },
  phone: { network: 'UNKNOWN' } }
2020-02-11T09:03:54.631Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] Touch origin is top left
2020-02-11T09:03:54.633Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] Requesting touch consumer to start
2020-02-11T09:03:54.635Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] Launching touch service
2020-02-11T09:03:54.648Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] Connecting to minitouch service
2020-02-11T09:03:54.693Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] minitouch says: "Note: device /dev/input/mice is not supported by libevdev"
2020-02-11T09:03:54.694Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] minitouch says: "Type B touch device touch_dev (719x1439 with 10 contacts) detected on /dev/input/event2 (score 22026)"
2020-02-11T09:03:54.804Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] Reading minitouch banner
2020-02-11T09:03:54.843Z INF/device:plugins:touch 20440 [LMX420ZD6PNB9P9PHI] minitouch says: "Connection established"
2020-02-11T09:03:54.859Z INF/device:plugins:vnc 20440 [LMX420ZD6PNB9P9PHI] Starting VNC server on port 7450
2020-02-11T09:03:54.864Z INF/device:plugins:browser 20440 [LMX420ZD6PNB9P9PHI] Loading browser list
2020-02-11T09:03:54.891Z INF/device:plugins:browser 20440 [LMX420ZD6PNB9P9PHI] Updating browser list
2020-02-11T09:03:54.899Z INF/device:plugins:mute 20440 [LMX420ZD6PNB9P9PHI] Will not mute master volume
2020-02-11T09:03:55.355Z INF/device:resources:minirev 20440 [LMX420ZD6PNB9P9PHI] Installing "/usr/lib/node_modules/stf/vendor/minirev/armeabi-v7a/minirev" as "/data/local/tmp/minirev"
2020-02-11T09:03:55.434Z INF/device:plugins:forward 20440 [LMX420ZD6PNB9P9PHI] Launching reverse port forwarding service
2020-02-11T09:03:55.445Z INF/device:plugins:forward 20440 [LMX420ZD6PNB9P9PHI] Connecting to reverse port forwarding service
2020-02-11T09:03:55.608Z INF/device 20440 [LMX420ZD6PNB9P9PHI] Fully operational

In STF gui it comes up, but as soon as you click on the phone, you get device was disconnected and someone stole the phone

Software info on the phone
IMG_20200211_112009_2

Any suggestion please? Phone is a LG K40

@man4567890
Copy link

I think the main problem could be the 32 bit and 64 bit issue as the minicap from

Hi @varundtsfi
Here is the minicap.so I successfully tested on my G6 (API level 28). To overcome the different Vector types issue, the AOSP libgui (Apache v2) has been statically compiled and merged in minicap.so (that's why it is much bigger). To test it, you will have to replace prebuilt/arm64-v8a/lib/android-28/minicap.so with this file.

is 64 bit and the K40 that I have is 32 bit, it looks like? Or am I completely wrong?

platform: 'Android',
manufacturer: 'LGE',
operator: null,
model: 'LM-X420',
version: '9',
abi: 'armeabi-v7a',
sdk: '28',
product: 'mmh4_f',
cpuPlatform: 'mt6765',
openGLESVersion: '3.2',
marketName: 'LM-X420',
display:
{ id: 0,
width: 720,
height: 1440,
xdpi: 281.3529968261719,
ydpi: 281.3529968261719,
fps: 60.68000030517578,
density: 1.75,
rotation: 0,
secure: true,
size: 5.722238476082536,
url: 'ws://172.28.200.168:7572' },
phone: { network: 'UNKNOWN' } }

Does anyone have a 32bit pre compiled minicap on SDK 28 for the LG please, if what I think is the problem, is correct?

@varundtsfi
Copy link

Hi @man4567890
I don't have but If you can wait for one day then I can give it to you for 32 bit. One more thing I don't have a device for abi: 'armeabi-v7a', configuration so I can't test.

@varundtsfi
Copy link

Actually you are getting the same error which you were getting in Android-SDK 28. Might be the solution for Android 9 will work for Android-10. I need to build AOSP for android 10 but again I don't have physical device to test. This will take time because My system is not so heavy and its normal system having 8 GB Ram. AOSP Build take around 8 to 9 hrs. You have to wait for @man4567890

@man4567890
Copy link

Thanks so much @varundtsfi , I can test for you, I will wait

@man4567890
Copy link

Hi @varundtsfi , did you manage to build the Android 10 LG build, please?

@man4567890
Copy link

man4567890 commented Feb 15, 2020 via email

@varundtsfi
Copy link

@man4567890 Might be monday morning I can.

@man4567890
Copy link

man4567890 commented Feb 17, 2020 via email

@albertiniLiu
Copy link

@varundtsfi
I meet the same issue on Mi10 phone.
Could you please compile a arm64 version for me?
Thanks in advance.

I try to build myself as pcrepieux told method. But meet many build errors.

@varundtsfi
Copy link

varundtsfi commented Feb 20, 2020

@varundtsfi
I meet the same issue on Mi10 phone.
Could you please compile a arm64 version for me?
Thanks in advance.

I try to build myself as pcrepieux told method. But meet many build errors.

Hi @albertiniLiu and @man4567890
My System got crashed two days back and Today only I setup the system again. I am downloading the AOSP of 9 and 10. Once its done. I will try to build it. Might be on Sunday I can deliver the required binaries.

@albertiniLiu What is Mi10 Please provide the details like MIUI and Android version. Because its coming in MIUI 11 version devices only.

@albertiniLiu
Copy link

albertiniLiu commented Feb 21, 2020

hi @varundtsfi

My Mi10 phone information hope it's enouch for your:
SW information as below:
[ro.build.version.incremental]: [V11.0.4.0.QJACNXM]
[ro.build.version.min_supported_target_sdk]: [23]
[ro.build.version.preview_sdk]: [0]
[ro.build.version.preview_sdk_fingerprint]: [REL]
[ro.build.version.release]: [10]
[ro.build.version.sdk]: [29]
[ro.build.version.security_patch]: [2020-01-01]

@varundtsfi
Copy link

varundtsfi commented Feb 21, 2020

Hi @albertiniLiu

Please send the required information as it unnecessary increasing the length.
Only below information was fine.
[ro.product.build.version.sdk]: [29]
[ro.product.cpu.abi]: [arm64-v8a]
[ro.build.version.incremental]: [V11.0.4.0.QJACNXM]
. If you read my requirement, it was only MIUI and Android Version of your device. If possible edit your device details so that It became short and readable to others also.
Thanks for the information.

@koral-- koral-- added the bug label Feb 21, 2020
@albertiniLiu
Copy link

@varundtsfi

Already edit my message as you requested.

@man4567890
Copy link

man4567890 commented Feb 27, 2020 via email

@man4567890
Copy link

man4567890 commented Mar 3, 2020 via email

@varundtsfi
Copy link

I have tried few fixes on android 10 for LG and Xiaomi devices but did not get any success.. so I don't have any ETA just HIT and Trial..

@man4567890
Copy link

man4567890 commented Mar 5, 2020 via email

@man4567890
Copy link

man4567890 commented Mar 13, 2020

Seems there is a problem on the LG - LM-G820 with Android 10 as well, arm64-v8a, but it seems that it is minitouch that is complaining

`2020-03-13T07:00:49.855Z INF/device:plugins:group 20905 [LMG820UMb681bd28] Subscribing to group channel "27wYow6vQ7KHx53MvmzFQw=="

2020-03-13T07:00:50.693Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Setting frame producer projection to 843x843

2020-03-13T07:00:50.693Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Requesting frame producer to start

2020-03-13T07:00:50.694Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Launching screen service

2020-03-13T07:00:50.814Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "PID: 30890"

2020-03-13T07:00:50.814Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: Using projection 1080x2340@389x843/0"

2020-03-13T07:00:50.814Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:241) Creating SurfaceComposerClient"

2020-03-13T07:00:50.815Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Connecting to minicap service

2020-03-13T07:00:50.817Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:244) Performing SurfaceComposerClient init check"

2020-03-13T07:00:50.817Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:255) Creating virtual display"

2020-03-13T07:00:50.817Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:261) Creating buffer queue"

2020-03-13T07:00:50.817Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:264) Setting buffer options"

2020-03-13T07:00:50.818Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:268) Creating CPU consumer"

2020-03-13T07:00:50.818Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:272) Creating frame waiter"

2020-03-13T07:00:50.819Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "INFO: (external/MY_minicap/src/minicap_29.cpp:276) Publishing virtual display"

2020-03-13T07:00:50.819Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "Vector<> have different types (this=0x7ff81d0190, rhs=0x7ff81d02e0)"

2020-03-13T07:00:50.961Z WRN/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Shell keeping minicap running ended unexpectedly

2020-03-13T07:00:52.611Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Disconnecting from minicap service

2020-03-13T07:00:52.612Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Stopping minicap service

2020-03-13T07:00:52.613Z FTL/device:plugins:screen:stream 20905 [LMG820UMb681bd28] Frame producer had an error FailError: Failure: 'closed'

at /usr/lib/node_modules/stf/node_modules/adbkit/lib/adb/parser.js:183:29
at runCallback (timers.js:810:20)
at tryOnImmediate (timers.js:768:5)
at processImmediate [as _immediateCallback] (timers.js:745:5)

2020-03-13T07:00:52.613Z FTL/util:lifecycle 20905 [LMG820UMb681bd28] Shutting down due to fatal error

2020-03-13T07:00:52.619Z INF/provider 17188 [*] Cleaning up device worker "LMG820UMb681bd28"

2020-03-13T07:00:52.620Z ERR/provider 17188 [*] Device worker "LMG820UMb681bd28" died with code 1

2020-03-13T07:00:52.620Z INF/provider 17188 [*] Restarting device worker "LMG820UMb681bd28"

2020-03-13T07:00:53.405Z INF/device:support:push 27538 [LMG820UMb681bd28] Sending output to "tcp://127.0.0.1:7116"

2020-03-13T07:00:53.408Z INF/device 27538 [LMG820UMb681bd28] Preparing device

2020-03-13T07:00:53.715Z INF/device:support:sub 27538 [LMG820UMb681bd28] Receiving input from "tcp://127.0.0.1:7114"

2020-03-13T07:00:53.716Z INF/device:support:sub 27538 [LMG820UMb681bd28] Subscribing to permanent channel "*ALL"

2020-03-13T07:00:53.815Z INF/device:support:properties 27538 [LMG820UMb681bd28] Loading properties

2020-03-13T07:00:53.909Z INF/device:support:sdk 27538 [LMG820UMb681bd28] Supports SDK 29

2020-03-13T07:00:53.909Z INF/device:support:abi 27538 [LMG820UMb681bd28] Supports ABIs arm64-v8a, armeabi-v7a, armeabi

2020-03-13T07:00:54.259Z INF/device:resources:minicap 27538 [LMG820UMb681bd28] Installing "/usr/lib/node_modules/stf/node_modules/minicap-prebuilt/prebuilt/arm64-v8a/bin/minicap" as "/data/local/tmp/minicap"

2020-03-13T07:00:54.260Z INF/device:resources:minicap 27538 [LMG820UMb681bd28] Installing "/usr/lib/node_modules/stf/node_modules/minicap-prebuilt/prebuilt/arm64-v8a/lib/android-29/minicap.so" as "/data/local/tmp/minicap.so"

2020-03-13T07:00:54.629Z INF/device:resources:service 27538 [LMG820UMb681bd28] Checking whether we need to install STFService

2020-03-13T07:00:54.719Z INF/device:resources:service 27538 [LMG820UMb681bd28] Running version check

2020-03-13T07:00:55.109Z INF/device:resources:service 27538 [LMG820UMb681bd28] STFService up to date

2020-03-13T07:00:55.110Z INF/device:plugins:service 27538 [LMG820UMb681bd28] Launching agent

2020-03-13T07:00:55.867Z INF/device:plugins:service 27538 [LMG820UMb681bd28] Agent says: "Starting minitouch agent"

2020-03-13T07:00:55.881Z INF/device:plugins:service 27538 [LMG820UMb681bd28] Agent says: "Listening on @stfagent"

2020-03-13T07:00:55.935Z INF/device:plugins:service 27538 [LMG820UMb681bd28] Launching service

2020-03-13T07:00:55.936Z INF/device:plugins:service 27538 [LMG820UMb681bd28] using 'start-foreground-service' command for API 29

2020-03-13T07:00:55.948Z INF/device:plugins:service 27538 [LMG820UMb681bd28] Agent says: "InputClient started"

2020-03-13T07:00:56.052Z INF/device:plugins:display 27538 [LMG820UMb681bd28] Reading display info

2020-03-13T07:00:56.101Z INF/device:plugins:phone 27538 [LMG820UMb681bd28] Fetching phone info

2020-03-13T07:00:56.139Z INF/device:plugins:identity 27538 [LMG820UMb681bd28] Solving identity

2020-03-13T07:00:56.139Z INF/device:plugins:solo 27538 [LMG820UMb681bd28] Subscribing to permanent channel "SnAEz7FrWHnEcjuAY/KjF3gPBNQ="

2020-03-13T07:00:56.141Z INF/device:plugins:screen:stream 27538 [LMG820UMb681bd28] Starting WebSocket server on port 7488

2020-03-13T07:00:56.423Z INF/device:resources:minitouch 27538 [LMG820UMb681bd28] Installing "/usr/lib/node_modules/stf/node_modules/minitouch-prebuilt/prebuilt/arm64-v8a/bin/minitouch" as "/data/local/tmp/minitouch"

2020-03-13T07:00:56.636Z WRN/device:plugins:data 27538 [LMG820UMb681bd28] Unable to find device data { serial: 'LMG820UMb681bd28',

platform: 'Android',
manufacturer: 'LGE',
operator: '',
model: 'LM-G820',
version: '10',
abi: 'arm64-v8a',
sdk: '29',
product: 'alphalm_lao_com',
cpuPlatform: 'msmnile',
openGLESVersion: '3.2',
display:
{ id: 0,
width: 1080,
height: 2340,
xdpi: 422.03021240234375,
ydpi: 424.5427551269531,
fps: 60.000003814697266,
density: 2.625,
rotation: 0,
secure: true,
size: 6.0769116941916055,
url: 'ws://10.119.102.86:7488' },
phone: { network: 'UNKNOWN' } }

2020-03-13T07:00:56.639Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] Touch origin is top left

2020-03-13T07:00:56.640Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] Requesting touch consumer to start

2020-03-13T07:00:56.640Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] Launching touch service

2020-03-13T07:00:56.679Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] Connecting to minitouch service

2020-03-13T07:00:56.736Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "open: Permission denied"

2020-03-13T07:00:56.736Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event7 for inspectionopen: Permission denied"

2020-03-13T07:00:56.736Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event6 for inspectionopen: Permission denied"

2020-03-13T07:00:56.737Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event1 for inspectionopen: Permission denied"

2020-03-13T07:00:56.737Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event4 for inspectionopen: Permission denied"

2020-03-13T07:00:56.737Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event3 for inspectionopen: Permission denied"

2020-03-13T07:00:56.737Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/mice for inspectionopen: Permission denied"

2020-03-13T07:00:56.738Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event2 for inspectionopen: Permission denied"

2020-03-13T07:00:56.738Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event0 for inspectionopen: Permission denied"

2020-03-13T07:00:56.738Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event5 for inspectionUnable to find a suitable touch device"

2020-03-13T07:00:56.738Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "using Android InputManager"

2020-03-13T07:00:56.856Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] Reading minitouch banner

2020-03-13T07:00:56.898Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Connection established"

2020-03-13T07:00:56.904Z INF/device:plugins:vnc 27538 [LMG820UMb681bd28] Starting VNC server on port 7490

2020-03-13T07:00:56.906Z INF/device:plugins:browser 27538 [LMG820UMb681bd28] Loading browser list

2020-03-13T07:00:56.939Z INF/device:plugins:browser 27538 [LMG820UMb681bd28] Updating browser list

2020-03-13T07:00:56.939Z WRN/device:plugins:browser 27538 [LMG820UMb681bd28] Unmapped browser "com.airfind.deltabrowser"

2020-03-13T07:00:56.940Z INF/device:plugins:mute 27538 [LMG820UMb681bd28] Will not mute master volume

2020-03-13T07:00:57.223Z INF/device:resources:minirev 27538 [LMG820UMb681bd28] Installing "/usr/lib/node_modules/stf/vendor/minirev/arm64-v8a/minirev" as "/data/local/tmp/minirev"

2020-03-13T07:00:57.437Z INF/device:plugins:forward 27538 [LMG820UMb681bd28] Launching reverse port forwarding service

2020-03-13T07:00:57.478Z INF/device:plugins:forward 27538 [LMG820UMb681bd28] Connecting to reverse port forwarding service
2020-03-13T07:00:57.654Z INF/device 27538 [LMG820UMb681bd28] Fully operational`

@varundtsfi
Copy link

Hi @man4567890

You have two issue here:-

2020-03-13T07:00:50.819Z INF/device:plugins:screen:stream 20905 [LMG820UMb681bd28] minicap says: "Vector<> have different types (this=0x7ff81d0190, rhs=0x7ff81d02e0)"

2020-03-13T07:00:56.736Z INF/device:plugins:touch 27538 [LMG820UMb681bd28] minitouch says: "Unable to open device /dev/input/event7 for inspectionopen: Permission denied"

In android 10 you cannot user third party libs for handling touch actions. second again the vector.
So if you resolve the issue for touch then also that device will not because this will not produce display.

This entire thread is discussing about the vector issue and still we are struggling for the solution.
"Vector<> have different types (this=0x7ff81d0190, rhs=0x7ff81d02e0)"

@HEZI0427
Copy link

HEZI0427 commented Apr 18, 2020

@Ethan-2013
Sure, will post instruction shortly (didn't find the time to do it earlier...).
That's basically adding a cc_library_static block in libgui's Android.bp file and a few change in minicap-shared Makefile. More or less... stay tuned.
Sorry for the delay.
...
Here you are.

  • in $AOSP/frameworks/native/libs/gui/Android.bp

    • make a copy of the cc_library_shared block and change cc_library_shared to cc_library_static
    • give it another name ... like libgui_s
  • in $MINICAP/jni/minicap-shared/aosp/Android.mk

  • Compile minicap-shared

I only tested on android 9, so you might have to adjust a few things to have it working on Android 10.

I also do this(modify Android 9.0 gui lib Android.bp ),after get libgui_s,when compile minicap but get error bleow:
image

but libgui_s.a has generated,

image

can you help me ~~~

@huhuang03
Copy link

huhuang03 commented Apr 24, 2020

@varundtsfi Have you solved the xiaomi api28 black screen issue? I have the same issue, and I will try to follow the build by aosp step..

@varundtsfi
Copy link

varundtsfi commented Apr 29, 2020

It's still there and I haven't spent much time on it because I don't have Xiaomi device

@maykonpacheco
Copy link

maykonpacheco commented Dec 7, 2022

Hi @pcrepieux Sorry for the delay. I don't have LG G6 right now but I will buy this asap. Right Now I have LG G7 Thinq running on Android 9. Model Number: LMG710EMW LG G7 thinq

And Getting the below error. Vector<> have different types (this=0x7fc7d7f700, rhs=0x7fc7d7f820)

Hi @varundtsfi, I also have LG G7 Thinq running on Android 9. Model Number: LMG710EMW , could you explain to me the steps that you said to make the minicap work on your cell phone? I have no idea how to add the minicap to my cell phone.

@varundtsfi
Copy link

Hi @pcrepieux Sorry for the delay. I don't have LG G6 right now but I will buy this asap. Right Now I have LG G7 Thinq running on Android 9. Model Number: LMG710EMW LG G7 thinq
And Getting the below error. Vector<> have different types (this=0x7fc7d7f700, rhs=0x7fc7d7f820)

Hi @varundtsfi, I also have LG G7 Thinq running on Android 9. Model Number: LMG710EMW , could you explain to me the steps that you said to make the minicap work on your cell phone? I have no idea how to add the minicap to my cell phone.

Hi @maykonpacheco

Have the similar device which is working fine. So what you want do you want Pre-compiled Binaries or Just the solution?
LG_G7_Thinq

If you need Pre-built binaries get these from here https://github.com/varundtsfi/Xiaomi_Vector_issue/tree/main/LG

if you need solution perform the following steps:-
There is a file called LayerState.h in android aosp. AOSP/frameworks/native/libs/gui/include/gui/LayerState.h

in this file one int array uint8_t _dummy is there just change the current value to 8 and Build the code again.

Sorry for the delay

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

No branches or pull requests