如何正确使用emwin图书馆

⚠️
Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads at//www.xmece.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
5 posts / 0 new
Last post
火鸟
Offline
Last seen:4 weeks 1 day ago
加入:2019-07-12 09:48
如何正确使用emwin图书馆

Hi, teams.

I have ported emWin library to my project, and create a new diplay driver for my board.

To test display, I copied very simple codes from examples like follows:

GUI_Init(); GUI_SetColor(GUI_WHITE); GUI_SetBkColor(GUI_BLACK); GUI_Clear(); GUI_FillCircle(40,40,40);

GUI_Init() returns successfully, and screen_power_on(), screen_setup(), and screen_enable() functions are properly called.

But, GUI_Clear(), GUI_FillCircle() functions never works.

I have put some debug prints to dev_draw() and some driver specific functions like screen_pre_draw(), but these functions are not even called.

Any advice about how I can debug this issue?

Device:
PM_Dialog
Offline
Last seen:7 hours 32 min ago
Staff
加入:2018-02-08 11:03
Hi firebird,

Hi firebird,

Please check out the documentation and the demo which are available on our support website. Have you followed the correct steps?

//www.xmece.com/products/connectivity/bluetooth-low-energy/smartbond-reference-designs/emwin

Thanks, PM_Dialog

火鸟
Offline
Last seen:4 weeks 1 day ago
加入:2019-07-12 09:48
I have followed the guideline

I have followed the guideline in the above pages.

All the display setup codes works fine, but emWin never executes actual drawing codes.

i.e. gdi_display_update() or gdi_display_update_async() is not called. Why?

P.S.> I did not use the emwin demo code exactly the same, because window manager or image animation is too much for my testing purpose.

I think the simple clear screen or drawing circle should work without adding complex codes.

火鸟
Offline
Last seen:4 weeks 1 day ago
加入:2019-07-12 09:48
To explain my question based

To explain my question based on document//www.xmece.com/products/connectivity/bluetooth-low-energy/smartbond-reference-designs/emwin:

Fig.6 Display Initialization Sequence is successful.

But, in Fig.7, LCD_X_SHOWBUFFER in LCD_X_DisplayDriver() is never called.

火鸟
Offline
Last seen:4 weeks 1 day ago
加入:2019-07-12 09:48
After I blocked drawing codes

After I blocked drawing codes with GUI_MULTIBUF_Begin()/GUI_MULTIBUF_End(), the display is working fine.

Case closed.