1,KEIL设置
2,
3,
4,
5,RuninRAM.sct设置
6,
哈哈!这样KEIL环境已经建立好了,先给我的MICRO2440写个亮灯的程序,GPB5,GPB6,GPB7,GPB8为开发板上的四个LED,先点亮他,程序编译后产生BIN档文件,通过DNW下载到开发板中,启动方式为NORFLASH,见上面的设置。程序如下:
//#i nclude "S3C2440.h" /* S3C2440 definitions */
#define rGPBCON (*(volatile unsigned *)0x56000010) //Port Bcontrol
#define rGPBDAT (*(volatile unsigned *)0x56000014) //Port B data
#define rGPBUP (*(volatile unsigned *)0x56000018) //Pull-up control B
/*----------------------------------------------------------------------------
* Main: Initialize and start RTX Kernel
*---------------------------------------------------------------------------*/
int main (void) {
/* Initialize RTX and start init */
//int i;
//Port_Init();
rGPBCON = 0x15400;
rGPBUP = 0xff; // The pull up is disabled GPB[7:0]
rGPBDAT=0x0;
while (1)
{
;
}
}
文章评论(0条评论)
登录后参与讨论