How to clear just one layer on tft

cancel
Showing results for 
Search instead for 
Did you mean: 

How to clear just one layer on tft

Jump to solution
253 Views
cedricpillet
Contributor I

Hello everyone !

I'm working on MPC560XS target with a TFT connected and i'm facing to a major issue.

I can't find a way to clear just one layer (by the 16 available with the freescale library).

 

Here is my application :

I display a picture (with Display_InitLayer() ) with 4bpp clut, and I want to make it blink as if it is a led.

But the only solution I can manage to find is to re-print all elements on the screen which make the one i'm interested to make disappear, disappear, but also all the screen because of the many texts I'm displaying.

 

 

 

Sorry if my english is not very accurate, I will do my best to make me understood.

 

Best regards.

Labels (1)
Tags (2)
0 Kudos
1 Solution
189 Views
PetrS
NXP TechSupport
NXP TechSupport

Hi,

 

If you want just “blink a layer” so the graphic, that is on this layer, disappears and appears again, it should be enough to just toggle the Layer Enable bit  (EN) of the CtrlDescLx_4 register.

Use e.g.

DCU.LAYER[0].CTRLDESCL4.B.EN = 1; and DCU.LAYER[0].CTRLDESCL4.B.EN = 0;

BR, Petr

View solution in original post

0 Kudos
2 Replies
190 Views
PetrS
NXP TechSupport
NXP TechSupport

Hi,

 

If you want just “blink a layer” so the graphic, that is on this layer, disappears and appears again, it should be enough to just toggle the Layer Enable bit  (EN) of the CtrlDescLx_4 register.

Use e.g.

DCU.LAYER[0].CTRLDESCL4.B.EN = 1; and DCU.LAYER[0].CTRLDESCL4.B.EN = 0;

BR, Petr

0 Kudos
189 Views
cedricpillet
Contributor I

Hi,

Thanks for your answer.

Yes indeed I don't why I didn't manage to make it work before but now it's working.

Though I don't call the register directly but I use the macro instead provided by the freescale library which does the same.

DCU_LayerDisable(layer); which does DCU.LAYER[layer].CTRLDESCL4.B.EN = 0;

Thanks again !

have a nice day.

0 Kudos