1 /* RT-Thread config file */ 2 #ifndef __RTTHREAD_CFG_H__ 3 #define __RTTHREAD_CFG_H__ 4 5 /* RT_NAME_MAX*/ 6 #define RT_NAME_MAX 8 7 8 /* RT_ALIGN_SIZE*/ 9 #define RT_ALIGN_SIZE 8 10 11 /* PRIORITY_MAX */ 12 #define RT_THREAD_PRIORITY_MAX 32 13 14 /* Tick per Second */ 15 #define RT_TICK_PER_SECOND 100 16 17 /* SECTION: RT_DEBUG */ 18 /* Thread Debug */ 19 #define RT_DEBUG 20 #define RT_DEBUG_COLOR 21 //#define THREAD_DEBUG 22 #define SCHEDULER_DEBUG 23 //#define IRQ_DEBUG 24 25 #define IDLE_THREAD_STACK_SIZE 1024 26 27 #define RT_USING_OVERFLOW_CHECK 28 29 /* Using Hook */ 30 #define RT_USING_HOOK 31 32 /* Using Software Timer */ 33 /* #define RT_USING_TIMER_SOFT */ 34 #define RT_TIMER_THREAD_PRIO 4 35 #define RT_TIMER_THREAD_STACK_SIZE 512 36 #define RT_TICK_PER_SECOND 10 37 38 /* SECTION: IPC */ 39 /* Using Semaphore*/ 40 #define RT_USING_SEMAPHORE 41 42 /* Using Mutex */ 43 #define RT_USING_MUTEX 44 45 /* Using Event */ 46 #define RT_USING_EVENT 47 48 /* Using MailBox */ 49 #define RT_USING_MAILBOX 50 51 /* Using Message Queue */ 52 #define RT_USING_MESSAGEQUEUE 53 54 /* SECTION: Memory Management */ 55 /* Using Memory Pool Management*/ 56 #define RT_USING_MEMPOOL 57 58 /* Using Dynamic Heap Management */ 59 #define RT_USING_HEAP 60 61 /* Using Small MM */ 62 #define RT_USING_SMALL_MEM 63 64 /* SECTION: Device System */ 65 /* Using Device System */ 66 #define RT_USING_DEVICE 67 #define RT_USING_UART1 68 69 /* SECTION: Console options */ 70 #define RT_USING_CONSOLE 71 /* the buffer size of console*/ 72 #define RT_CONSOLEBUF_SIZE 128 73 74 /* SECTION: finsh, a C-Express shell */ 75 #define RT_USING_FINSH 76 /* Using symbol table */ 77 #define FINSH_USING_SYMTAB 78 #define FINSH_USING_DESCRIPTION 79 80 /* SECTION: device filesystem */ 81 //#define RT_USING_DFS 82 #define RT_USING_DFS_ELMFAT 83 84 /* the max number of mounted filesystem */ 85 #define DFS_FILESYSTEMS_MAX 2 86 /* the max number of opened files */ 87 #define DFS_FD_MAX 4 88 /* the max number of cached sector */ 89 #define DFS_CACHE_MAX_NUM 4 90 91 /* SECTION: lwip, a lighwight TCP/IP protocol stack */ 92 //#define RT_USING_LWIP 93 /* Enable ICMP protocol*/ 94 #define RT_LWIP_ICMP 95 /* Enable UDP protocol*/ 96 #define RT_LWIP_UDP 97 /* Enable TCP protocol*/ 98 #define RT_LWIP_TCP 99 /* Enable DNS */ 100 #define RT_LWIP_DNS 101 102 /* the number of simulatenously active TCP connections*/ 103 #define RT_LWIP_TCP_PCB_NUM 5 104 105 /* Using DHCP */ 106 //#define RT_LWIP_DHCP 107 108 /* ip address of target*/ 109 #define RT_LWIP_IPADDR0 192 110 #define RT_LWIP_IPADDR1 168 111 #define RT_LWIP_IPADDR2 1 112 #define RT_LWIP_IPADDR3 30 113 114 /* gateway address of target*/ 115 #define RT_LWIP_GWADDR0 192 116 #define RT_LWIP_GWADDR1 168 117 #define RT_LWIP_GWADDR2 1 118 #define RT_LWIP_GWADDR3 1 119 120 /* mask address of target*/ 121 #define RT_LWIP_MSKADDR0 255 122 #define RT_LWIP_MSKADDR1 255 123 #define RT_LWIP_MSKADDR2 255 124 #define RT_LWIP_MSKADDR3 0 125 126 /* tcp thread options */ 127 #define RT_LWIP_TCPTHREAD_PRIORITY 12 128 #define RT_LWIP_TCPTHREAD_MBOX_SIZE 4 129 #define RT_LWIP_TCPTHREAD_STACKSIZE 1024 130 131 /* ethernet if thread options */ 132 #define RT_LWIP_ETHTHREAD_PRIORITY 15 133 #define RT_LWIP_ETHTHREAD_MBOX_SIZE 4 134 #define RT_LWIP_ETHTHREAD_STACKSIZE 512 135 136 #endif 137