emWin can not read from SSD1963?

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

emWin can not read from SSD1963?

1,469件の閲覧回数
philiphills
Contributor I

I am using the NXP emWin (5.38a) library running on an LPC1768 to drive a 800 x 480 pixel LCD panel using a Solomon SSD1963 controller. I have configured emWin to use the FlexColor driver with 16 bpp (565 format), no cache, and a 16 bit parallel bus, and allocated 30K bytes of RAM for emWin. I can execute various commands that write to the display (GUI_FillCircle, GUI_Drawline, GUI_DispString), but not commands that read-modify-write to the display (GUI_InvertRect). The display is distorted (the width of all shapes is reduced by half) and the colors are not properly inverted.

 

It seems that emWin performs two 16-bit reads for each pixel, saving the first 16-bit word as the Red value and the second as the Blue value. Nothing is read for the Green value, which defaults to zero.

 

Because two pixels (words) are read from the SSD1963 and combined into one pixel in the emWin memory, the shape width is reduced by half. Also the color values are interpreted incorrectly.

 

Things get more interesting when working with text. If I first set the text mode to XOR with GUI_SetTextMode(GUI_TM_XOR) and then display text with GUI_DispString, it appears that emWin performs four 16-bit reads for each pixel; the first two reads are dummy, the next two are the Red and Blue values as above, and Green again defaults to zero.

 

I believe that I have configured emWin correctly, since all the write routines are working properly. Is this a bug in emWin? I suspect so, since the read operations are inconsistent without changing the configuration. Has anyone out there been able to perform read-modify-write operations using emWin on an SSD1963?

 

ラベル(1)
0 件の賞賛
返信
2 返答(返信)

881件の閲覧回数
philiphills
Contributor I

After Sol redirected this question to the SEGGER forum, it was answered by a SEGGER super moderator. At his suggestion, I added the following line after setting up the FlexColor driver for the SSD1963:

  

   GUIDRV_FlexColor_SetReadFunc66720_B16(pDevice, GUIDRV_FLEXCOLOR_READ_FUNC_II);

According to the emWin User Manual, this configures the FlexColor driver to use 2 cycles and no data conversion, instead of 3 cycles with data conversion (the default.)

After making the change, the graphical commands [ GUI_InvertRect() ] now work correctly. However, the text commands [ GUI_SetTextMode(GUI_TM_XOR) ]  display the wrong color text.

So I guess I have half of my answer....

0 件の賞賛
返信

881件の閲覧回数
soledad
NXP Employee
NXP Employee

Hi,

 

I redirected this issue to SEGGER forum. Please check the following thread

emWin can not read from SSD1963? - emWin related - SEGGER Forum 

 


Have a great day,
Sol

 

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

1 person found this helpful