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/TDA2EXEVM: Show the Qt Application in TDA2EX Platform

Part Number: TDA2EXEVM

Tool/software: Linux

Hi TI Experts,

I'm working customized TDA2EX platform. 

I have cross compiled the QT 5.2.1 version for TDA2EX platform. I have created the qt application.

So I just want to run GUI application in TDA2Ex !!! 

Is it any arguments required to run GUI ?  Is it any document for my reference.

Kindly suggest me.

Thanks & Regards,

RajKumar.

  • Hi Raj,

    which SDK you use? VisionSDK (and it's linux rootfs) do not have support for QT.
    Can you check this thread for some directions:
    e2e.ti.com/.../2584162

    Regards,
    Yordan
  • Hi Yordan,

    Thanks for your reply,

    We noticed Qt5 libraries in VisionSDK 3.04 filesystem, So we thought already
    it is available in VisionSDK.

    ./usr/lib/libQt5PrintSupport.so.5
    ./usr/lib/libQt5Test.so.5.6
    ./usr/lib/libQt5Sql.so.5
    ./usr/lib/libQt5Sql.so.5.6
    ./usr/lib/libQt5OpenGL.so.5.6.2
    ./usr/lib/libQt5Network.so.5.6
    ./usr/lib/libQt5DBus.so.5.6
    ./usr/lib/libQt5Gui.so.5
    ./usr/lib/libQt5Gui.so.5.6.2
    ./usr/lib/libQt5Xml.so.5.6.2
    ./usr/lib/libQt5Network.so.5.6.2
    ./usr/lib/libQt5Test.so.5
    ./usr/lib/libQt5Xml.so.5.6
    ./usr/lib/libQt5DBus.so.5
    ./usr/lib/libQt5EglDeviceIntegration.so.5
    ./usr/lib/libQt5DBus.so.5.6.2
    ./usr/lib/libQt5Core.so.5
    ./usr/lib/libQt5Widgets.so.5.6
    ./usr/lib/libQt5EglDeviceIntegration.so.5.6.2
    ./usr/lib/libQt5Concurrent.so.5
    ./usr/lib/libQt5Sql.so.5.6.2
    ./usr/lib/libQt5Concurrent.so.5.6.2
    ./usr/lib/libQt5Core.so.5.6.2
    ./usr/lib/libQt5EglDeviceIntegration.so.5.6
    ./usr/lib/libQt5Widgets.so.5.6.2
    ./usr/lib/libQt5OpenGL.so.5
    ./usr/lib/libQt5Concurrent.so.5.6
    ./usr/lib/libQt5PrintSupport.so.5.6
    ./usr/lib/libQt5Test.so.5.6.2
    ./usr/lib/libQt5PrintSupport.so.5.6.2
    ./usr/lib/libQt5Gui.so.5.6
    ./usr/lib/libQt5Widgets.so.5
    ./usr/lib/libQt5Core.so.5.6
    ./usr/lib/libQt5Network.so.5
    ./usr/lib/libQt5Xml.so.5
    ./usr/lib/libQt5OpenGL.so.5.6

    Kindly let us know how any example Qt application available in VisionSDK 3.04.

    If Qt is not yet supported in VisionSDK, Let us know the changes or
    procedure documents to port Qt in VisionSDK 3.04.
  • Hi Raj,

    the rootfs for VisionSDK 3.04 do not have support for Qt. You can use the rootfs from Processor SDK Linux Automotive to run Qt apps:
    e2e.ti.com/.../2737137

    but in that case you will not have integration with VisionSDK out-of-the-box as VisionSDK uses M4 based display and in it's Linux variant it uses Virtual DRM interface, see here for details:
    e2e.ti.com/.../2643725

    it should be possible to get PSDKLA's rootfs and integrate it with VisionSDK, but it is not straightforward and there is no particular document for this. There is a list of components that need to be changed:
    e2e.ti.com/.../2597171

    Regards,
    Yordan
  • Hi Yordan,

    Thanks for your feedback.

    As per the above links we understand there are two approaches ,

    1. Take the PSDKLA and port the necessary components one by one from Vision
    SDK
    2. Vision SDK has support for Virtual DRM Interface, and we have to enable
    linuxfb with DRM dump buffer support. In this case, Qt will use linuxfb and
    internally the content will be displayed through DRM. Please refer the post
    e2e.ti.com/.../2643725

    We are thinking to take up the Option "2" of using DRM interface. In our
    case, we will run the Qt application from A15, and video display through M4.
    So the DSS will be controlled by both A15 and M4 through DRM, Is our
    understanding correct ? Also will the alpha blending(Qt screen + Video) and
    z-order can be controlled from A15 ?

    Thanks & Regards,
    Rajkumar
  • Hi Rajkumar,

    I have pinged graphics expert to provide further help as I am not familiar with this. He will reply here soon.

    Regards,
    Yordan
  • Hi Yordan,

    Ok, Thank you.

    Regards,
    Rajkumar
  • QT applications are dependent on weston. Do you have weston running?
  • Hi Subhajit,

    Thanks for your reply.

    We are new to this, So I do not know about weston running.
    How to check weston running?
    Can you give me any document for my reference?


    Regards,
    Rajkumar
  • you can check in /var/log/weston.log

  • Hi Subhajit,

    /var/log/weston.log file contains

    Date: 2018-06-12 UTC
    [00:16:28.283] weston 1.9.0
    http://wayland.freedesktop.org
    Bug reports to: bugs.freedesktop.org/enter_bug.cgi
    Build: 1.8.93-2-gb05cdb8 configure.ac: bump to version 1.9.0 for the official release (2015-09-21 18:11:26 -0700)
    [00:16:28.284] OS: Linux, 4.4.84-00027-g018eb62-dirty, #2 SMP PREEMPT Fri Nov 9 16:28:10 IST 2018, armv7l
    [00:16:28.285] Using config file '/etc//weston.ini'
    [00:16:28.290] Loading module '/usr/lib/weston/drm-backend.so'
    [00:16:28.322] Output repaint window is 7 ms maximum.
    [00:16:28.322] initializing drm backend
    [00:16:28.323] no drm device found
    [00:16:28.323] fatal: failed to create compositor backend

    Regards,
    Rajkumar
  • Raj Kumar,

    TI SDKs only support DRM based solutions. It seems like you have a highly customised setup where DRM drivers are not used.

    We do not support any other framework apart from DRM
  • Hi Subhajit,

    We are enabled DRM in kernal. So After enabled we Got error like,

    root@dra7xx-evm:/var/log# cat weston.log
    Date: 2018-06-11 UTC
    [19:54:30.732] weston 1.9.0
    http://wayland.freedesktop.org
    Bug reports to: bugs.freedesktop.org/enter_bug.cgi
    Build: 1.8.93-2-gb05cdb8 configure.ac: bump to version 1.9.0 for the official release (2015-09-21 18:11:26 -0700)
    [19:54:30.732] OS: Linux, 4.4.84-00027-g018eb62-dirty, #3 SMP PREEMPT Fri Nov 16 19:17:00 IST 2018, armv7l
    [19:54:30.740] Using config file '/etc//weston.ini'
    [19:54:30.753] Loading module '/usr/lib/weston/drm-backend.so'
    [19:54:30.792] Output repaint window is 7 ms maximum.
    [19:54:30.792] initializing drm backend
    [19:54:30.794] using /dev/dri/card0
    [19:54:30.797] Loading module '/usr/lib/weston/gl-renderer.so'
    loaded module : gbm_pvr.so
    found valid GBM backend : gbm_pvr.so
    [19:54:30.896] failed to initialize egl
    [19:54:30.896] fatal: failed to create compositor backend
    PVR:(Error): [ 581-> 581] < gbm_pvr_create_device():645|ERROR> Failed to create DBM device: No such device [0, ]



    Regards,
    Rajkumar
  • Hi Subhajit,

    Any response for this issue ?

    Which DBM device is referring ?

    Regards,

    Rajesh Kannan S
  • Hi,

    Now I could able to see wayland terminal on HDMI display via M4 core.

    Could you tell me how to run GUI(QT) Application by using wayland protocol.

    Regards,

    Rajesh Kannan S
  • Hi TI Experts,

    Now I have cross compiled the QT 5.6.2 version for TDA2EX platform. I have created the qt application.

    Run the Qt application like,

    ./DVR_GUI --platform eglfs

    So After run the Qt application we got error like,

    This application failed to start because it could not find or load the Qt platform plugin "eglfs"
    in "".

    Reinstalling the application may fix this problem.
    Aborted (core dumped)

    Can you tell me, how to resolve this issue.

    Thank you,

    Regards,
    Rajkumar
  • It looks like your system does not have any DRM device. Can you send the output of "ls /dev/dri/*"
  • Hi Subhajit Paul,

    Thanks for your reply,

    This is the output of "ls /dev/dri/*"

    root@dra7xx-evm:/dev/dri# ls /dev/dri/*
    /dev/dri/card0 /dev/dri/card1 /dev/dri/card2 /dev/dri/controlD64 /dev/dri/controlD65 /dev/dri/renderD128 /dev/dri/renderD129
    root@dra7xx-evm:/dev/dri#

    Thanks & Regards,
    Rajkumar
  • Hi Subhajit Paul,

    Could you guide me to enable /dev/fb* support by default in this platform.

    Regards,

    Rajkumar
  • Raj Kumar,

    TI does not support FBdev implementation on DRAxxx platforms. When a DRM framework is setup, it should expose an emulated FBdev which you should be able to find in /dev/fb0

    Regards,
    Subhajit

  • Hi Subhajit,

    Thanks for your reply.

    root@dra7xx-evm:/dev/dri# ls /dev/dri/*

    /dev/dri/card0 /dev/dri/card1 /dev/dri/card2 /dev/dri/controlD64 /dev/dri/controlD65 /dev/dri/renderD128 /dev/dri/renderD129

    As you said, by seeing this output DRM has been enabled.

    If DRM framework is setup, it should expose an emulated FBdev should be able to find in /dev/fb0 correct ? 

    If is not enabled by default, FbDev support needs to be added ? Is there any way to check it ?

    Regards,

    RajKumar

  • Check in the kernel .config file if CONFIG_DRM_FBDEV_EMULATION is enabled
  • Hi,

    Thanks for your reply.
    Ya its enabled.

    Symbol: DRM_FBDEV_EMULATION [=y]
    Type : boolean
    Prompt: Enable legacy fbdev support for your modesetting driver
    Location:
    -> Device Drivers
    -> Graphics support
    (1) -> Direct Rendering Manager (XFree86 4.1.0 and higher DRI support) (DRM [=y])
    Defined at drivers/gpu/drm/Kconfig:50
    Depends on: HAS_IOMEM [=y] && DRM [=y]
    Selects: DRM_KMS_HELPER [=y] && DRM_KMS_FB_HELPER [=y]

    Kindly suggest !!!

    Regards,
    Rajkumar
  • Do you see a problem when you use omapdrm instead of virtual DRM?
  • Hi,

    I have enabled VDRM and ompdrm. I have tried to run GUI application, it was giving /dev/fb0 no such file or directory.

    Then I replied to you.

    You said, You will not have an framebuffer device when using vdrm. Try to use DRM based EGL

    Now I have disabled VDRM. Trying to open fb0 is having problem.

    I couldn't able to see the node from /dev/vdrm-controller-0 and weston output is not showing in HDMI display.

    Regards,

    Rajesh Kannan

  • try to run any other usecase in apps.out and verify whether HDMI display code in vision SDK is functional. If single camera usecases etc run as expected, then we can start debugging why weston buffers are not showing up
  • Hi,

    Without Enabling VDRM,the below mentioned useacse is showing on HDMI display.

    a: 4CH CSI2 CAL capture + SgxFrmCpy + DISPLAY - Only HDMI 1080p display supported

    Other than that showing assertion failure.

    Regards,

    Rajesh Kannan S

  • Hi,

    Any update regarding frame buffer /dev/fb* ?

    Kindly suggest

    Regards,

    Rajesh Kannan S
  • Hi,

    As per Linux Core DSS Userguide, If I enabled omapdrm it should create /dev/fb* (CONFIG_DRM_FBDEV_EMULATION) node by default.
    In kernel config also it's showing the option has been enabled.
    But In filesys, doesn't have a support to create the frame buffer node. What could be the dependency to enable to access frame buffer node.

    Kindly suggest me to solve this issue !!!

    Regards,

    Rajesh Kannan S
  • Hi,

    I have enabled VDRM as well as OMAPDRM in kernel_config and cross  compiled QT along with wayland support.

    By using  weston --tty=1 --backend= drm-backend.so&. I could able to see the output on HDMI Display.

    But performance wise it's very slow. Is there any way to enable frame buffer to use EGL

    I have attached the log. Kindly suggest me to solve this issue.

    Regards,

    Rajesh Kannan S

    root@dra7xx-evm:/opt/vision_sdk# top 
    Mem: 249476K used, 433184K free, 17404K shrd, 4960K buff, 92156K cached
    CPU:   0% usr  10% sys   0% nic  90% idle   0% io   0% irq   0% sirq
    Load average: 0.13 0.07 0.02 2/102 945
      PID  PPID USER     STAT   VSZ %VSZ %CPU COMMAND
      945   860 root     R     1960   0%   5% top
      292     2 root     RW       0   0%   5% [kworker/0:4]
      810   803 root     S    76988  11%   0% weston --idle-time=0
      873     1 root     S    60224   9%   0% ./DVR_GUI -platform wayland-egl
      834   810 root     S    14788   2%   0% /usr/libexec/weston-desktop-shell
      286     1 systemd- S    11992   2%   0% /lib/systemd/systemd-timesyncd
      188     1 root     S    10676   2%   0% /lib/systemd/systemd-udevd
      827     1 root     S     9760   1%   0% /usr/bin/lad_dra7xx -g -l lad.txt
      857   851 root     S     7356   1%   0% (sd-pam)
      840   810 root     S     7012   1%   0% /usr/libexec/weston-keyboard
      134     1 root     S     6320   1%   0% /lib/systemd/systemd-journald
      851     1 root     S     5336   1%   0% /lib/systemd/systemd --user
        1     0 root     S     5228   1%   0% {systemd} /sbin/init
      807     1 root     S     4864   1%   0% /bin/login --
      480     1 messageb S     4192   1%   0% /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation
      796     1 systemd- S     2984   0%   0% /lib/systemd/systemd-resolved
      592     1 systemd- S     2676   0%   0% /lib/systemd/systemd-networkd
      860   807 root     S     2676   0%   0% -sh
      803     1 root     S     2668   0%   0% {runWeston} /bin/sh /usr/bin/runWeston
      410     1 root     S     2600   0%   0% /lib/systemd/systemd-logind
      436     1 root     S     1976   0%   0% /sbin/syslogd -n -C
      426     1 root     S     1960   0%   0% /sbin/klogd -n
      825     1 root     S     1960   0%   0% /usr/sbin/telnetd
      804     1 root     S     1784   0%   0% /sbin/agetty --noclear tty1 linux
       72     2 root     SW       0   0%   0% [mmcqd/2]
        6     2 root     SW       0   0%   0% [kworker/u2:0]
       52     2 root     SW       0   0%   0% [kworker/u2:1]
        3     2 root     SW       0   0%   0% [ksoftirqd/0]
       89     2 root     SW       0   0%   0% [kworker/0:2]
        7     2 root     SW       0   0%   0% [rcu_preempt]
       11     2 root     SW       0   0%   0% [kdevtmpfs]
       61     2 root     SW       0   0%   0% [mmcqd/0]
       73     2 root     SW<      0   0%   0% [kworker/0:1H]
        2     0 root     SW       0   0%   0% [kthreadd]
        4     2 root     SW       0   0%   0% [kworker/0:0]
        5     2 root     SW<      0   0%   0% [kworker/0:0H]
        8     2 root     SW       0   0%   0% [rcu_sched]
        9     2 root     SW       0   0%   0% [rcu_bh]
       10     2 root     SW       0   0%   0% [migration/0]
       12     2 root     SW<      0   0%   0% [netns]
       13     2 root     SW<      0   0%   0% [perf]
    

  • Rajesh,

    TI cannot support you on enabling Framebuffer based EGL.

    Also, please elaborate on the statement : Performance is low.

    Regards,

    Subhajit

  • Hi,

    As per your statement,

    When a DRM framework is setup, it should expose an emulated FBdev which you should be able to find in /dev/fb0

    I have enabled DRM setup, but I didn't see FBdev node in /dev/fb* .

    What could be the way when a DRM framework setup, is should expose an emulated FB ?

    Guide me to expose an FB ?

    Regards,

    Rajesh Kannan S

  • Hello,

    Whatever you said, just confirm me is it correct or not ? Our team is going to validate and close this ASAP !!!

    Enabling drm support in kernel configuration, add those details to dts file like that you guide us to get proper support ??

    Kindly reply back !

    Regards,

    Rajesh Kannan S
  • I am marking this thread as resolved as this question has been answered in more than one thread