rhysmorgan134 / react-carplay

MIT License
518 stars 72 forks source link

Carplay running, but no graphics only white screen #26

Closed kostasfe closed 1 year ago

kostasfe commented 1 year ago

I've tried running the latest packages including the 3.+ release with a very similar result. The carplay seems to run, as the phone appears connected and the music starts playing - there is output from the Pi. Also, it appears to react to touch as I've managed to hit the pause button somewhere on the screen.

However, the screen remains white, showing the mouse if moved though. Ive tried two different displays, both HDMI - a TV and a 7 inch touch-screen (not RPI official).

I've also tried running the same set up on Buster and Bullseye on RPI 4B 8gb.

This could be related to the issue #22 as in previous releases (1.0.5 and 1.0.6) I was getting the same error.

Below is the terminal output from Bullseye and Buster (as seen at the beginning, the dongle is 1314:1521):

Bullseye:

lexus@raspberrypi:~ $ lsusb Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 001 Device 011: ID 1314:1521 Magic Communication Tec. Auto Box Bus 001 Device 005: ID 0eef:0005 D-WAV Scientific Co., Ltd WS170120 Bus 001 Device 004: ID 046d:0aaa Logitech, Inc. PRO X Bus 001 Device 003: ID 046d:c52b Logitech, Inc. Unifying Receiver Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub lexus@raspberrypi:~ $ sudo /home/lexus/React_carplay/ReactCarplay-3.0.1- armv7l.AppImage --no-sandbox /root/.config/ReactCarplay [1382:0205/175810.089991:ERROR:bus.cc(399)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix") [1382:0205/175810.090474:ERROR:bus.cc(399)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix") No protocol specified No protocol specified No protocol specified No protocol specified [1412:0205/175810.347140:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [1412:0205/175810.347440:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [1412:0205/175810.347571:ERROR:gl_display.cc(920)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type No protocol specified [1412:0205/175810.348172:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [1412:0205/175810.348377:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [1412:0205/175810.348520:ERROR:gl_display.cc(920)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED [1412:0205/175810.348654:ERROR:gl_ozone_egl.cc(23)] GLDisplayEGL::Initialize failed. [1412:0205/175810.386815:ERROR:viz_main_impl.cc(186)] Exiting GPU process due to errors during initialization [1382:0205/175810.677446:ERROR:bus.cc(399)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix") spawning carplay { dpi: 240, nightMode: 0, hand: 0, boxName: 'nodePlay', width: 1024, height: 600, fps: 30 } directory found sending dpi device connected and ready unkown type: 24 with data:: <Buffer aa 55 aa 55 71 00 00 00 18 00 00 00 e7 ff ff ff> unkown type: 38 with data:: <Buffer aa 55 aa 55 00 00 00 00 26 00 00 00 d9 ff ff ff> unkown type: 1 with data:: <Buffer aa 55 aa 55 00 00 00 00 01 00 00 00 fe ff ff ff> No protocol specified No protocol specified No protocol specified

No protocol specified [1442:0205/175811.182407:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [1442:0205/175811.185215:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [1442:0205/175811.185815:ERROR:gl_display.cc(920)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type No protocol specified [1442:0205/175811.189036:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [1442:0205/175811.189975:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [1442:0205/175811.190180:ERROR:gl_display.cc(920)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED [1442:0205/175811.190613:ERROR:gl_ozone_egl.cc(23)] GLDisplayEGL::Initialize failed. [1442:0205/175811.202102:ERROR:viz_main_impl.cc(186)] Exiting GPU process due to errors during initialization No protocol specified No protocol specified No protocol specified No protocol specified [1451:0205/175811.370022:ERROR:angle_platform_impl.cc(43)] DisplayVkXcb.cpp:59 (initialize): xcb_connect() failed, error 1 ERR: DisplayVkXcb.cpp:59 (initialize): xcb_connect() failed, error 1 [1451:0205/175811.370568:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Not initialized. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Not initialized. [1451:0205/175811.370870:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Not initialized. [1451:0205/175811.371051:ERROR:gl_display.cc(920)] eglInitialize SwANGLE failed with error EGL_NOT_INITIALIZED [1451:0205/175811.371263:ERROR:gl_ozone_egl.cc(23)] GLDisplayEGL::Initialize failed. starting projection [1451:0205/175811.386732:ERROR:viz_main_impl.cc(186)] Exiting GPU process due to errors during initialization No protocol specified No protocol specified [1459:0205/175811.486080:ERROR:gpu_init.cc(523)] Passthrough is not supported, GL is disabled, ANGLE is [1459:0205/175811.522482:ERROR:x11_software_bitmap_presenter.cc(142)] XGetWindowAttributes failed for window 25165827 parsing type: 8 for length: 4 <Buffer aa 55 aa 55 04 00 00 00 08 00 00 00 f7 ff ff ff> parsing 8 <Buffer e8 03 00 00> Carplay message: Support Wifi unkown type: 13 with data:: <Buffer aa 55 aa 55 0d 00 00 00 0d 00 00 00 f2 ff ff ff>

Buster:

pi@raspberrypi:~ $ sudo /home/pi/React_carplay/ReactCarplay-3.0.1-armv7l.AppImage --no-sandbox /root/.config/ReactCarplay [2712:0205/183609.365972:ERROR:bus.cc(399)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix") [2712:0205/183609.366281:ERROR:bus.cc(399)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix") No protocol specified No protocol specified No protocol specified No protocol specified [2742:0205/183609.649250:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [2742:0205/183609.649561:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [2742:0205/183609.649701:ERROR:gl_display.cc(920)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type No protocol specified [2742:0205/183609.650350:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [2742:0205/183609.650574:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [2742:0205/183609.650716:ERROR:gl_display.cc(920)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED [2742:0205/183609.650854:ERROR:gl_ozone_egl.cc(23)] GLDisplayEGL::Initialize failed. [2742:0205/183609.686442:ERROR:viz_main_impl.cc(186)] Exiting GPU process due to errors during initialization [2712:0205/183610.016389:ERROR:bus.cc(399)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix") spawning carplay { dpi: 240, nightMode: 0, hand: 0, boxName: 'nodePlay', width: 1024, height: 600, fps: 30 } directory found sending dpi device connected and ready unkown type: 24 with data:: <Buffer aa 55 aa 55 71 00 00 00 18 00 00 00 e7 ff ff ff> unkown type: 38 with data:: <Buffer aa 55 aa 55 00 00 00 00 26 00 00 00 d9 ff ff ff> unkown type: 1 with data:: <Buffer aa 55 aa 55 00 00 00 00 01 00 00 00 fe ff ff ff> No protocol specified No protocol specified No protocol specified No protocol specified [2776:0205/183610.543691:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [2776:0205/183610.544046:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [2776:0205/183610.544231:ERROR:gl_display.cc(920)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type No protocol specified [2776:0205/183610.545206:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Could not open the default X display. [2776:0205/183610.545475:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Could not open the default X display. [2776:0205/183610.545628:ERROR:gl_display.cc(920)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED [2776:0205/183610.545780:ERROR:gl_ozone_egl.cc(23)] GLDisplayEGL::Initialize failed. [2776:0205/183610.564742:ERROR:viz_main_impl.cc(186)] Exiting GPU process due to errors during initialization No protocol specified No protocol specified starting projection No protocol specified No protocol specified [2786:0205/183610.756925:ERROR:angle_platform_impl.cc(43)] DisplayVkXcb.cpp:59 (initialize): xcb_connect() failed, error 1 ERR: DisplayVkXcb.cpp:59 (initialize): xcb_connect() failed, error 1 [2786:0205/183610.757242:ERROR:angle_platform_impl.cc(43)] Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Not initialized. ERR: Display.cpp:1004 (initialize): ANGLE Display::initialize error 12289: Not initialized. [2786:0205/183610.757435:ERROR:gl_display.cc(508)] EGL Driver message (Critical) eglInitialize: Not initialized. [2786:0205/183610.757567:ERROR:gl_display.cc(920)] eglInitialize SwANGLE failed with error EGL_NOT_INITIALIZED [2786:0205/183610.757716:ERROR:gl_ozone_egl.cc(23)] GLDisplayEGL::Initialize failed. [2786:0205/183610.771085:ERROR:viz_main_impl.cc(186)] Exiting GPU process due to errors during initialization No protocol specified No protocol specified [2794:0205/183610.851136:ERROR:gpu_init.cc(523)] Passthrough is not supported, GL is disabled, ANGLE is [2794:0205/183610.884361:ERROR:x11_software_bitmap_presenter.cc(142)] XGetWindowAttributes failed for window 27262978 parsing type: 8 for length: 4 <Buffer aa 55 aa 55 04 00 00 00 08 00 00 00 f7 ff ff ff> parsing 8 <Buffer e8 03 00 00> Carplay message: Support Wifi unkown type: 13 with data:: <Buffer aa 55 aa 55 0d 00 00 00 0d 00 00 00 f2 ff ff ff>

Thanks for the great work btw!

rhysmorgan134 commented 1 year ago

Thanks for the info, could you supply abit more about how you installed the OS? Is this running on a headless pi? Are you using a custom desktop enviroment? If not was it the full OS or the light version? All errors point to not being able to open the x display.

Just to rule it out could you run the below commands and then start the application without sudo ?

echo "SUBSYSTEM==\"usb\", ATTR{idVendor}==\"1314\", ATTR{idProduct}==\"152*\", MODE=\"0660\", GROUP=\"plugdev\"" | sudo tee /etc/udev/rules.d/52-nodecarplay.rules

LRYMND commented 1 year ago

Please try without sudo, when your phone connects you should see "Connect iPhone to begin carplay".

You will see in the console that the data arrives however the stream should still not be visible. Once you toggle carplay in the iPhone settings off and back on again, CarPlay should be visible.

This would be a replication of the behavior I mentioned in the other issue where the status state of the CarPlay component apparently needs to be updated twice in order for the stream to be revealed. Confirmed this issue with @Tigo2000 as well on the latest react-carplay as well as volvo-rtvi.

Cheers

rhysmorgan134 commented 1 year ago

@LRYMND Could you elaborate? I am not seeing that issue my side. Are you having to do that on every run?

kostasfe commented 1 year ago

@rhysmorgan134 thank you for the swift answer. After running your commands and the application without sudo it worked like a charm. Including the wireless option.

However, I'm not sure what the commands actually do, therefore, not sure if they helped or just running without sudo did, as I have always used sudo in previous attempts.

Any suggestions of what I should do if the problem repeats? Also would be curious to know what your commands actually did thanks.

By the way, not sure if still relevant, but to your questions: I installed the os through the official Raspberry Pi Imager onto an SD Card. The Pi is headless and the OS is completely clean and empty, no custom desktop env. Both Buster and Bullseye were full versions.

@LRYMND thanks for the comment. I did get the "Connect iPhone to begin carplay", but it connected seconds after I plugged in the phone without the need to toggle Carplay in the settings.

LRYMND commented 1 year ago

I tested a bit more extensively with react-carplay now and you are right, the connection does in fact establish right away without needing to toggle. Maybe my dongle was asleep or something... Interesting though that Tigo experienced the same behaviour. However the problem with navigating from and to the carplay component persists and you have to toggle it in the settings to reveal it again.

rhysmorgan134 commented 1 year ago

@kostasfe the commands don’t do much, they just allow non root permissions to access the carlinkit (matches product and vendor ID) the issue won’t come back, just make sure you add those rules on any install (or use the setup-pi.sh script which does it for you)

if you tried to run without sudo before doing the command you would have had an error there too!

kostasfe commented 1 year ago

@rhysmorgan134 many thanks. By the way, the wireless option seems to be snappier versus using it when running LineageOS Android 11 and Android Autokit.apk on the same PI. Well done!