Android 9 - Issues

  1. EGL crash when launching XBMC/Kodi
  2. Opengapps: Missing remote service “AtvRemoteService”
  3. Opengapps: Missing cast receiver “AndroidMediaShell”
  4. HDMI CEC doesn’t seem to work. When I press “home” on rk3399 box, the TV does NOT turn on.

Overall, I’m extremely impressed by the state of Android 9 for this hardware.

Can you provide a logcat after Kodi crashes?
Also try getprop | grep mali and post all the logs then Rockchip can look into the EGL crash issue.

So now the first of those issues is fixed.
The second issue is easily fixed by just copying the files into place.

The third issue isn’t as simple to solve, and seems to be tied to a failure in the widevine l3 implementation. That is probably the next most important thing that needs to be fixed.

@Lili , @jack : Would anybody at radxa care to comment on these issues and begin to address them?

Some apps that might help:

AndroidMediaShell only works on the Nvidia Shield and MiBox, it needs signed keys by Google that won’t release it for open-source, non Google Certified devices. On OpenGapps’s Github page they also say this app doesn’t work anymore.
If you add the app, it will give force close messages the whole time or just do nothing. Adding Widevine L3 won’t help with this.

AtvRemoteService app can just be added then it will work with the 2 Android phone remote control apps in the Play Store.

Try an app like Cetus Play for remote control.
If it doesn’t work properly, someone can ask them to add support or Radxa can do tests perhaps and contact them.

For Kodi remote control, an app like Yatse works well.

Getting a cheap airmouse controller works the best.
eg. https://www.gearbest.com/air-mouse/pp_639444.html?wid=1433363
https://www.gearbest.com/air-mouse/pp_009939434747.html?wid=1433363

The Rockchip Wifi Display app can connect with Wifi Display on your phone if you need to mirror the screen.
The DLNA app can help to receive casted videos from a phone casting app.
There is also a Chinese app, Happycast that you can install, the layout will be Chinese but the settings menu is English and it can also receive casted video from a phone app like BubbleUPNP etc.

Try to rename MOVE_HOME in system/usr/keylayout/Generic.kl to HOME.
It will fix the Home key on external keyboards, not sure if it will do anything to HDMI CEC. For some tv’s like LG, extra firmware patches are needed to make HDMI CEC work as LG uses a non standard method.

I am merging the latest rk code, these problems will be verified on the latest version

1 Like

LILI - Great work will your “merging” fix the other issue where google play apps just crash ?

Just to keep all the observable issues contained in one thread, there is also an issue with volume control. Specifically, there is a volume control enabled, even for strictly HDMI output. It is a software volume controller that works in the digital domain, which means that even during playback via HDMI, the volume can be lowered from maximum. HDMI should only output at full volume so that the maximum number of bits are sent to the receiver (television), which has its own volume control.

I’ve observed that it resets to a low volume every time the board is rebooted, requiring that the volume be raised. The only way I’m aware of to raise the volume is by plugging in an external keyboard with volume keys, which is inconvenient.

Regarding the HDMI CEC, here is a log excerpt;

# logcat | grep -i cec                                                                                                                                                                          
07-04 09:55:13.871   255   275 D hdmicec : poll revent:02
07-04 09:55:13.872   255   275 I hdmicec : poll receive event
07-04 09:55:13.872   255   275 D hdmicec : event:1
07-04 09:55:13.872   255   275 D hdmicec : adapt state change,phy_addr:ffff,flags:2
07-04 09:55:13.892   255   275 D hdmicec : poll revent:02
07-04 09:55:13.892   255   275 I hdmicec : poll receive event
07-04 09:55:13.892   255   275 D hdmicec : event:5
07-04 09:55:13.892   255   275 I hdmicec : CEC_EVENT_PIN_HPD_LOW
07-04 09:55:14.906   258  1132 D RKATVAudioPolicyManager: setDeviceConnectionState() this= 0xf2ef2000, device: 0x400, state 0, address  name 
07-04 09:55:22.230   255   275 D hdmicec : poll revent:02
07-04 09:55:22.230   255   275 I hdmicec : poll receive event
07-04 09:55:22.230   255   275 D hdmicec : event:6
07-04 09:55:22.230   255   275 I hdmicec : CEC_EVENT_PIN_HPD_HIGH
07-04 09:55:22.234   255   255 I hdmicec : hdmi_cec_clear_logical_address
07-04 09:55:22.234   255   275 D hdmicec : poll revent:02
07-04 09:55:22.234   255   275 I hdmicec : poll receive event
07-04 09:55:22.234   255   275 D hdmicec : event:1
07-04 09:55:22.234   255   275 D hdmicec : adapt state change,phy_addr:ffff,flags:0
07-04 09:55:22.234   255   255 D hdmicec : kernel logic addr:ff, preferred logic addr:04
07-04 09:55:22.235   255   255 I hdmicec : kernel logaddr is not existing
07-04 09:55:22.235   255   255 D hdmicec : set_kernel_logical_address, logic addr:04
07-04 09:55:22.235   255   255 I hdmicec : primary_device_type:04,log_addr_type:03,log_addr[0]:ff
07-04 09:55:22.235   255   255 E hdmicec : phy addr not ready
07-04 09:55:22.242   258   258 D RKATVAudioPolicyManager: setDeviceConnectionState() this= 0xf2ef2000, device: 0x400, state 1, address  name 
07-04 09:55:22.435   255   255 E hdmicec : phy addr not ready
07-04 09:55:22.447   255   275 D hdmicec : poll revent:02
07-04 09:55:22.447   255   275 I hdmicec : poll receive event
07-04 09:55:22.447   255   275 D hdmicec : event:1
07-04 09:55:22.447   255   275 D hdmicec : adapt state change,phy_addr:2000,flags:0
07-04 09:55:22.476   255   275 D hdmicec : poll revent:02
07-04 09:55:22.476   255   275 I hdmicec : poll receive event
07-04 09:55:22.476   255   275 D hdmicec : event:1
07-04 09:55:22.476   255   275 D hdmicec : adapt state change,phy_addr:2000,flags:0
07-04 09:55:22.567   460   460 I HdmiCecLocalDevice: Not ready to start action. Queued for deferred start:com.android.server.hdmi.DevicePowerStatusAction@66f7e18
07-04 09:55:22.636   255   255 D hdmicec : kernel logic addr:04, preferred logic addr:04
07-04 09:55:22.636   255   255 I hdmicec : kernel logaddr is existing
07-04 09:55:22.636   255   255 I hdmicec : kernel logaddr is preferred logaddr
07-04 09:55:22.636   255   255 D hdmicec : kernel logic addr:04, preferred logic addr:04
07-04 09:55:22.637   255   255 I hdmicec : kernel logaddr is existing
07-04 09:55:22.637   255   255 I hdmicec : kernel logaddr is preferred logaddr
07-04 09:55:22.637   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:22.638   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:22.638   255   255 I hdmicec : hdmi_cec_get_vendor_id
07-04 09:55:22.639   255   255 D hdmicec : set_kernel_logical_address, logic addr:04
07-04 09:55:22.639   255   255 I hdmicec : primary_device_type:04,log_addr_type:03,log_addr[0]:04
07-04 09:55:22.639   255   255 D hdmicec : LA is existing, not need to set logic addr
07-04 09:55:22.639   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:22.640   255   255 I hdmicec : hdmi_cec_get_vendor_id
07-04 09:55:22.640   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:22.640   255   255 I hdmicec : send msg LEN:5,opcode:84,addr:4f
07-04 09:55:22.640   460   460 I HdmiCecLocalDevice: Starting queued action:com.android.server.hdmi.DevicePowerStatusAction@66f7e18
07-04 09:55:22.768   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:22.768   255   255 I hdmicec : send msg LEN:5,opcode:87,addr:4f
07-04 09:55:22.896   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:22.896   255   255 I hdmicec : send msg LEN:4,opcode:82,addr:4f
07-04 09:55:22.999   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:23.000   255   255 I hdmicec : send msg LEN:2,opcode:0d,addr:40
07-04 09:55:23.029   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:23.330   255   255 I hdmicec : send msg LEN:2,opcode:0d,addr:40
07-04 09:55:23.359   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:23.659   460   571 W HdmiCecController: Failed to send <Text View On> src: 4, dst: 0 with errorCode=1
07-04 09:55:23.660   255   255 I hdmicec : send msg LEN:2,opcode:8f,addr:40
07-04 09:55:23.690   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:23.991   255   255 I hdmicec : send msg LEN:2,opcode:8f,addr:40
07-04 09:55:24.020   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:24.321   460   571 W HdmiCecController: Failed to send <Give Device Power Status> src: 4, dst: 0 with errorCode=1
07-04 09:55:26.511   255   275 D hdmicec : poll revent:02
07-04 09:55:26.511   255   275 I hdmicec : poll receive event
07-04 09:55:26.512   255   275 D hdmicec : event:1
07-04 09:55:26.512   255   275 D hdmicec : adapt state change,phy_addr:ffff,flags:2
07-04 09:55:26.535   255   275 D hdmicec : poll revent:02
07-04 09:55:26.535   255   275 I hdmicec : poll receive event
07-04 09:55:26.535   255   275 D hdmicec : event:5
07-04 09:55:26.535   255   275 I hdmicec : CEC_EVENT_PIN_HPD_LOW
07-04 09:55:27.299   255   275 D hdmicec : poll revent:02
07-04 09:55:27.299   255   275 I hdmicec : poll receive event
07-04 09:55:27.299   255   275 D hdmicec : event:6
07-04 09:55:27.299   255   275 I hdmicec : CEC_EVENT_PIN_HPD_HIGH
07-04 09:55:27.300   255   255 I hdmicec : hdmi_cec_clear_logical_address
07-04 09:55:27.300   255   275 D hdmicec : poll revent:02
07-04 09:55:27.300   255   275 I hdmicec : poll receive event
07-04 09:55:27.300   255   275 D hdmicec : event:1
07-04 09:55:27.300   255   275 D hdmicec : adapt state change,phy_addr:ffff,flags:0
07-04 09:55:27.301   255   255 D hdmicec : kernel logic addr:ff, preferred logic addr:04
07-04 09:55:27.301   255   255 I hdmicec : kernel logaddr is not existing
07-04 09:55:27.301   255   255 D hdmicec : set_kernel_logical_address, logic addr:04
07-04 09:55:27.301   255   255 I hdmicec : primary_device_type:04,log_addr_type:03,log_addr[0]:ff
07-04 09:55:27.301   255   255 E hdmicec : phy addr not ready
07-04 09:55:27.501   255   255 E hdmicec : phy addr not ready
07-04 09:55:27.540   258   290 D RKATVAudioPolicyManager: setDeviceConnectionState() this= 0xf2ef2000, device: 0x400, state 0, address  name 
07-04 09:55:27.578   258   290 D RKATVAudioPolicyManager: setDeviceConnectionState() this= 0xf2ef2000, device: 0x400, state 1, address  name 
07-04 09:55:27.701   255   255 E hdmicec : phy addr not ready
07-04 09:55:27.902   255   255 E hdmicec : phy addr not ready
07-04 09:55:27.968   255   275 D hdmicec : poll revent:02
07-04 09:55:27.968   255   275 I hdmicec : poll receive event
07-04 09:55:27.968   255   275 D hdmicec : event:1
07-04 09:55:27.968   255   275 D hdmicec : adapt state change,phy_addr:2000,flags:0
07-04 09:55:27.998   255   275 D hdmicec : poll revent:02
07-04 09:55:27.999   255   275 I hdmicec : poll receive event
07-04 09:55:27.999   255   275 D hdmicec : event:1
07-04 09:55:27.999   255   275 D hdmicec : adapt state change,phy_addr:2000,flags:0
07-04 09:55:28.070   460   460 I HdmiCecLocalDevice: Not ready to start action. Queued for deferred start:com.android.server.hdmi.DevicePowerStatusAction@4743071
07-04 09:55:28.102   255   255 D hdmicec : kernel logic addr:04, preferred logic addr:04
07-04 09:55:28.102   255   255 I hdmicec : kernel logaddr is existing
07-04 09:55:28.102   255   255 I hdmicec : kernel logaddr is preferred logaddr
07-04 09:55:28.102   255   255 D hdmicec : kernel logic addr:04, preferred logic addr:04
07-04 09:55:28.102   255   255 I hdmicec : kernel logaddr is existing
07-04 09:55:28.102   255   255 I hdmicec : kernel logaddr is preferred logaddr
07-04 09:55:28.103   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:28.103   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:28.103   255   255 I hdmicec : hdmi_cec_get_vendor_id
07-04 09:55:28.103   255   255 D hdmicec : set_kernel_logical_address, logic addr:04
07-04 09:55:28.103   255   255 I hdmicec : primary_device_type:04,log_addr_type:03,log_addr[0]:04
07-04 09:55:28.103   255   255 D hdmicec : LA is existing, not need to set logic addr
07-04 09:55:28.104   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:28.104   255   255 I hdmicec : hdmi_cec_get_vendor_id
07-04 09:55:28.104   255   255 I hdmicec : send msg LEN:5,opcode:84,addr:4f
07-04 09:55:28.252   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:28.253   255   255 I hdmicec : hdmi_cec_get_physical_address val = 2000
07-04 09:55:28.253   255   255 I hdmicec : send msg LEN:5,opcode:87,addr:4f
07-04 09:55:28.253   460   460 I HdmiCecLocalDevice: Starting queued action:com.android.server.hdmi.DevicePowerStatusAction@4743071
07-04 09:55:28.260   460   460 W Looper  : Slow dispatch took 157ms main h=android.os.Handler c=com.android.server.hdmi.HdmiCecController$4@7ea63c4 m=0
07-04 09:55:28.380   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:28.381   255   255 I hdmicec : send msg LEN:4,opcode:82,addr:4f
07-04 09:55:28.484   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:28.485   255   255 I hdmicec : send msg LEN:2,opcode:0d,addr:40
07-04 09:55:28.514   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:28.815   255   255 I hdmicec : send msg LEN:2,opcode:0d,addr:40
07-04 09:55:28.844   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:29.145   460   571 W HdmiCecController: Failed to send <Text View On> src: 4, dst: 0 with errorCode=1
07-04 09:55:29.146   255   255 I hdmicec : send msg LEN:2,opcode:8f,addr:40
07-04 09:55:29.175   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:29.476   255   255 I hdmicec : send msg LEN:2,opcode:8f,addr:40
07-04 09:55:29.505   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:29.806   460   571 W HdmiCecController: Failed to send <Give Device Power Status> src: 4, dst: 0 with errorCode=1

The interesting lines are the ones with “send msg”, and the results of them.

# logcat | grep -i cec | grep "send msg" -A3                                                                                                                                                
07-04 09:55:22.640   255   255 I hdmicec : send msg LEN:5,opcode:84,addr:4f
07-04 09:55:22.640   460   460 I HdmiCecLocalDevice: Starting queued action:com.android.server.hdmi.DevicePowerStatusAction@66f7e18
07-04 09:55:22.768   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:22.768   255   255 I hdmicec : send msg LEN:5,opcode:87,addr:4f
07-04 09:55:22.896   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:22.896   255   255 I hdmicec : send msg LEN:4,opcode:82,addr:4f
07-04 09:55:22.999   255   255 E hdmicec : HDMI_RESULT_SUCCESS
07-04 09:55:23.000   255   255 I hdmicec : send msg LEN:2,opcode:0d,addr:40
07-04 09:55:23.029   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:23.330   255   255 I hdmicec : send msg LEN:2,opcode:0d,addr:40
07-04 09:55:23.359   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:23.659   460   571 W HdmiCecController: Failed to send <Text View On> src: 4, dst: 0 with errorCode=1
07-04 09:55:23.660   255   255 I hdmicec : send msg LEN:2,opcode:8f,addr:40
07-04 09:55:23.690   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:23.991   255   255 I hdmicec : send msg LEN:2,opcode:8f,addr:40
07-04 09:55:24.020   255   255 E hdmicec : HDMI_RESULT_NACK
07-04 09:55:24.321   460   571 W HdmiCecController: Failed to send <Give Device Power Status> src: 4, dst: 0 with errorCode=1
07-04 09:55:26.511   255   275 D hdmicec : poll revent:02