#include "gd32f4xx.h"
#include "systick.h"
#include "lcd_init.h"
#include "lcd.h"
int main(void)
{
float t = 0;
nvic_priority_group_set(NVIC_PRIGROUP_PRE2_SUB2); // 优先级分组
systick_config();//滴答定时器初始化 1ms
LCD_Init();//屏幕初始化
LCD_Fill(0,0,LCD_W,LCD_H,BLACK);//清全屏为黑色
while(1)
{
LCD_ShowString(0,16*2,"LCD_W:",WHITE,BLACK,16,0);
LCD_ShowIntNum(48,16*2,LCD_W,3,WHITE,BLACK,16);
LCD_ShowString(80,16*2,"LCD_H:",WHITE,BLACK,16,0);
LCD_ShowIntNum(128,16*2,LCD_H,3,WHITE,BLACK,16);
LCD_ShowString(0,16*3,"Nun:",WHITE,BLACK,16,0);
LCD_ShowFloatNum1(8*4,16*3,t,4,WHITE,BLACK,16);
t+=0.11;
delay_1ms(1000);
}
}