egui touch calibration

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

egui touch calibration

ソリューションへジャンプ
1,272件の閲覧回数
Toe
Contributor IV

I am a little confused by some things on a 240x320 screen.  Our display comes oriented in portrait mode, so the built in touch calibration is misleading when following the xr, xl, yu, yd inputs from the display.  Calibrating in portrait mode causes the x and y count per pixel to be divided by the wrong value.  The code is in d4d_low.c

 

snip:

...// Calculate number of (bits / pixel) * 16 for Xd4d_tchCalib.TouchScreenXBitsPerPixelx16 = (Word)((dX * 16)/(D4D_SCREEN_SIZE_LONGER_SIDE - D4DTCH_CALIB_CROSS_OFFSET * 2));// Does number of ADC bits per pixel in X seem reasonable?if (d4d_tchCalib.TouchScreenXBitsPerPixelx16 < ((16 * p_tchRawLimits->rawDataScale) / D4D_SCREEN_SIZE_LONGER_SIDE))        {    // Calculate number of (bits / pixel) * 16 for Y    d4d_tchCalib.TouchScreenYBitsPerPixelx16 = (Word)((dY * 16)/(D4D_SCREEN_SIZE_SHORTER_SIDE - D4DTCH_CALIB_CROSS_OFFSET * 2));    // Does number of ADC bits per pixel in Y seem reasonable?    if (d4d_tchCalib.TouchScreenYBitsPerPixelx16 < ((16 * p_tchRawLimits->rawDataScale) / D4D_SCREEN_SIZE_SHORTER_SIDE))...

 

Since this screen we are using defaults to "portrait" the x and y are reversed.  x is the shorter side and when displaying this during calibration the text would be reversed as well.

 

This isn't a hard fix, just commenting that it might be helpful to make this more configurable in the user_cfg.

0 件の賞賛
返信
1 解決策
1,030件の閲覧回数
Gargy
NXP Employee
NXP Employee

Hi,

 you absolutely right, thank you for the feedback.

By the way three days ago I found some issue because I start test on 800x480 pixels LCD in portrait mode.

 

Thank you

 

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
1,031件の閲覧回数
Gargy
NXP Employee
NXP Employee

Hi,

 you absolutely right, thank you for the feedback.

By the way three days ago I found some issue because I start test on 800x480 pixels LCD in portrait mode.

 

Thank you

 

0 件の賞賛
返信