cancel
Showing results for 
Search instead for 
Did you mean: 

STemWin AN4323 clock enable issue

asafbit
Associate II
Posted on November 05, 2015 at 10:21

hello

as required in the STemwin manual i have to enable RCC AHB1 CRC clock.

 ''The CRC module (in RCC peripheral clock enable register) should be enabled before using the library''

trying to use 

RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_CRC, ENABLE);

as it apears at AN4323,

i get error ''identifier undefined'' and ''function declared implicitly''

how i enable that?
6 REPLIES 6
Nesrine M_O
Lead II
Posted on November 05, 2015 at 11:03

Hi Assaf,

1- What are you using as STM32 product?

2- You are using SPL or HAL libraries?

You need to check the correct function to enable CRC clock.

-Syrine-

asafbit
Associate II
Posted on November 05, 2015 at 13:06

Thank you for your reply.

1. I'm using STM324x9I-Eval with Himax Driver LCD.

2. I'm using HAL Libraries and found that Define. 

  __HAL_RCC_CRC_CLK_ENABLE();

is that correct? if yes - 

i still have problems using MEMDEV.

Nesrine M_O
Lead II
Posted on November 05, 2015 at 13:41

Hi Assaf,

Yes it is the correct function. But now please explain with more details the new problem.

I'd highly recommend you to have a look to STemWin examples under STM32Cube F4 package: 

STM32Cube_FW_F4_V1.9.0\Projects\STM324x9I_EVAL\Applications\STemWin, it can be very useful.

-Syrine-

asafbit
Associate II
Posted on November 05, 2015 at 14:40

I'm drawing bitmap to the screen, its taking time and i have flickering - video attached.

i'm trying to solve that by using MEMDEV, but i can't see any change.

here is the flow:

1. create 1 memory device.

2. select the relevant handle.

3. drawing anything to it.

4. copy to lcd.

what happens is, writing to MEMDEV writes to the screen as well, before copy to LCD.

GUI_MEMDEV_Handle hMemDev1= GUI_MEMDEV_Create(0,0,240,320);

GUI_MEMDEV_Select(hMemDev1);

GUI_SetFont(&GUI_FontOpenSansRegular27);

GUI_SetColor(0x42CADE);

//GUI_SetBkColor(0x2A2A2A);

GUI_DispStringHCenterAt(''WRITE'' ,(LCD_GetXSize()/2),28);

GUI_MEMDEV_CopyToLCD(hMemDev1);.

iv'e also tried to GUI_Draw_Bitmap() and its acting the same.

Thank you for your help.

________________

Attachments :

TRIM_20151104_091451.zip : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HtWJ&d=%2Fa%2F0X0000000aRC%2FZQcglF_htDv_9L8YB03S8J.CVMvIkFc_ZdydqU2EbbQ&asPdf=false
Nesrine M_O
Lead II
Posted on November 06, 2015 at 09:48

Hi Assaf,

I would like to give you some advices that can be useful: 

1- The use of ''multi-buffering'' functionality to avoid flickering effect: 

· Add the enable of multi-buffring functionality to your application: WM_MULTIBUF_Enable(1);

· update ''LCDConf.c'' file => #define NUM_BUFFERS 3

2- To accelerate the bitmap drawing, it is recommended to use the Chrom-ART Accelerator.

-Syrine –

asafbit
Associate II
Posted on November 07, 2015 at 19:45

I do use multi-buffering as you adviced, and that's how its looks, in the video. thats why im trying the MEMDEV option.

can you refer me to some example of how to use Chrome-ART?