Any tips on rotating an iMX6UL LCD Screen?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Any tips on rotating an iMX6UL LCD Screen?

2,214件の閲覧回数
abgironne
Contributor I

Hello, I've been trying to rotate a LVDS screen for quite some time now on a iMX6UL. For some mecanical reason it would be tricky to just turn the screen around so I've been looking for a software solution.

I'm using the framebuffer QT5 yocto build and I've been trying to recompile the kernel to ask for the v4l2 interface to rotate the image. 

So far I've learn that the iMX6UL uses the PXP driver but I'm not able to find the exact function that I need to change and call some kind of rotation event. I've found the mxc_pxp_v4l2.c file inside the kernel and I've been trying to modify and recompile it without success on having the screen rotated. I also notice that there are many file versions for the dma manipulation (pxp_dma_v2.c, pxp_dma_v3.c) and I don't know which file is used for real.

I'm not sure about how things are called out since I'm only changing pointers in a struct.

Anyone has tips or possibles solutions that I could try to make it work? Am I trying to change the appropriate files?

0 件の賞賛
返信
2 返答(返信)

2,200件の閲覧回数
abgironne
Contributor I

Ok I found out that the correct video driver used by the iMX6UL is the file: "drivers/video/fbdev/mxsfb.c". It looks so far like a pretty tricky operation to understand this code and make the image rotate at the driver level so I found out another possible solution.

By adding the FRAMEBUFFER_CONSOLE_ROTATION kernel setting in the kernel menuconfig I can rotate the Console using the standard fb rotation command: "echo 2 | sudo tee /sys/class/graphics/fbcon/rotate" for a 180 degrees rotation.

I also notice that by adding the parameter " --platform linuxfb:fb=/dev/fb0:rotation=180" when starting the QT5 application it would rotate the application. 

Now all I need to add is how to rotate the bootloader splash/loading screen and the goal should be achieved.

0 件の賞賛
返信

2,177件の閲覧回数
Juan-Rodarte
NXP Employee
NXP Employee

Hi Antony,

You should in the configuration set the initial orientation you need during boot, and then make the orientation changes you need.

Best Regards,

Diego.

0 件の賞賛
返信