Capacitive touch display not showing entire image

I have compiled a custom image based on the tdx-reference-multimedia-image. When using the Toradex Capacitive Touch 7’ display, the image is not displayed on the entire width of the screen. I can get it to work using the command:

fw_setenv vidargs 'video=mxsfb:800x480M-16@60,pixclockpol=1'

However, I would like to have the image build for this display, so I can avoid manually configure each module flashed with this image. So, I modified the device tree (based on the device tree for the Aster board), according to the overlay for the Capacitive Touch 7’ display.

I have attached my device tree source file. Although the settings are the same, the image is still not displayed on the entire width of the screen and only using the command above I can fix it. These are the settings for the display:

&lcdif {
	display = <&display0>;
	status = "okay";

	display0: lcd-display {
		bits-per-pixel = <16>;
		bus-width = <18>;

		display-timings {
			native-mode = <&timing_wvga>;

            /* LT161010 display (7inch) */
			timing_wvga: 800x480 {
				clock-frequency = <33230769>;
				hactive = <800>;
				vactive = <480>;
				hback-porch = <88>;
				hfront-porch = <40>;
				vback-porch = <33>;
				vfront-porch = <10>;
				hsync-len = <128>;
				vsync-len = <1>;

				de-active = <1>;
				hsync-active = <0>;
				vsync-active = <0>;
				pixelclk-active = <1>;
			};
		};
	};
};

Can someone tell me what is wrong with my device tree? Or are there other configurations/settings required?

Could you describe how did you compile and apply updated device tree? And please specify which exactly Toradex image you are using. The “Toradex Linux BSP 5” is too ambiguous.

Hi! I have modified the device tree source file for the Aster board (imx6ull-colibri-aster.dtsi) and compiled it according to this article. I built the image using Yocto. Because I don’t know yet how to include the new device tree in the Yocto build (see this question), I have made two copies of it and renamed them as imx6ull-colibri-wifi-eval-v3.dtb and imx6ull-colibri-eval-v3.dtb and replaced them in the image archive (it is a workaround I found to deploy the device tree).

I am using the tdx-reference-multimedia-image.

You can replace a device tree without image reflashing. DTB file located at UBI partition1 dev/ubi0_1. To replace it from Linux please use

 ubiupdatevol /dev/ubi0_1  <DTB file>

Thank you. It is good to know, especially for quick tests. Do you have an idea what is wrong with my device tree? Are there other configurations necessary? It is weird that the displayed image is OK after giving the command:

fw_setenv vidargs 'video=mxsfb:800x480M-16@60,pixclockpol=1'

although the resolution and clock polarity have the same values in the device tree.

Our BSP supports configuration of framebuffer resolution from kernel command line using the kernel internal modedb. If no resolution is given on the command line (e.g. cleared vidargs doing setenv vidargs from within U-Boot) the native-mode from the device tree is taken.

Ok. How can I perform this configuration when building the image using Yocto? Please, can you detail this?

You can modify a U_Boot env variable either by changing U_boot source code or by updating u_boot_env property at package json file. See details here.

I’ve changed in the u-boot-initial-env file this line:

vidargs=video=mxsfb:640x480M-16@60

to

vidargs=video=mxsfb:800x480M-16@60

and it displayed correctly. However, if I use:

vidargs=video=mxsfb:800x480M-16@60,pixclockpol=1

at the end of the image installation I get the warning “Bad CRC, using default environment. Line 65 not corrected terminated or too long”. Line 65 is exactly the line above. What is wrong with the syntax?

I’ve tested this u-boot-initial-env file with Linux Reference Minimal image
5.1.0+build.4
and

vidargs=video=mxsfb:800x480M-16@60,pixclockpol=1

string was accepted with no errors. Please doublecheck your u-boot-initial-env file for some unprinted symbols.

Hi. I confirm that the file needed two empty lines after the last line to work. Thank you!

You are very welcome! Thanks for an update.