Hello !
I have been trying to change resolution (video mode) on a HDMI screen. I have used the advice on https://www.toradex.com/community/questions/59009/how-to-rotate weston-in-torizon-core.html.
So, the HMDI screen is connected:
apalis-imx8-06805164:~$ cat /sys/class/drm/card0-HDMI-A-1/status
connected
apalis-imx8-06805164:~$*cat /sys/class/drm/card0-HDMI-A-1/enabled
enabled
and the following modes are annonunced:
apalis-imx8-06805164:~$ cat /sys/class/drm/card0-HDMI-A-1/modes
1920x1080 1920x1080 1920x1080 1920x1080 1680x1050
1600x900 1280x1024 1280x1024 1440x900 1280x800
1152x864 1280x720 1280x720 1280x720 1280x720
1280x720 1024x768 1024x768 1024x768 832x624
800x600 800x600 800x600 800x600 720x576
720x576 720x480 720x480 720x480 720x480
640x480 640x480 640x480 640x480 640x480
720x400
apalis-imx8-06805164:~$
So, I made a new weston.ini (with a low resolution for testing):
apalis-imx8-06805164:~$ more weston.ini
[core]
idle-time=0
require-input=false
xwayland=true
[output]
mode=1024x768
[shell]
background-image=
background-color=0x00000000
panel-position=none
locking=false
allow-zap=false
num-workspaces=1
[keyboard]
vt-switching=false
apalis-imx8-06805164:~$
residing in /home/torizon. Then I start the Weston container with the following command (including -v /home/torizon/weston.ini:/etc/xdg/weston/weston.ini, which should copy the weston.ini file to the container).
apalis-imx8-06805164:~$ docker run -d --rm --name=weston --net=host --cap-add CAP_SYS_TTY_CONFIG -v /home/torizon/weston.ini:/etc/xdg/weston/weston.ini -v /dev:/dev -v /tmp:/tmp -v /run/udev/:/run/udev/ --device-cgroup-rule='c 4:* rmw' --device-cgroup-rule='c 13:* rmw' --device-cgroup-rule='c 199:* rmw' --device-cgroup-rule='c 226:* rmw' torizon/weston:$CT_TAG_WESTON --developer weston-launch --tty=/dev/tty7 --user=torizon
89d918aa9c08889a4bc44ebd8c796fab83fde0b2a4a0b9e37d45d7f78aa7a29e
apalis-imx8-06805164:~$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
89d918aa9c08 torizon/weston:2 "/usr/bin/entry.sh -…" 2 seconds ago Up 1 second weston
But the resolution does not change. The copy worked, because the modified weston.ini can be seen in a shell in the Weston container. I also tried /etc/xdg/weston-dev as destination för weston.ini, with the same result.
I also tried to to change the panel-position in the weston.ini file to bottom, but it had no effect. Is it neccessary to build a new weston container image to change video pars ? There seems to be no video mode specified in the kernel command line:
apalis-imx8-06805164:~$ cat /proc/cmdline
root=LABEL=otaroot rootfstype=ext4 quiet logo.nologo vt.global_cursor_default=0 plymouth.ignore-serial-consoles splash ostree=/ostree/boot.1/torizon/cad4230bb4cbaa931d36a90bd375a75fa3291d66311587ba799a563a81464ae0/0
Also, where is the video resolution set ? It seems that the default weston.ini file in the Weston container does not change the resolution, but the resolution does appear to change at some point in the boot process ?
Any suggestions ?
Confused,
Pernilla