📄 main.c
字号:
#include <math.h>
#include <stddef.h>
#include "gui\core\GUI.h"
#include "Target\44b.h"
#include "Target\44blib.h"
/********************************************/
// ARMSYS实验二十一:在GUI中应用汉字库
// 描述:利用GUI提供的API函数绘制汉字
/********************************************/
void Main(void) {
int i=0;
int LCDXSize = LCD_GET_XSIZE();
int LCDYSize = LCD_GET_YSIZE();
rSYSCFG=CACHECFG;// Using 8KB Cache//
Port_Init();
Uart_Init(0,115200);
Led_Display(0xf);
Delay(0);
Beep(0x01);
Uart_Select(0); //Select UART0//
Uart_Printf("\n\n*************************************************************************");
Beep(0x0);
Uart_Printf("\n* 立泰电子 *");
Uart_Printf("\n* -GUI应用:汉字显示- *");
Uart_Printf("\n* Version 1.10 *");
Uart_Printf("\n* Email:rao_dali@263.net *");
Uart_Printf("\n* UART Config--COM:115.2kbps,8Bit,NP,UART0 *");
Uart_Printf("\n*------------------Begin to Start Drawing,OK? (Y/N)---------------------*");
Led_Display(0x0);
GUI_Init();
GUI_SetBkColor(GUI_BLACK);
GUI_Clear();
GUI_SetColor(GUI_RED);
GUI_SetFont(&GUI_FontHZ12);//设置字体
GUI_DispStringHCenterAt("你好吗?\nHow are you?\x0", LCDXSize/2, LCDYSize/2);//在屏幕中心显示文字
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -