This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/DRA74: Carplay Screen goes blank when switch back from Video playback

Part Number: DRA74

Tool/software: Linux

Hello Team, 

We use custom h/w and software based on DRA746 and PSDK 3.03

We are trying following use case:

1. Start Carplay.

2. Switch to Video Playback.(video playback starts)

3. Switch back to CarPlay( carplay screen comes and video playback is in paused state)

4. Start audio playback on Carplay(when we starts the audio playback on carplay, audio source switch happens and video playback pipeline is destroyed). At this moment we carplay screen goes blank.

Is there a limitation when we play multiple gstreamer pipelines and destroys the pipeline running in the background.  

Could you help us in debugging this issue. 

Sharing the gstreamer logs when issue happens through portal .

Regards,

Ikshwaku

  • Hi Ikshwaku,
    >>Is there a limitation when we play multiple gstreamer pipelines and destroys the pipeline running in the background.
    This should not happen.

    TI's SDK doesn't support ivi-shell with waylandsink. TI has tested multiple gstreamer video playback with desktop-shell.
    I had integrated your ivi-shell patch on waylandsink and tested the attached patch. It works well.

    Can you get the information of the surface/layer/screen for carplay and video playback from LayerManagerControl?
    Can you confirm if they are using different sruface-id s?

    >>4. Start audio playback on Carplay(when we starts the audio playback on carplay, audio source switch happens and video playback pipeline is >>destroyed). At this moment we carplay screen goes blank.
    Can you check how is video-pipeline is getting killed here?

    I looked at the logs you shared but could not much ifnormation from this on what can cause the issue.

    Thanks
    Ram
  • I tested this script

    layer-add-surfaces 1000 2 &
    sleep 2
    gst-play-1.0 --videosink "waylandsink window-resolution=960x540 surface-id=100" /home/root/b1.mp4 &
    sleep 1
    LayerManagerControl set surface 100 position 960 0
    sleep 1
    gst-play-1.0 --videosink "waylandsink window-resolution=960x540 surface-id=200" /home/root/f1.mp4 &
    sleep 1
  • Hello Ram,

    Can you get the information of the surface/layer/screen for carplay and video playback from LayerManagerControl?
    Can you confirm if they are using different sruface-id s?
    --> We are using different surface ids for carplay(id : 90) and video playback(id : 80).

    Can you check how is video-pipeline is getting killed here?
    --> when we switch from video playback to carplay then we put video playback pipeline into pause state and when source switch happens then we put video playback pipeline to NULL state.



    Regards,
    Ikshwaku
  • Hello Ram,

    In the logs shared with you, we see below observation.

    In Working case we always see wayland buffer is available and given to display as shown below log.

    ========================================================================

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1f8d0

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xade1f8d0 has a wl_buffer from our display, writing directly

    waylandsink wlbuffer.c:137:buffer_release:<GstWlBuffer@0xade16ec0>[00m wl_buffer::release (GstBuffer: 0xade1a6e8)

    waylandsink gstwaylandsink.c:644:frame_redraw_callback:[00m frame_redraw_cb

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a508

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xade1a508 has a wl_buffer from our display, writing directly

    waylandsink wlbuffer.c:137:buffer_release:<GstWlBuffer@0xade20ca0>[00m wl_buffer::release (GstBuffer: 0xade1f8d0)

    waylandsink gstwaylandsink.c:644:frame_redraw_callback:[00m frame_redraw_cb

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a008

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xade1a008 has a wl_buffer from our display, writing directly

    waylandsink wlbuffer.c:137:buffer_release:<GstWlBuffer@0xade20a40>[00m wl_buffer::release (GstBuffer: 0xade1a508)

    waylandsink gstwaylandsink.c:644:frame_redraw_callback:[00m frame_redraw_cb

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1fa10

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xade1fa10 has a wl_buffer from our display, writing directly

    ===============================================================================================================

    In Non working case where media pipeline is destroyed and CarPlay pipeline is active in the foreground we can see the below observation where we see its not able to write directly to display.

    ===============================================================================================================

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xaf115ea0

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xaf115ea0 has a wl_buffer from our display, writing directly

    0m bufferpool gstbufferpool.c:300:do_alloc_buffer:<vpebufferpool27>[00m alloc function failed

    waylandsink wlbuffer.c:137:buffer_release:<GstWlBuffer@0xade31ee0>[00m wl_buffer::release (GstBuffer: 0xade1a1e8)

    waylandsink gstwaylandsink.c:644:frame_redraw_callback:[00m frame_redraw_cb

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1f970

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xade1f970 has a wl_buffer from our display, writing directly

    0m bufferpool gstbufferpool.c:300:do_alloc_buffer:<vpebufferpool27>[00m alloc function failed

    0m bufferpool gstbufferpool.c:300:do_alloc_buffer:<vpebufferpool27>[00m alloc function failed

    0m bufferpool gstbufferpool.c:300:do_alloc_buffer:<vpebufferpool27>[00m alloc function failed

    e=40 sessionID = 01 seq=21 ack=b2 data= 40 40 00 12 50 01 00 0c 00 01 00 08 00 01 00 00 d8 b9

    waylandsink wlbuffer.c:137:buffer_release:<GstWlBuffer@0xade17540>[00m wl_buffer::release (GstBuffer: 0xaf115ea0)

    waylandsink gstwaylandsink.c:644:frame_redraw_callback:[00m frame_redraw_cb

    0m bufferpool gstbufferpool.c:300:do_alloc_buffer:<vpebufferpool27>[00m alloc function failed

    0m bufferpool gstbufferpool.c:537:gst_buffer_pool_set_active:<vpebufferpool27>[00m stop failed

    0m bufferpool gstbufferpool.c:537:gst_buffer_pool_set_active:<vpebufferpool27>[00m stop failed

    0m ducati gstducatividdec.c:570:codec_process:<decoder>[00m err=-1, extendedError=00008000

    00m ducati gstducati.c:61:gst_ducati_log_extended_error_info:[00m Bit 15 (00008000): fatal

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a648

    waylandsink gstwaylandsink.c:719:gst_wayland_sink_render:<videoSink>[00m buffer 0xade1a648 has a wl_buffer from our display, writing directly

     

    e=40 sessionID = 01 seq=22 ack=b2 data= 40 40 00 12 50 01 00 0c 00 01 00 08 00 01 00 00 d9 08

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a008

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1fa10

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a5a8

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a6e8

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a0a8

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xaf115900

    waylandsink gstwaylandsink.c:687:gst_wayland_sink_render:<videoSink>[00m render buffer 0xade1a288

    =====================================================================================================

    Can you please let us know when this issue can happen, to further debug this issue.

    Thanks,

    Ayyappa

  • Hi Ikshwaku/Ayyappa,
    When the screen goes blank, is it nothing but ivi-shell's blank screen?
    Can you check LayerManagerControl status to check which screen/surface/layer are active?

    In the log you posted
    00m ducati gstducati.c:61:gst_ducati_log_extended_error_info:[00m Bit 15 (00008000): fatal
    Decoder is setting a FATAL error. Can you enable debug for ducati plugin alone and share the logs?

    Thanks
    Ramprasad
  • Hello Ram,

    When we are initiating LayerManagerControl command then carplay screen become visible.

    And yes all the screen/surface/layers are active.

    Regards,
    Ikshwaku

  • Hi Ikshwaku,
    With ivi-shell, we have seen the issue with any application that last displayed frame will remain on display. Are you seeing this issue?
    and when LayerManagerControl command is executed, display we can see a movement.

    Weston uses 3 buffers to render display. When LayerManagerControl is executed, it is showing second and third buffers.
    Can you let us know the version of weston and wayland-ivi-extension integrated?

    Thanks
    Ram
  • Hello Ram,

    With ivi-shell, we have seen the issue with any application that last displayed frame will remain on display. Are you seeing this issue?
    --> no we are not seeing this issue. when we switch back to carplay screen its is proper and we can navigate on the carplay screen properly. carplay screen goes to blank only when we starts audio playback on carplay. then if we execute LayermanagerControl command then carplay screen become visible and works properly.
    Also, if we call ilm_commitChanges call from then screen carplay screen belome visible and works properly.

    We are using following versions:
    weston : 1.11
    wayland-ivi-extention : 1.11

    Regards,
    Ikshwaku
  • Hi Ikshwaku,
    >>Also, if we call ilm_commitChanges call from then screen carplay screen belome visible and works properly.
    So with this change issue is no more observed?
    Can we consider that issue is resolved if there is no dependency?

    Thanks
    Ram
  • Hello Ram,

    Calling ilm_commitChanges is not the solution, its just a work around. We are calling it from our middleware component just after we receives destroy surface notification for video playback surface.
    So, this issue is not resolved, we need to debug why carplay screen is going blank when background video playback is destroyed.


    This kind of issue is happening only when two gstreamer pipelines are involved and one is destroyed when other tries to get the audio source.


    Regards,
    Ikshwaku
  • Hello Ram,

    Sharing the ducati and waylandsink logs through portal. Please have a look.

    You were taking about some known issue related to ivi-extension, please share the reference for that issue as well.

    Regards,
    Ikshwaku
  • One more query:

    In the waylandsink logs, we are able to see that waylandsink is not rendering the buffer as "gst_wayland_sink_render" function is returning because "sink->redraw_pending " is always TRUE and this function is not rendering the frames. also "frame_redraw_cb" this callback is not invoked.
  • Hi Ikshwaku,
    I have downloaded the logs you shared. Can you confirm if these logs were taken when display goes blank after switching the audio source?

    The known issue reported with ivi-shell is that it always retains the last displayed image on display even after application exited.
    This can be reproduced with PSDKLA3.04 with any application, when you execute LayerManagerControl command, you can see the movement on display
    as it forces last two rendered buffers on display.

    Can you make this change in weston 1.11 and check what is impact?

    0001-gl-render-Clear-render-buffer-before-painting.zip

    >>In the waylandsink logs, we are able to see that waylandsink is not rendering the buffer as "gst_wayland_sink_render" function is returning
    >>>because "sink->redraw_pending " is always TRUE and this function is not rendering the frames. also "frame_redraw_cb" this callback is not invoked.

    Can you check if you have applied this patch in your waylandsink?
    e2e.ti.com/.../2440288

  • Hello Ram,

    >>>>>I have downloaded the logs you shared. Can you confirm if these logs were taken when display goes blank after switching the audio source?

    Yes, these logs are for carplay, from carplay starts till black screen issue occurs.

    Patches you shared will check and update you.

    Regards,
    Ikshwaku
  • Can you make this change in weston 1.11 and check what is impact?

    0001-gl-render-Clear-render-buffer-before-painting.zip

    ---> issue is seen after applying the gl-render patch.

    Can you check if you have applied this patch in your waylandsink?
    e2e.ti.com/.../2440288

    ---> yes this patch is present in waylandsink.

    Regards,
    Ikshwaku
  • Hi Ikshwaku,
    Closing this thread as it is the issue with wayland-ivi-extension and there is no dependency on TI.

    Thanks
    Ram