📄 main.c
字号:
/*********************************************************************************************
* File: main.c
* Author: embest
* Desc: c main entry
* History:
*********************************************************************************************/
#include "lcd.h"
#include "bmp.h"
extern const UINT8T g_ucBitmap[][76800];
/*------------------------------------------------------------------------------------------*/
/* extern function */
/*------------------------------------------------------------------------------------------*/
extern void lcd_test();
/*------------------------------------------------------------------------------------------*/
/* function declare */
/*------------------------------------------------------------------------------------------*/
void Main(void);
void lcd_test(void);
/*********************************************************************************************
* name: main
* func: c code entry
* para: none
* ret: none
* modify:
* comment:
*********************************************************************************************/
void Main(void)
{
sys_init(); /* Initial 44B0X's Interrupt,Port and UART */
uart_printf("\n\rEmbest EduKit II Evaluation Board");
uart_printf("\n\rLCD display Test Example(please look at LCD screen)\n");
lcd_test();
while(1);
}
/*********************************************************************************************
* name: lcd_test()
* func: LCD test function
* para: none
* ret: none
* modify:
* comment:
*********************************************************************************************/
void lcd_test(void)
{
int i;
lcd_init(); // initial LCD controller
lcd_clr(); // clear screen
#ifdef CHINESE_VERSION
lcd_disp_hz16(10,10,BLUE,"英蓓特三星实验平台");
#else
lcd_disp_ascii8x16(10,0,BLUE,"Embest S3CEV40 ");
#endif
lcd_disp_ascii8x16(10,24,GREEN-55,"ShenZhen Embest Info&Tech Co.,LTD");
/* draw rectangle pattern */
lcd_draw_box(10,40,310,230,GREEN);
lcd_draw_box(20,45,300,225,GREEN);
lcd_draw_box(30,50,290,220,GREEN);
lcd_draw_box(40,55,280,215,GREEN);
LCD_D_ON;
delay(30000);
while (1)
{
for (i = 0; i < 5; i++)
{
bitmap_view320x240x256((UINT8T*)(g_ucBitmap[i]));
delay(20000);
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -