fix lpc2148 demo
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@287 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
parent
6b77e031db
commit
4d263b6490
|
@ -42,99 +42,100 @@
|
||||||
/* thread phase init */
|
/* thread phase init */
|
||||||
void rt_init_thread_entry(void *parameter)
|
void rt_init_thread_entry(void *parameter)
|
||||||
{
|
{
|
||||||
/* Filesystem Initialization */
|
/* Filesystem Initialization */
|
||||||
#ifdef RT_USING_DFS
|
#ifdef RT_USING_DFS
|
||||||
{
|
{
|
||||||
/* init the device filesystem */
|
/* init the device filesystem */
|
||||||
dfs_init();
|
dfs_init();
|
||||||
/* init the efsl filesystam*/
|
/* init the efsl filesystam*/
|
||||||
efsl_init();
|
efsl_init();
|
||||||
|
|
||||||
/* mount sd card fat partition 1 as root directory */
|
/* mount sd card fat partition 1 as root directory */
|
||||||
if (dfs_mount("sd0", "/", "efs", 0, 0) == 0)
|
if (dfs_mount("sd0", "/", "efs", 0, 0) == 0)
|
||||||
rt_kprintf("File System initialized!\n");
|
rt_kprintf("File System initialized!\n");
|
||||||
else
|
else
|
||||||
rt_kprintf("File System init failed!\n");
|
rt_kprintf("File System init failed!\n");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* LwIP Initialization */
|
/* LwIP Initialization */
|
||||||
#ifdef RT_USING_LWIP
|
#ifdef RT_USING_LWIP
|
||||||
{
|
{
|
||||||
extern void lwip_sys_init(void);
|
extern void lwip_sys_init(void);
|
||||||
|
|
||||||
/* init lwip system */
|
/* init lwip system */
|
||||||
lwip_sys_init();
|
lwip_sys_init();
|
||||||
rt_kprintf("TCP/IP initialized!\n");
|
rt_kprintf("TCP/IP initialized!\n");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/************** LED BLINK *******************/
|
/************** LED BLINK *******************/
|
||||||
#include "lpc214x.h"
|
#include "lpc214x.h"
|
||||||
#define LED1 ( 1<<16) //P1
|
#define LED1 (1<<16) //P1
|
||||||
#define LED2 ( 1<<17) //P1
|
#define LED2 (1<<17) //P1
|
||||||
#define LED3 ( 1<<18) //P1
|
#define LED3 (1<<18) //P1
|
||||||
#define LED4 ( 1<<19) //P1
|
#define LED4 (1<<19) //P1
|
||||||
char thread3_stack[512];
|
char thread_led1_stack[512];
|
||||||
struct rt_thread thread3;
|
struct rt_thread thread_led1;
|
||||||
void thread3_entry(void* parameter)
|
void thread_led1_entry(void* parameter)
|
||||||
{
|
{
|
||||||
volatile unsigned int i;
|
volatile unsigned int i;
|
||||||
IO1DIR |= LED1;
|
IO1DIR |= LED1;
|
||||||
while(1)
|
while(1)
|
||||||
{
|
{
|
||||||
IO1CLR = LED1;
|
IO1CLR = LED1;
|
||||||
rt_thread_delay(20);
|
rt_thread_delay( RT_TICK_PER_SECOND/3 ); /* delay 0.3s */
|
||||||
IO1SET = LED1;
|
IO1SET = LED1;
|
||||||
rt_thread_delay(20);
|
rt_thread_delay( RT_TICK_PER_SECOND/3 );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
char thread4_stack[512];
|
char thread_led2_stack[512];
|
||||||
struct rt_thread thread4;
|
struct rt_thread thread_led2;
|
||||||
void thread4_entry(void* parameter)
|
void thread_led2_entry(void* parameter)
|
||||||
{
|
{
|
||||||
volatile unsigned int i;
|
volatile unsigned int i;
|
||||||
IO1DIR |= LED2;
|
IO1DIR |= LED2;
|
||||||
while(1)
|
while(1)
|
||||||
{
|
{
|
||||||
IO1CLR = LED2;
|
IO1CLR = LED2;
|
||||||
rt_thread_delay(30);
|
rt_thread_delay( RT_TICK_PER_SECOND/2 ); /* delay 0.5s */
|
||||||
IO1SET = LED2;
|
IO1SET = LED2;
|
||||||
rt_thread_delay(30);
|
rt_thread_delay( RT_TICK_PER_SECOND/2 );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/************** LED BLINK *******************/
|
/************** LED BLINK *******************/
|
||||||
|
|
||||||
int rt_application_init()
|
int rt_application_init()
|
||||||
{
|
{
|
||||||
rt_thread_init(&thread3,
|
rt_thread_init(&thread_led1,
|
||||||
"led1",
|
"led1",
|
||||||
thread3_entry, RT_NULL,
|
thread_led1_entry, RT_NULL,
|
||||||
&thread3_stack[0], sizeof(thread3_stack),
|
&thread_led1_stack[0], sizeof(thread_led1_stack),
|
||||||
20, 10);
|
20, 10);
|
||||||
|
|
||||||
rt_thread_init(&thread4,
|
rt_thread_init(&thread_led2,
|
||||||
"led2",
|
"led2",
|
||||||
thread4_entry, RT_NULL,
|
thread_led2_entry, RT_NULL,
|
||||||
&thread4_stack[0], sizeof(thread4_stack),
|
&thread_led2_stack[0], sizeof(thread_led2_stack),
|
||||||
25, 8);
|
25, 8);
|
||||||
rt_thread_startup(&thread3);
|
rt_thread_startup(&thread_led1);
|
||||||
rt_thread_startup(&thread4);
|
rt_thread_startup(&thread_led2);
|
||||||
|
|
||||||
{
|
/* inint SD-crad and dm9000 */
|
||||||
rt_thread_t init_thread;
|
{
|
||||||
|
rt_thread_t init_thread;
|
||||||
|
|
||||||
init_thread = rt_thread_create("init",
|
init_thread = rt_thread_create("init",
|
||||||
rt_init_thread_entry, RT_NULL,
|
rt_init_thread_entry, RT_NULL,
|
||||||
1024, 8, 5);
|
1024, 8, 5);
|
||||||
rt_thread_startup(init_thread);
|
rt_thread_startup(init_thread);
|
||||||
}
|
}
|
||||||
|
|
||||||
rt_kprintf("enter list() to get function list!\n");
|
rt_kprintf("\r\nenter list() to get function list!\r\n");
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*@}*/
|
/*@}*/
|
||||||
|
|
|
@ -10,106 +10,52 @@
|
||||||
CppX (*.cpp)
|
CppX (*.cpp)
|
||||||
DaveTm { 0,0,0,0,0,0,0,0 }
|
DaveTm { 0,0,0,0,0,0,0,0 }
|
||||||
|
|
||||||
Target (RT-Thread/LPC2148), 0x0004 // Tools: 'ARM-ADS'
|
Target (RT-Thread-LPC2148), 0x0004 // Tools: 'ARM-ADS'
|
||||||
GRPOPT 1,(Startup),1,0,0
|
GRPOPT 1,(Startup),1,0,0
|
||||||
GRPOPT 2,(Kernel),0,0,0
|
GRPOPT 2,(Kernel),0,0,0
|
||||||
GRPOPT 3,(LPC214x),0,0,0
|
GRPOPT 3,(LPC214x),0,0,0
|
||||||
GRPOPT 4,(finsh),0,0,0
|
GRPOPT 4,(finsh),0,0,0
|
||||||
GRPOPT 5,(Filesystem),0,0,0
|
|
||||||
GRPOPT 6,(LwIP),0,0,0
|
|
||||||
|
|
||||||
OPTFFF 1,1,1,150994944,0,0,0,0,<.\application.c><application.c>
|
OPTFFF 1,1,1,637534208,0,119,136,0,<.\application.c><application.c> { 44,0,0,0,0,0,0,0,1,0,0,0,255,255,255,255,255,255,255,255,252,255,255,255,226,255,255,255,110,0,0,0,145,0,0,0,100,4,0,0,240,1,0,0 }
|
||||||
OPTFFF 1,2,1,0,0,0,0,0,<.\board.c><board.c>
|
OPTFFF 1,2,1,0,0,0,0,0,<.\board.c><board.c>
|
||||||
OPTFFF 1,3,1,0,0,0,0,0,<.\startup.c><startup.c>
|
OPTFFF 1,3,1,33554434,0,2,18,0,<.\startup.c><startup.c> { 44,0,0,0,2,0,0,0,3,0,0,0,255,255,255,255,255,255,255,255,252,255,255,255,226,255,255,255,44,0,0,0,58,0,0,0,46,4,0,0,112,1,0,0 }
|
||||||
OPTFFF 1,4,1,0,0,0,0,0,<.\dm9000.c><dm9000.c>
|
OPTFFF 1,4,5,0,0,0,0,0,<.\rtconfig.h><rtconfig.h>
|
||||||
OPTFFF 1,5,1,0,0,0,0,0,<.\sd.c><sd.c>
|
OPTFFF 2,5,1,0,0,0,0,0,<..\..\src\clock.c><clock.c>
|
||||||
OPTFFF 1,6,5,0,0,0,0,0,<.\rtconfig.h><rtconfig.h>
|
OPTFFF 2,6,1,150994944,0,0,0,0,<..\..\src\device.c><device.c>
|
||||||
OPTFFF 2,7,1,0,0,0,0,0,<..\..\src\clock.c><clock.c>
|
OPTFFF 2,7,1,0,0,0,0,0,<..\..\src\ipc.c><ipc.c>
|
||||||
OPTFFF 2,8,1,150994944,0,0,0,0,<..\..\src\device.c><device.c>
|
OPTFFF 2,8,1,0,0,0,0,0,<..\..\src\mempool.c><mempool.c>
|
||||||
OPTFFF 2,9,1,0,0,0,0,0,<..\..\src\ipc.c><ipc.c>
|
OPTFFF 2,9,1,0,0,0,0,0,<..\..\src\object.c><object.c>
|
||||||
OPTFFF 2,10,1,0,0,0,0,0,<..\..\src\mempool.c><mempool.c>
|
OPTFFF 2,10,1,0,0,0,0,0,<..\..\src\timer.c><timer.c>
|
||||||
OPTFFF 2,11,1,0,0,0,0,0,<..\..\src\object.c><object.c>
|
OPTFFF 2,11,1,553648128,0,0,0,0,<..\..\src\idle.c><idle.c>
|
||||||
OPTFFF 2,12,1,0,0,0,0,0,<..\..\src\timer.c><timer.c>
|
OPTFFF 2,12,1,0,0,0,0,0,<..\..\src\irq.c><irq.c>
|
||||||
OPTFFF 2,13,1,0,0,0,0,0,<..\..\src\idle.c><idle.c>
|
OPTFFF 2,13,1,0,0,0,0,0,<..\..\src\mem.c><mem.c>
|
||||||
OPTFFF 2,14,1,0,0,0,0,0,<..\..\src\irq.c><irq.c>
|
OPTFFF 2,14,1,0,0,0,0,0,<..\..\src\scheduler.c><scheduler.c>
|
||||||
OPTFFF 2,15,1,0,0,0,0,0,<..\..\src\mem.c><mem.c>
|
OPTFFF 2,15,1,0,0,0,0,0,<..\..\src\slab.c><slab.c>
|
||||||
OPTFFF 2,16,1,0,0,0,0,0,<..\..\src\scheduler.c><scheduler.c>
|
OPTFFF 2,16,1,0,0,0,0,0,<..\..\src\thread.c><thread.c>
|
||||||
OPTFFF 2,17,1,0,0,0,0,0,<..\..\src\slab.c><slab.c>
|
OPTFFF 2,17,1,0,0,0,0,0,<..\..\src\kservice.c><kservice.c>
|
||||||
OPTFFF 2,18,1,0,0,0,0,0,<..\..\src\thread.c><thread.c>
|
OPTFFF 3,18,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\serial.c><serial.c>
|
||||||
OPTFFF 2,19,1,0,0,0,0,0,<..\..\src\kservice.c><kservice.c>
|
OPTFFF 3,19,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\interrupt.c><interrupt.c>
|
||||||
OPTFFF 3,20,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\serial.c><serial.c>
|
OPTFFF 3,20,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\cpu.c><cpu.c>
|
||||||
OPTFFF 3,21,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\interrupt.c><interrupt.c>
|
OPTFFF 3,21,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\trap.c><trap.c>
|
||||||
OPTFFF 3,22,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\cpu.c><cpu.c>
|
OPTFFF 3,22,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\stack.c><stack.c>
|
||||||
OPTFFF 3,23,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\trap.c><trap.c>
|
OPTFFF 3,23,2,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\start_rvds.s><start_rvds.s>
|
||||||
OPTFFF 3,24,1,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\stack.c><stack.c>
|
OPTFFF 3,24,2,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\context_rvds.s><context_rvds.s>
|
||||||
OPTFFF 3,25,2,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\start_rvds.s><start_rvds.s>
|
OPTFFF 4,25,1,0,0,0,0,0,<..\..\finsh\finsh_compiler.c><finsh_compiler.c>
|
||||||
OPTFFF 3,26,2,0,0,0,0,0,<..\..\libcpu\arm\lpc214x\context_rvds.s><context_rvds.s>
|
OPTFFF 4,26,1,0,0,0,0,0,<..\..\finsh\finsh_error.c><finsh_error.c>
|
||||||
OPTFFF 4,27,1,0,0,0,0,0,<..\..\finsh\finsh_compiler.c><finsh_compiler.c>
|
OPTFFF 4,27,1,0,0,0,0,0,<..\..\finsh\finsh_heap.c><finsh_heap.c>
|
||||||
OPTFFF 4,28,1,0,0,0,0,0,<..\..\finsh\finsh_error.c><finsh_error.c>
|
OPTFFF 4,28,1,0,0,0,0,0,<..\..\finsh\finsh_init.c><finsh_init.c>
|
||||||
OPTFFF 4,29,1,0,0,0,0,0,<..\..\finsh\finsh_heap.c><finsh_heap.c>
|
OPTFFF 4,29,1,0,0,0,0,0,<..\..\finsh\finsh_node.c><finsh_node.c>
|
||||||
OPTFFF 4,30,1,0,0,0,0,0,<..\..\finsh\finsh_init.c><finsh_init.c>
|
OPTFFF 4,30,1,0,0,0,0,0,<..\..\finsh\finsh_ops.c><finsh_ops.c>
|
||||||
OPTFFF 4,31,1,0,0,0,0,0,<..\..\finsh\finsh_node.c><finsh_node.c>
|
OPTFFF 4,31,1,0,0,0,0,0,<..\..\finsh\finsh_token.c><finsh_token.c>
|
||||||
OPTFFF 4,32,1,0,0,0,0,0,<..\..\finsh\finsh_ops.c><finsh_ops.c>
|
OPTFFF 4,32,1,0,0,0,0,0,<..\..\finsh\finsh_var.c><finsh_var.c>
|
||||||
OPTFFF 4,33,1,0,0,0,0,0,<..\..\finsh\finsh_token.c><finsh_token.c>
|
OPTFFF 4,33,1,0,0,0,0,0,<..\..\finsh\finsh_vm.c><finsh_vm.c>
|
||||||
OPTFFF 4,34,1,0,0,0,0,0,<..\..\finsh\finsh_var.c><finsh_var.c>
|
OPTFFF 4,34,1,0,0,0,0,0,<..\..\finsh\shell.c><shell.c>
|
||||||
OPTFFF 4,35,1,0,0,0,0,0,<..\..\finsh\finsh_vm.c><finsh_vm.c>
|
OPTFFF 4,35,1,0,0,0,0,0,<..\..\finsh\symbol.c><symbol.c>
|
||||||
OPTFFF 4,36,1,0,0,0,0,0,<..\..\finsh\shell.c><shell.c>
|
OPTFFF 4,36,1,0,0,0,0,0,<..\..\finsh\cmd.c><cmd.c>
|
||||||
OPTFFF 4,37,1,0,0,0,0,0,<..\..\finsh\symbol.c><symbol.c>
|
OPTFFF 4,37,1,0,0,0,0,0,<..\..\finsh\finsh_parser.c><finsh_parser.c>
|
||||||
OPTFFF 4,38,1,0,0,0,0,0,<..\..\finsh\cmd.c><cmd.c>
|
|
||||||
OPTFFF 4,39,1,0,0,0,0,0,<..\..\finsh\finsh_parser.c><finsh_parser.c>
|
|
||||||
OPTFFF 5,40,1,0,0,0,0,0,<..\..\filesystem\dfs\src\dfs_util.c><dfs_util.c>
|
|
||||||
OPTFFF 5,41,1,0,0,0,0,0,<..\..\filesystem\dfs\src\dfs_cache.c><dfs_cache.c>
|
|
||||||
OPTFFF 5,42,1,0,0,0,0,0,<..\..\filesystem\dfs\src\dfs_fs.c><dfs_fs.c>
|
|
||||||
OPTFFF 5,43,1,0,0,0,0,0,<..\..\filesystem\dfs\src\dfs_init.c><dfs_init.c>
|
|
||||||
OPTFFF 5,44,1,301989888,0,0,0,0,<..\..\filesystem\dfs\src\dfs_posix.c><dfs_posix.c>
|
|
||||||
OPTFFF 5,45,1,0,0,0,0,0,<..\..\filesystem\dfs\src\dfs_raw.c><dfs_raw.c>
|
|
||||||
OPTFFF 5,46,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\base\plibc.c><plibc.c>
|
|
||||||
OPTFFF 5,47,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\base\efs.c><efs.c>
|
|
||||||
OPTFFF 5,48,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\base\extract.c><extract.c>
|
|
||||||
OPTFFF 5,49,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\base\partition.c><partition.c>
|
|
||||||
OPTFFF 5,50,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\dir.c><dir.c>
|
|
||||||
OPTFFF 5,51,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\fat.c><fat.c>
|
|
||||||
OPTFFF 5,52,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\file.c><file.c>
|
|
||||||
OPTFFF 5,53,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\fs.c><fs.c>
|
|
||||||
OPTFFF 5,54,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\ls.c><ls.c>
|
|
||||||
OPTFFF 5,55,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\ui.c><ui.c>
|
|
||||||
OPTFFF 5,56,1,0,0,0,0,0,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\time.c><time.c>
|
|
||||||
OPTFFF 6,57,1,0,0,0,0,0,<..\..\net\lwip\src\netif\etharp.c><etharp.c>
|
|
||||||
OPTFFF 6,58,1,150994944,0,0,0,0,<..\..\net\lwip\src\netif\ethernetif.c><ethernetif.c>
|
|
||||||
OPTFFF 6,59,1,0,0,0,0,0,<..\..\net\lwip\src\core\udp.c><udp.c>
|
|
||||||
OPTFFF 6,60,1,0,0,0,0,0,<..\..\net\lwip\src\core\dhcp.c><dhcp.c>
|
|
||||||
OPTFFF 6,61,1,0,0,0,0,0,<..\..\net\lwip\src\core\dns.c><dns.c>
|
|
||||||
OPTFFF 6,62,1,0,0,0,0,0,<..\..\net\lwip\src\core\init.c><init.c>
|
|
||||||
OPTFFF 6,63,1,0,0,0,0,0,<..\..\net\lwip\src\core\memp_tiny.c><memp_tiny.c>
|
|
||||||
OPTFFF 6,64,1,0,0,0,0,0,<..\..\net\lwip\src\core\netif.c><netif.c>
|
|
||||||
OPTFFF 6,65,1,0,0,0,0,0,<..\..\net\lwip\src\core\pbuf.c><pbuf.c>
|
|
||||||
OPTFFF 6,66,1,0,0,0,0,0,<..\..\net\lwip\src\core\raw.c><raw.c>
|
|
||||||
OPTFFF 6,67,1,0,0,0,0,0,<..\..\net\lwip\src\core\stats.c><stats.c>
|
|
||||||
OPTFFF 6,68,1,0,0,0,0,0,<..\..\net\lwip\src\core\sys.c><sys.c>
|
|
||||||
OPTFFF 6,69,1,0,0,0,0,0,<..\..\net\lwip\src\core\tcp.c><tcp.c>
|
|
||||||
OPTFFF 6,70,1,0,0,0,0,0,<..\..\net\lwip\src\core\tcp_in.c><tcp_in.c>
|
|
||||||
OPTFFF 6,71,1,0,0,0,0,0,<..\..\net\lwip\src\core\tcp_out.c><tcp_out.c>
|
|
||||||
OPTFFF 6,72,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\ip_frag.c><ip_frag.c>
|
|
||||||
OPTFFF 6,73,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\autoip.c><autoip.c>
|
|
||||||
OPTFFF 6,74,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\icmp.c><icmp.c>
|
|
||||||
OPTFFF 6,75,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\igmp.c><igmp.c>
|
|
||||||
OPTFFF 6,76,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\inet.c><inet.c>
|
|
||||||
OPTFFF 6,77,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\inet_chksum.c><inet_chksum.c>
|
|
||||||
OPTFFF 6,78,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\ip.c><ip.c>
|
|
||||||
OPTFFF 6,79,1,0,0,0,0,0,<..\..\net\lwip\src\core\ipv4\ip_addr.c><ip_addr.c>
|
|
||||||
OPTFFF 6,80,1,0,0,0,0,0,<..\..\net\lwip\src\api\tcpip.c><tcpip.c>
|
|
||||||
OPTFFF 6,81,1,0,0,0,0,0,<..\..\net\lwip\src\api\api_lib.c><api_lib.c>
|
|
||||||
OPTFFF 6,82,1,0,0,0,0,0,<..\..\net\lwip\src\api\api_msg.c><api_msg.c>
|
|
||||||
OPTFFF 6,83,1,0,0,0,0,0,<..\..\net\lwip\src\api\err.c><err.c>
|
|
||||||
OPTFFF 6,84,1,0,0,0,0,0,<..\..\net\lwip\src\api\netbuf.c><netbuf.c>
|
|
||||||
OPTFFF 6,85,1,0,0,0,0,0,<..\..\net\lwip\src\api\netdb.c><netdb.c>
|
|
||||||
OPTFFF 6,86,1,0,0,0,0,0,<..\..\net\lwip\src\api\netifapi.c><netifapi.c>
|
|
||||||
OPTFFF 6,87,1,0,0,0,0,0,<..\..\net\lwip\src\api\sockets.c><sockets.c>
|
|
||||||
OPTFFF 6,88,1,0,0,0,0,0,<..\..\net\lwip\src\arch\sys_arch_init.c><sys_arch_init.c>
|
|
||||||
OPTFFF 6,89,1,0,0,0,0,0,<..\..\net\lwip\src\arch\sys_arch.c><sys_arch.c>
|
|
||||||
|
|
||||||
|
|
||||||
TARGOPT 1, (RT-Thread/LPC2148)
|
TARGOPT 1, (RT-Thread-LPC2148)
|
||||||
ADSCLK=12000000
|
ADSCLK=12000000
|
||||||
OPTTT 1,1,1,0
|
OPTTT 1,1,1,0
|
||||||
OPTHX 1,65535,0,0,0
|
OPTHX 1,65535,0,0,0
|
||||||
|
@ -123,7 +69,7 @@ TARGOPT 1, (RT-Thread/LPC2148)
|
||||||
OPTDBG 48125,6,()()()()()()()()()() (Segger\JLTAgdi.dll)()()()
|
OPTDBG 48125,6,()()()()()()()()()() (Segger\JLTAgdi.dll)()()()
|
||||||
OPTKEY 0,(DLGDARM)((134=-1,-1,-1,-1,0)(135=-1,-1,-1,-1,0)(153=-1,-1,-1,-1,0)(154=-1,-1,-1,-1,0)(108=-1,-1,-1,-1,0)(106=-1,-1,-1,-1,0)(105=-1,-1,-1,-1,0)(145=-1,-1,-1,-1,0)(147=-1,-1,-1,-1,0)(80=-1,-1,-1,-1,0)(104=-1,-1,-1,-1,0)(100=-1,-1,-1,-1,0)(101=-1,-1,-1,-1,0)(160=-1,-1,-1,-1,0)(161=-1,-1,-1,-1,0)(113=556,103,931,655,0)(112=-1,-1,-1,-1,0)(137=-1,-1,-1,-1,0)(138=-1,-1,-1,-1,0)(117=-1,-1,-1,-1,0)(146=-1,-1,-1,-1,0)(110=-1,-1,-1,-1,0)(111=-1,-1,-1,-1,0)(114=-1,-1,-1,-1,0)(141=-1,-1,-1,-1,0)(142=-1,-1,-1,-1,0)(143=-1,-1,-1,-1,0)(144=-1,-1,-1,-1,0)(115=-1,-1,-1,-1,0)(116=-1,-1,-1,-1,0))
|
OPTKEY 0,(DLGDARM)((134=-1,-1,-1,-1,0)(135=-1,-1,-1,-1,0)(153=-1,-1,-1,-1,0)(154=-1,-1,-1,-1,0)(108=-1,-1,-1,-1,0)(106=-1,-1,-1,-1,0)(105=-1,-1,-1,-1,0)(145=-1,-1,-1,-1,0)(147=-1,-1,-1,-1,0)(80=-1,-1,-1,-1,0)(104=-1,-1,-1,-1,0)(100=-1,-1,-1,-1,0)(101=-1,-1,-1,-1,0)(160=-1,-1,-1,-1,0)(161=-1,-1,-1,-1,0)(113=556,103,931,655,0)(112=-1,-1,-1,-1,0)(137=-1,-1,-1,-1,0)(138=-1,-1,-1,-1,0)(117=-1,-1,-1,-1,0)(146=-1,-1,-1,-1,0)(110=-1,-1,-1,-1,0)(111=-1,-1,-1,-1,0)(114=-1,-1,-1,-1,0)(141=-1,-1,-1,-1,0)(142=-1,-1,-1,-1,0)(143=-1,-1,-1,-1,0)(144=-1,-1,-1,-1,0)(115=-1,-1,-1,-1,0)(116=-1,-1,-1,-1,0))
|
||||||
OPTKEY 0,(ARMDBGFLAGS)(-T5F)
|
OPTKEY 0,(ARMDBGFLAGS)(-T5F)
|
||||||
OPTDF 0xB0
|
OPTDF 0x90
|
||||||
OPTLE <>
|
OPTLE <>
|
||||||
OPTLC <>
|
OPTLC <>
|
||||||
EndOpt
|
EndOpt
|
||||||
|
|
|
@ -1,20 +1,16 @@
|
||||||
### uVision2 Project, (C) Keil Software
|
### uVision2 Project, (C) Keil Software
|
||||||
### Do not modify !
|
### Do not modify !
|
||||||
|
|
||||||
Target (RT-Thread/LPC2148), 0x0004 // Tools: 'ARM-ADS'
|
Target (RT-Thread-LPC2148), 0x0004 // Tools: 'ARM-ADS'
|
||||||
|
|
||||||
Group (Startup)
|
Group (Startup)
|
||||||
Group (Kernel)
|
Group (Kernel)
|
||||||
Group (LPC214x)
|
Group (LPC214x)
|
||||||
Group (finsh)
|
Group (finsh)
|
||||||
Group (Filesystem)
|
|
||||||
Group (LwIP)
|
|
||||||
|
|
||||||
File 1,1,<.\application.c><application.c>
|
File 1,1,<.\application.c><application.c>
|
||||||
File 1,1,<.\board.c><board.c>
|
File 1,1,<.\board.c><board.c>
|
||||||
File 1,1,<.\startup.c><startup.c>
|
File 1,1,<.\startup.c><startup.c>
|
||||||
File 1,1,<.\dm9000.c><dm9000.c>
|
|
||||||
File 1,1,<.\sd.c><sd.c>
|
|
||||||
File 1,5,<.\rtconfig.h><rtconfig.h>
|
File 1,5,<.\rtconfig.h><rtconfig.h>
|
||||||
File 2,1,<..\..\src\clock.c><clock.c>
|
File 2,1,<..\..\src\clock.c><clock.c>
|
||||||
File 2,1,<..\..\src\device.c><device.c>
|
File 2,1,<..\..\src\device.c><device.c>
|
||||||
|
@ -49,59 +45,9 @@ File 4,1,<..\..\finsh\shell.c><shell.c>
|
||||||
File 4,1,<..\..\finsh\symbol.c><symbol.c>
|
File 4,1,<..\..\finsh\symbol.c><symbol.c>
|
||||||
File 4,1,<..\..\finsh\cmd.c><cmd.c>
|
File 4,1,<..\..\finsh\cmd.c><cmd.c>
|
||||||
File 4,1,<..\..\finsh\finsh_parser.c><finsh_parser.c>
|
File 4,1,<..\..\finsh\finsh_parser.c><finsh_parser.c>
|
||||||
File 5,1,<..\..\filesystem\dfs\src\dfs_util.c><dfs_util.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\src\dfs_cache.c><dfs_cache.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\src\dfs_fs.c><dfs_fs.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\src\dfs_init.c><dfs_init.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\src\dfs_posix.c><dfs_posix.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\src\dfs_raw.c><dfs_raw.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\base\plibc.c><plibc.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\base\efs.c><efs.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\base\extract.c><extract.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\base\partition.c><partition.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\dir.c><dir.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\fat.c><fat.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\file.c><file.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\fs.c><fs.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\ls.c><ls.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\ui.c><ui.c>
|
|
||||||
File 5,1,<..\..\filesystem\dfs\filesystems\efsl\src\fs\vfat\time.c><time.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\netif\etharp.c><etharp.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\netif\ethernetif.c><ethernetif.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\udp.c><udp.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\dhcp.c><dhcp.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\dns.c><dns.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\init.c><init.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\memp_tiny.c><memp_tiny.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\netif.c><netif.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\pbuf.c><pbuf.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\raw.c><raw.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\stats.c><stats.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\sys.c><sys.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\tcp.c><tcp.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\tcp_in.c><tcp_in.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\tcp_out.c><tcp_out.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\ip_frag.c><ip_frag.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\autoip.c><autoip.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\icmp.c><icmp.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\igmp.c><igmp.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\inet.c><inet.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\inet_chksum.c><inet_chksum.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\ip.c><ip.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\core\ipv4\ip_addr.c><ip_addr.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\tcpip.c><tcpip.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\api_lib.c><api_lib.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\api_msg.c><api_msg.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\err.c><err.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\netbuf.c><netbuf.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\netdb.c><netdb.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\netifapi.c><netifapi.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\api\sockets.c><sockets.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\arch\sys_arch_init.c><sys_arch_init.c>
|
|
||||||
File 6,1,<..\..\net\lwip\src\arch\sys_arch.c><sys_arch.c>
|
|
||||||
|
|
||||||
|
|
||||||
Options 1,0,0 // Target 'RT-Thread/LPC2148'
|
Options 1,0,0 // Target 'RT-Thread-LPC2148'
|
||||||
Device (LPC2148)
|
Device (LPC2148)
|
||||||
Vendor (NXP (founded by Philips))
|
Vendor (NXP (founded by Philips))
|
||||||
Cpu (IRAM(0x40000000-0x40007FFF) IROM(0-0x7FFFF) CLOCK(12000000) CPUTYPE(ARM7TDMI))
|
Cpu (IRAM(0x40000000-0x40007FFF) IROM(0-0x7FFFF) CLOCK(12000000) CPUTYPE(ARM7TDMI))
|
||||||
|
|
|
@ -84,7 +84,7 @@
|
||||||
/* #define RT_USING_CPLUSPLUS */
|
/* #define RT_USING_CPLUSPLUS */
|
||||||
|
|
||||||
/* SECTION: DFS options */
|
/* SECTION: DFS options */
|
||||||
#define RT_USING_DFS
|
/* #define RT_USING_DFS */
|
||||||
/* the max number of mounted filesystem */
|
/* the max number of mounted filesystem */
|
||||||
#define DFS_FILESYSTEMS_MAX 2
|
#define DFS_FILESYSTEMS_MAX 2
|
||||||
/* the max number of opened files */
|
/* the max number of opened files */
|
||||||
|
@ -94,7 +94,7 @@
|
||||||
|
|
||||||
/* SECTION: lwip, a lighwight TCP/IP protocol stack */
|
/* SECTION: lwip, a lighwight TCP/IP protocol stack */
|
||||||
/* Using lighweight TCP/IP protocol stack*/
|
/* Using lighweight TCP/IP protocol stack*/
|
||||||
#define RT_USING_LWIP
|
/* #define RT_USING_LWIP */
|
||||||
|
|
||||||
/* Trace LwIP protocol*/
|
/* Trace LwIP protocol*/
|
||||||
/* #define RT_LWIP_DEBUG */
|
/* #define RT_LWIP_DEBUG */
|
||||||
|
|
|
@ -57,84 +57,84 @@ extern int __bss_end;
|
||||||
*/
|
*/
|
||||||
void rtthread_startup(void)
|
void rtthread_startup(void)
|
||||||
{
|
{
|
||||||
/* init hardware interrupt */
|
/* init hardware interrupt */
|
||||||
rt_hw_interrupt_init();
|
rt_hw_interrupt_init();
|
||||||
|
|
||||||
/* init board */
|
/* init board */
|
||||||
rt_hw_board_init();
|
rt_hw_board_init();
|
||||||
|
|
||||||
/* init tick */
|
/* init tick */
|
||||||
rt_system_tick_init();
|
rt_system_tick_init();
|
||||||
|
|
||||||
/* init kernel object */
|
/* init kernel object */
|
||||||
rt_system_object_init();
|
rt_system_object_init();
|
||||||
|
|
||||||
rt_show_version();
|
rt_show_version();
|
||||||
|
|
||||||
/* init timer system */
|
/* init timer system */
|
||||||
rt_system_timer_init();
|
rt_system_timer_init();
|
||||||
|
|
||||||
#ifdef RT_USING_HEAP
|
#ifdef RT_USING_HEAP
|
||||||
#ifdef __CC_ARM
|
#ifdef __CC_ARM
|
||||||
rt_system_heap_init((void*)&Image$$RW_IRAM1$$ZI$$Limit, (void*)0x40008000);
|
rt_system_heap_init((void*)&Image$$RW_IRAM1$$ZI$$Limit, (void*)0x40008000);
|
||||||
#else
|
#else
|
||||||
/* init memory system */
|
/* init memory system */
|
||||||
rt_system_heap_init((void*)&__bss_end, (void*)0x40008000);
|
rt_system_heap_init((void*)&__bss_end, (void*)0x40008000);
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* init scheduler system */
|
/* init scheduler system */
|
||||||
rt_system_scheduler_init();
|
rt_system_scheduler_init();
|
||||||
|
|
||||||
#ifdef RT_USING_HOOK /* if the hook is used */
|
#ifdef RT_USING_HOOK /* if the hook is used */
|
||||||
/* set idle thread hook */
|
/* set idle thread hook */
|
||||||
rt_thread_idle_sethook(0);
|
rt_thread_idle_sethook(0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef RT_USING_DEVICE
|
#ifdef RT_USING_DEVICE
|
||||||
#ifdef RT_USING_DFS
|
#ifdef RT_USING_DFS
|
||||||
/* init sd card */
|
/* init sd card */
|
||||||
rt_hw_sdcard_init();
|
rt_hw_sdcard_init();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef RT_USING_LWIP
|
#ifdef RT_USING_LWIP
|
||||||
eth_system_device_init();
|
eth_system_device_init();
|
||||||
/* init ethernetif device */
|
/* init ethernetif device */
|
||||||
rt_hw_dm9000_init();
|
rt_hw_dm9000_init();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* init hardware serial device */
|
/* init hardware serial device */
|
||||||
rt_hw_serial_init();
|
rt_hw_serial_init();
|
||||||
|
|
||||||
/*init all registed devices*/
|
/*init all registed devices*/
|
||||||
rt_device_init_all();
|
rt_device_init_all();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* init application */
|
/* init application */
|
||||||
rt_application_init();
|
rt_application_init();
|
||||||
|
|
||||||
#ifdef RT_USING_FINSH
|
#ifdef RT_USING_FINSH
|
||||||
/* init finsh */
|
/* init finsh */
|
||||||
finsh_system_init();
|
finsh_system_init();
|
||||||
finsh_set_device("uart1");
|
finsh_set_device("uart1");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* init idle thread */
|
/* init idle thread */
|
||||||
rt_thread_idle_init();
|
rt_thread_idle_init();
|
||||||
|
|
||||||
/* start scheduler */
|
/* start scheduler */
|
||||||
rt_system_scheduler_start();
|
rt_system_scheduler_start();
|
||||||
|
|
||||||
/* never reach here */
|
/* never reach here */
|
||||||
return ;
|
return ;
|
||||||
}
|
}
|
||||||
|
|
||||||
int main (void)
|
int main (void)
|
||||||
{
|
{
|
||||||
/* invoke rtthread_startup */
|
/* invoke rtthread_startup */
|
||||||
rtthread_startup();
|
rtthread_startup();
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*@}*/
|
/*@}*/
|
||||||
|
|
Loading…
Reference in New Issue