📄 44btest.c
字号:
#include <stdlib.h>
#include <string.h>
#include "..\inc\option.h"
#include "..\inc\44b.h"
#include "..\inc\44blib.h"
#include "..\inc\def.h"
#include "..\inc\lcd.h"
#include "..\inc\lcdlib.h"
#include "..\inc\glib.h"
#include "..\inc\clcd.h"
void * function[][2]=
{
#if (LCD_TYPE==CLCD_640_480)
(void *)Test_LcdColor_640X480, "640x480 Color Lcd test ",
#endif
0,0
};
void Main(void)
{
int i;
rSYSCFG=CACHECFG;
__rt_lib_init(); //for ADS 1.0
Port_Init();
Uart_Init(0,115200);
//rSBUSCON=(1<<31)|(3<<6)|(2<<4)|(1<<2)|(0); //nBREQ>BDMA>ZDMA>LCD_DMA
Uart_Select(0);
Delay(0); //calibrate Delay()
while(1)
{
i=0;
Uart_Printf("\n\nS3C44B0X Test Program Ver 0.00 rSYSCFG=0x%x MCLK=%d\n\n",rSYSCFG,MCLK);
while(1)
{ //display menu
Uart_Printf("%2d:%s",i,function[i][1]);
i++;
if((int)(function[i][0])==0)
{
Uart_Printf("\n");
break;
}
if((i%4)==0)
Uart_Printf("\n");
}
Uart_Printf("\nSelect the function to test?");
i=Uart_GetIntNum();
Uart_Printf("\n");
if(i>=0 && (i<(sizeof(function)/8)) )
( (void (*)(void)) (function[i][0]) )();
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -