[imx8mp]Weston-rdp screen share issue

I have imx8m board which has one display connected. and i want to share custom board display screen to any host machine(in my case it it Linux system)

For that i used to weston-rdp service for sharing screen and below configuration i have done in bot side client and host.

  1. In yocto add below lines into the weston bb file “weston_10*.imx.bb” to enable freerdp support.
DEPENDS += "freerdp"
EXTRA_OEMESON += "-Dbackend-rdp=true"
  1. On client side:

Add below module into the /etc/xdg/weston/weston.ini file.

[core]
modules=screen-share.so

Add below command into the /etc/xdg/weston/weston.ini file

command=@bindir@/weston --no-config –backend=rdp-backend.so

Generate TLS certificate/key.

Modify ExecStart command into the /lib/systemd/system/weston.service file.

ExecStart=/usr/bin/weston --backend=rdp-backend.so –rdp-tls- cert=/home/root/server.crt --rdp-tls-key=/home/root/server.key

restart the weston service.

3) On Host side:-

Run xfreerdp with client ip address and display resolution.

xfreerdp /v:192.168.200.59 /size:800x480

When I restart weston service after all changes the service not started and weston not created socket into the /run/user/0/ location. this issue created when i add “–backend=rdp-backend.so” into the service file.

[11:14:50.666] weston 10.0.1
               https://wayland.freedesktop.org
               Bug reports to: https://gitlab.freedesktop.org/wayland/weston/issues/
               Build: lf-5.15.52-2.1.0+
[11:14:50.666] Command line: weston
[11:14:50.666] OS: Linux, 5.15.77-6.4.0-devel+git.ddc6ca4d76ea, #1 SMP PREEMPT Thu Jun 29 10:14:22 UTC 2023, aarch64
[11:14:50.666] Flight recorder: enabled
[11:14:50.666] fatal: environment variable XDG_RUNTIME_DIR is not set.
Refer to your distribution on how to get it, or
http://www.freedesktop.org/wiki/Specifications/basedir-spec
on how to implement it.

In normal state without --backend=rdp-backend.so the weston created socket into the /run/user/0/ location.
Why weston failed in when i add rdp-backend.so in weston.service file ? can someone help me ?

Hi @bhavanihimanshu,

Thanks for writing to Toradex Community!

As you already see BSP reference image do not have default VNC or RDP server so you are required to make necessary changes in weston recipe to enable and provide VNC/RDP support.

We have Toradex easy installer, where same is enabled by default, you can take reference from there and try to enable and use same.

Best Regards
Ritesh Kumar

Thanks for you response, Could you please help me what changes are required to enable rdp ?

Hi @bhavanihimanshu,

You will need to modify weston recipe in order to get VNC running. Please go through recipe and implement same.

Best Regards
Ritesh Kumar

Hi @ritesh.tx

I am using weston 10, could you please provide me weston 10 changes? and i am trying to implement RDP.

Hi @bhavanihimanshu,

Above changes we shared is from our software Toradex easy installer, by default we do not have this enabled for our reference image.
Since with Toradex easy installer we still using weston 9 so the changes are only avaiable for same. That said you can simply implement above in your recipe details are already shared.

If you face any issue, please feel free to write us back with steps and error logs.
Best Regards
Ritesh Kumar