Screen Orientation Incorrect

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Screen Orientation Incorrect

742 Views
justinzerjav
Contributor I

Hello,

We are having with a touchscreen LCD that we are designing.

We are attempting to set up the screen (Newhaven Display P/N: NHD-3.5-320240MF-ATXL#-CTP-1) on a Kinetis K70 board (Freescale P/N: MK70FN1M0VMJ15). We designed the screens in PEG Windowbuilder and PEG Pro. Our compiler is GCC, and our RTOS is MQX 4.2.

Our touch screen is rotated 180° from the orientation that we need it at. We are able to rotate the screen to 90° and 270°, but not 180° without causing the screen to mirror and display the images backwards (by enabling the reverse vertical scan bit in the LPCR control register). Due to the geometry of the housing, we cannot simply flip the screen and use it as-is, so our only option is to get the orientation correct.

We would greatly appreciate any insight into how this issue is happening, or how to correct it.

Thanks,

Justin Zerjav

Tags (3)
0 Kudos
2 Replies

517 Views
primozrebec
Contributor III

Hi All,

can i kindly ask what is the procedure for 90 degrees screen rotation? We have a similar setup with K70 and LCD display. Display's native orientation is portrait but we would like to have it in landscape position. Our current implementation involves display content to be rewritten to another frame buffer (rows to columns) but we would like to avoid this. I've noticed in AN4588 that K70 has this feature.

Best regards,

Primoz

0 Kudos

517 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi

I do a test with TWR-K70F120M board with TWR-LCD-RGB board.

The TWR-LCD-RGB LCD screen size is 480 X 272. The frame start address at 0x80400000, the frame buffer size is 0x7F800.

The original LCD display shows at below picture, the red color at top left corner (LCDC_LSSAR register value is 0x80400000):

2016-01-28_11-21-17.png

While after I set the LCDC_LPCR [REV_VS] bit and change LCDC_LSSAR register value to 0x8047F800, there make a horizontal mirror reverse.

After vertical scan reverse, please check below picture of the LCD display, the red color block at left bottom corner:

2016-01-28_11-23-28.png

My test code if from Kinetis 120MHz bare metal sample code LCDC demo, which could be downloaded from here.


Wish it helps
Have a great day,
Ma Hui

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos