rtconfig.h 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237
  1. #ifndef __RTTHREAD_CFG_H__
  2. #define __RTTHREAD_CFG_H__
  3. // <RDTConfigurator URL="http://www.rt-thread.com/eclipse">
  4. // <integer name="RT_NAME_MAX" description="Maximal size of kernel object name length" default="6" />
  5. #define RT_NAME_MAX 10
  6. // <integer name="RT_ALIGN_SIZE" description="Alignment size for CPU architecture data access" default="4" />
  7. #define RT_ALIGN_SIZE 8
  8. // <integer name="RT_THREAD_PRIORITY_MAX" description="Maximal level of thread priority" default="32">
  9. // <item description="8">8</item>
  10. // <item description="32">32</item>
  11. // <item description="256">256</item>
  12. // </integer>
  13. #define RT_THREAD_PRIORITY_MAX 32
  14. // <integer name="RT_TICK_PER_SECOND" description="OS tick per second" default="100" />
  15. #define RT_TICK_PER_SECOND 1000
  16. // <section name="RT_DEBUG" description="Kernel Debug Configuration" default="true" >
  17. #define RT_DEBUG
  18. // <bool name="RT_THREAD_DEBUG" description="Thread debug enable" default="false" />
  19. // #define RT_THREAD_DEBUG
  20. // <bool name="RT_USING_OVERFLOW_CHECK" description="Thread stack over flow detect" default="true" />
  21. #define RT_USING_OVERFLOW_CHECK
  22. // <bool name="RT_USING_INTERRUPT_INFO" description="Show more interrupt description" default="true" />
  23. #define RT_USING_INTERRUPT_INFO
  24. // <integer name="IDLE_THREAD_STACK_SIZE" description="The stack size of idle thread" default="1024" />
  25. #define IDLE_THREAD_STACK_SIZE 1024
  26. // </section>
  27. // <bool name="RT_USING_HOOK" description="Using hook functions" default="true" />
  28. #define RT_USING_HOOK
  29. // <section name="RT_USING_TIMER_SOFT" description="Using software timer which will start a thread to handle soft-timer" default="true" >
  30. // #define RT_USING_TIMER_SOFT
  31. // <integer name="RT_TIMER_THREAD_PRIO" description="The priority level of timer thread" default="4" />
  32. #define RT_TIMER_THREAD_PRIO 4
  33. // <integer name="RT_TIMER_THREAD_STACK_SIZE" description="The stack size of timer thread" default="512" />
  34. #define RT_TIMER_THREAD_STACK_SIZE 512
  35. // <integer name="RT_TIMER_TICK_PER_SECOND" description="The soft-timer tick per second" default="10" />
  36. #define RT_TIMER_TICK_PER_SECOND 10
  37. // </section>
  38. // <section name="IPC" description="Inter-Thread communication" default="always" >
  39. // <bool name="RT_USING_SEMAPHORE" description="Using semaphore in the system" default="true" />
  40. #define RT_USING_SEMAPHORE
  41. // <bool name="RT_USING_MUTEX" description="Using mutex in the system" default="true" />
  42. #define RT_USING_MUTEX
  43. // <bool name="RT_USING_EVENT" description="Using event group in the system" default="true" />
  44. #define RT_USING_EVENT
  45. // <bool name="RT_USING_MAILBOX" description="Using mailbox in the system" default="true" />
  46. #define RT_USING_MAILBOX
  47. // <bool name="RT_USING_MESSAGEQUEUE" description="Using message queue in the system" default="true" />
  48. #define RT_USING_MESSAGEQUEUE
  49. // </section>
  50. // <section name="MM" description="Memory Management" default="always" >
  51. // <bool name="RT_USING_MEMPOOL" description="Using Memory Pool Management in the system" default="true" />
  52. #define RT_USING_MEMPOOL
  53. // <bool name="RT_USING_MEMHEAP" description="Using Memory Heap Object in the system" default="true" />
  54. #define RT_USING_MEMHEAP
  55. // <bool name="RT_USING_HEAP" description="Using Dynamic Heap Management in the system" default="true" />
  56. #define RT_USING_HEAP
  57. // <bool name="RT_USING_SMALL_MEM" description="Optimizing for small memory" default="false" />
  58. #define RT_USING_SMALL_MEM
  59. // <bool name="RT_USING_SLAB" description="Using SLAB memory management for large memory" default="false" />
  60. // #define RT_USING_SLAB
  61. // </section>
  62. // <section name="RT_USING_DEVICE" description="Using Device Driver Framework" default="true" >
  63. #define RT_USING_DEVICE
  64. // <bool name="RT_USING_UART" description="Using UART" default="true" />
  65. #define RT_USING_UART
  66. // <bool name="RT_USING_UART2" description="Using UART0" default="true" />
  67. #define RT_USING_UART2
  68. // <integer name="RT_UART_RX_BUFFER_SIZE" description="The buffer size for UART reception" default="64" />
  69. #define RT_UART_RX_BUFFER_SIZE 64
  70. // </section>
  71. #define RT_USING_FPU
  72. // <section name="RT_USING_CONSOLE" description="Using console" default="true" >
  73. #define RT_USING_CONSOLE
  74. // <integer name="RT_CONSOLEBUF_SIZE" description="The buffer size for console output" default="128" />
  75. #define RT_CONSOLEBUF_SIZE 128
  76. // <string name="RT_CONSOLE_DEVICE_NAME" description="The device name for console" default="uart" />
  77. #define RT_CONSOLE_DEVICE_NAME "uart2"
  78. // </section>
  79. // <bool name="RT_USING_COMPONENTS_INIT" description="Using RT-Thread components initialization" default="true" />
  80. #define RT_USING_COMPONENTS_INIT
  81. // <section name="RT_USING_FINSH" description="Using finsh as shell, which is a C-Express shell" default="true" >
  82. #define RT_USING_FINSH
  83. // <bool name="FINSH_USING_SYMTAB" description="Using symbol table in finsh shell" default="true" />
  84. #define FINSH_USING_SYMTAB
  85. // <bool name="FINSH_USING_DESCRIPTION" description="Keeping description in symbol table" default="true" />
  86. #define FINSH_USING_DESCRIPTION
  87. // <integer name="FINSH_THREAD_STACK_SIZE" description="The stack size for finsh thread" default="4096" />
  88. #define FINSH_THREAD_STACK_SIZE 4096
  89. // <bool name="FINSH_USING_MSH" description="Using module shell" default="true" />
  90. #define FINSH_USING_MSH
  91. // <bool name="FINSH_USING_MSH_DEFAULT" description="Using module shell as the default shell" default="true" />
  92. #define FINSH_USING_MSH_DEFAULT
  93. // </section>
  94. // <section name="LIBC" description="C Runtime library setting" default="always" >
  95. #define RT_USING_LIBC
  96. // <bool name="RT_USING_PTHREADS" description="Using POSIX threads library" default="true" />
  97. #define RT_USING_PTHREADS
  98. // </section>
  99. // <section name="RT_USING_DFS" description="Device file system" default="true" >
  100. // #define RT_USING_DFS
  101. // <bool name="DFS_USING_WORKDIR" description="Using working directory" default="true" />
  102. // #define DFS_USING_WORKDIR
  103. // <integer name="DFS_FILESYSTEMS_MAX" description="The maximal number of mounted file system" default="4" />
  104. #define DFS_FILESYSTEMS_MAX 2
  105. // <integer name="DFS_FD_MAX" description="The maximal number of opened files" default="4" />
  106. #define DFS_FD_MAX 4
  107. // <bool name="RT_USING_DFS_ELMFAT" description="Using ELM FatFs" default="true" />
  108. #define RT_USING_DFS_ELMFAT
  109. // <integer name="RT_DFS_ELM_USE_LFN" description="Support long file name" default="0">
  110. // <item description="LFN1">1</item>
  111. // <item description="LFN1">2</item>
  112. // </integer>
  113. #define RT_DFS_ELM_USE_LFN 1
  114. // <integer name="RT_DFS_ELM_MAX_LFN" description="Maximal size of file name length" default="255" />
  115. #define RT_DFS_ELM_MAX_LFN 64
  116. // <bool name="RT_USING_DFS_YAFFS2" description="Using YAFFS2" default="false" />
  117. // #define RT_USING_DFS_YAFFS2
  118. // <bool name="RT_USING_DFS_UFFS" description="Using UFFS" default="false" />
  119. // #define RT_USING_DFS_UFFS
  120. // <bool name="RT_USING_DFS_DEVFS" description="Using devfs for device objects" default="true" />
  121. // #define RT_USING_DFS_DEVFS
  122. // <bool name="RT_USING_DFS_NFS" description="Using NFS v3 client file system" default="false" />
  123. // #define RT_USING_DFS_NFS
  124. // <string name="RT_NFS_HOST_EXPORT" description="NFSv3 host export" default="192.168.1.5:/" />
  125. #define RT_NFS_HOST_EXPORT "192.168.1.254:/"
  126. // </section>
  127. // <section name="RT_USING_LWIP" description="lwip, a lightweight TCP/IP protocol stack" default="true" >
  128. #define RT_USING_LWIP
  129. #define RT_USING_GMAC_INT_MODE
  130. #define RT_USING_LWIP141
  131. //#define RT_LWIP_DEBUG
  132. // <bool name="RT_LWIP_ICMP" description="Enable ICMP protocol" default="true" />
  133. #define RT_LWIP_ICMP
  134. // <bool name="RT_LWIP_IGMP" description="Enable IGMP protocol" default="false" />
  135. #define RT_LWIP_IGMP
  136. // <bool name="RT_LWIP_UDP" description="Enable UDP protocol" default="true" />
  137. #define RT_LWIP_UDP
  138. // <bool name="RT_LWIP_TCP" description="Enable TCP protocol" default="true" />
  139. #define RT_LWIP_TCP
  140. // <bool name="RT_LWIP_DNS" description="Enable DNS protocol" default="true" />
  141. #define RT_LWIP_DNS
  142. // <integer name="RT_LWIP_PBUF_NUM" description="Maximal number of buffers in the pbuf pool" default="4" />
  143. #define RT_LWIP_PBUF_NUM 4
  144. #define RT_LWIP_PBUF_POOL_BUFSIZE 2048
  145. // <integer name="RT_LWIP_TCP_PCB_NUM" description="Maximal number of simultaneously active TCP connections" default="5" />
  146. #define RT_LWIP_TCP_PCB_NUM 3
  147. // <integer name="RT_LWIP_TCP_SND_BUF" description="TCP sender buffer size" default="8192" />
  148. #define RT_LWIP_TCP_SND_BUF 4096
  149. // <integer name="RT_LWIP_TCP_WND" description="TCP receive window" default="8192" />
  150. #define RT_LWIP_TCP_WND 2048
  151. // <bool name="RT_LWIP_SNMP" description="Enable SNMP protocol" default="false" />
  152. // #define RT_LWIP_SNMP
  153. // <bool name="RT_LWIP_DHCP" description="Enable DHCP client to get IP address" default="false" />
  154. // #define RT_LWIP_DHCP
  155. // <integer name="RT_LWIP_TCP_SEG_NUM" description="the number of simultaneously queued TCP" default="4" />
  156. #define RT_LWIP_TCP_SEG_NUM 40
  157. // <integer name="RT_LWIP_TCPTHREAD_PRIORITY" description="the thread priority of TCP thread" default="128" />
  158. #define RT_LWIP_TCPTHREAD_PRIORITY 12
  159. // <integer name="RT_LWIP_TCPTHREAD_MBOX_SIZE" description="the mail box size of TCP thread to wait for" default="32" />
  160. #define RT_LWIP_TCPTHREAD_MBOX_SIZE 8
  161. // <integer name="RT_LWIP_TCPTHREAD_STACKSIZE" description="the thread stack size of TCP thread" default="4096" />
  162. #define RT_LWIP_TCPTHREAD_STACKSIZE 4096
  163. // <integer name="RT_LWIP_ETHTHREAD_PRIORITY" description="the thread priority of ethnetif thread" default="144" />
  164. #define RT_LWIP_ETHTHREAD_PRIORITY 14
  165. // <integer name="RT_LWIP_ETHTHREAD_MBOX_SIZE" description="the mail box size of ethnetif thread to wait for" default="8" />
  166. #define RT_LWIP_ETHTHREAD_MBOX_SIZE 8
  167. // <integer name="RT_LWIP_ETHTHREAD_STACKSIZE" description="the stack size of ethnetif thread" default="512" />
  168. #define RT_LWIP_ETHTHREAD_STACKSIZE 512
  169. // <ipaddr name="RT_LWIP_IPADDR" description="IP address of device" default="192.168.1.30" />
  170. #define RT_LWIP_IPADDR0 192
  171. #define RT_LWIP_IPADDR1 168
  172. #define RT_LWIP_IPADDR2 1
  173. #define RT_LWIP_IPADDR3 254
  174. // <ipaddr name="RT_LWIP_GWADDR" description="Gateway address of device" default="192.168.1.1" />
  175. #define RT_LWIP_GWADDR0 192
  176. #define RT_LWIP_GWADDR1 168
  177. #define RT_LWIP_GWADDR2 1
  178. #define RT_LWIP_GWADDR3 3
  179. // <ipaddr name="RT_LWIP_MSKADDR" description="Mask address of device" default="255.255.255.0" />
  180. #define RT_LWIP_MSKADDR0 255
  181. #define RT_LWIP_MSKADDR1 255
  182. #define RT_LWIP_MSKADDR2 255
  183. #define RT_LWIP_MSKADDR3 0
  184. // </section>
  185. // <section name="RT_USING_MODULE" description="Application module" default="true" >
  186. // #define RT_USING_MODULE
  187. // <bool name="RT_USING_LIBDL" description="Using dynamic library" default="true" />
  188. // #define RT_USING_LIBDL
  189. // </section>
  190. // <section name="RT_USING_RTGUI" description="RTGUI, a graphic user interface" default="true" >
  191. // #define RT_USING_RTGUI
  192. // <integer name="RTGUI_NAME_MAX" description="Maximal size of RTGUI object name length" default="16" />
  193. #define RTGUI_NAME_MAX 16
  194. // <bool name="RTGUI_USING_FONT16" description="Support 16 weight font" default="true" />
  195. #define RTGUI_USING_FONT16
  196. // <bool name="RTGUI_USING_FONT12" description="Support 12 weight font" default="true" />
  197. #define RTGUI_USING_FONT12
  198. // <bool name="RTGUI_USING_FONTHZ" description="Support Chinese font" default="true" />
  199. #define RTGUI_USING_FONTHZ
  200. // <bool name="RTGUI_USING_DFS_FILERW" description="Using DFS as file interface " default="true" />
  201. #define RTGUI_USING_DFS_FILERW
  202. // <bool name="RTGUI_USING_HZ_FILE" description="Using font file as Chinese font" default="false" />
  203. // #define RTGUI_USING_HZ_FILE
  204. // <bool name="RTGUI_USING_HZ_BMP" description="Using Chinese bitmap font" default="true" />
  205. #define RTGUI_USING_HZ_BMP
  206. // <bool name="RTGUI_USING_SMALL_SIZE" description="Using small size in RTGUI" default="false" />
  207. #define RTGUI_USING_SMALL_SIZE
  208. // <bool name="RTGUI_USING_MOUSE_CURSOR" description="Using mouse cursor in RTGUI" default="false" />
  209. // #define RTGUI_USING_MOUSE_CURSOR
  210. // <bool name="RTGUI_IMAGE_XPM" description="Using xpm image in RTGUI" default="true" />
  211. #define RTGUI_IMAGE_XPM
  212. // <bool name="RTGUI_IMAGE_JPEG" description="Using jpeg image in RTGUI" default="true" />
  213. // #define RTGUI_IMAGE_JPEG
  214. // <bool name="RTGUI_IMAGE_PNG" description="Using png image in RTGUI" default="true" />
  215. // #define RTGUI_IMAGE_PNG
  216. // <bool name="RTGUI_IMAGE_BMP" description="Using bmp image in RTGUI" default="true" />
  217. #define RTGUI_IMAGE_BMP
  218. // </section>
  219. // </RDTConfigurator>
  220. #endif