rtconfig.h 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242
  1. /* RT-Thread config file */
  2. #ifndef __RTTHREAD_CFG_H__
  3. #define __RTTHREAD_CFG_H__
  4. //add by mojingxian.defualt idle stack is too small.
  5. #define IDLE_THREAD_STACK_SIZE 512
  6. /* RT_NAME_MAX*/
  7. #define RT_NAME_MAX 32
  8. /* RT_ALIGN_SIZE*/
  9. #define RT_ALIGN_SIZE 8
  10. /* PRIORITY_MAX */
  11. #define RT_THREAD_PRIORITY_MAX 256
  12. /* Tick per Second */
  13. #define RT_TICK_PER_SECOND 1000
  14. /* SECTION: RT_DEBUG */
  15. /* Thread Debug */
  16. /* #define RT_DEBUG */
  17. /* #define RT_THREAD_DEBUG */
  18. #define RT_USING_OVERFLOW_CHECK
  19. /* Using Hook */
  20. #define RT_USING_HOOK
  21. /* Using Software Timer */
  22. //#define RT_USING_TIMER_SOFT
  23. #define RT_TIMER_THREAD_PRIO 8
  24. #define RT_TIMER_THREAD_STACK_SIZE 512
  25. #define RT_TICK_PER_SECOND 1000
  26. /* SECTION: IPC */
  27. /* Using Semaphore */
  28. #define RT_USING_SEMAPHORE
  29. /* Using Mutex */
  30. #define RT_USING_MUTEX
  31. /* Using Event */
  32. #define RT_USING_EVENT
  33. /* Using MailBox */
  34. #define RT_USING_MAILBOX
  35. /* Using Message Queue */
  36. #define RT_USING_MESSAGEQUEUE
  37. /* SECTION: Memory Management */
  38. /* Using Memory Pool Management*/
  39. #define RT_USING_MEMPOOL
  40. /* Using Dynamic Heap Management */
  41. #define RT_USING_HEAP
  42. /* Using Small MM */
  43. #define RT_USING_SMALL_MEM
  44. /* Using SLAB Allocator */
  45. //#define RT_USING_SLAB
  46. /* SECTION: Device System */
  47. /* Using Device System */
  48. #define RT_USING_DEVICE
  49. /* Using Module System */
  50. //#define RT_USING_MODULE
  51. /* SECTION: Console options */
  52. #define RT_USING_CONSOLE
  53. /* the buffer size of console */
  54. #define RT_CONSOLEBUF_SIZE 128
  55. /* SECTION: finsh, a C-Express shell */
  56. /* Using FinSH as Shell*/
  57. #define RT_USING_FINSH
  58. /* Using symbol table */
  59. #define FINSH_USING_SYMTAB
  60. #define FINSH_USING_DESCRIPTION
  61. #define FINSH_THREAD_STACK_SIZE 1024
  62. /* SECTION: a runtime libc library */
  63. /* a runtime libc library */
  64. //#define RT_USING_NEWLIBC
  65. //#define RT_USING_PTHREADS
  66. /* SECTION: C++ support */
  67. /* Using C++ support */
  68. /* #define RT_USING_CPLUSPLUS */
  69. /* SECTION: Device filesystem support */
  70. /* using DFS support */
  71. //#define RT_USING_DFS
  72. #define RT_USING_DFS_ELMFAT
  73. /* use long file name feature */
  74. #define RT_DFS_ELM_USE_LFN 1
  75. /* the max number of file length */
  76. #define RT_DFS_ELM_MAX_LFN 128
  77. /* #define RT_USING_DFS_YAFFS2 */
  78. /* #define RT_USING_DFS_UFFS */
  79. #define RT_USING_DFS_DEVFS
  80. /* #define RT_USING_DFS_NFS */
  81. #define RT_NFS_HOST_EXPORT "192.168.1.5:/"
  82. #define DFS_USING_WORKDIR
  83. /* the max number of mounted filesystem */
  84. #define DFS_FILESYSTEMS_MAX 4
  85. /* the max number of opened files */
  86. #define DFS_FD_MAX 16
  87. /* the max number of cached sector */
  88. #define DFS_CACHE_MAX_NUM 4
  89. /* Enable freemodbus protocal stack*/
  90. /* #define RT_USING_MODBUS */
  91. /* SECTION: lwip, a lighwight TCP/IP protocol stack */
  92. /* Using lighweight TCP/IP protocol stack */
  93. /* #define RT_USING_LWIP */
  94. //#define RT_LWIP_DNS
  95. /* Trace LwIP protocol */
  96. /* #define RT_LWIP_DEBUG */
  97. /* Enable ICMP protocol */
  98. #define RT_LWIP_ICMP
  99. /* Enable IGMP protocol */
  100. #define RT_LWIP_IGMP
  101. /* Enable UDP protocol */
  102. #define RT_LWIP_UDP
  103. /* Enable TCP protocol */
  104. #define RT_LWIP_TCP
  105. /* the number of simulatenously active TCP connections*/
  106. #define RT_LWIP_TCP_PCB_NUM 5
  107. /* TCP sender buffer space */
  108. #define RT_LWIP_TCP_SND_BUF 1024*8
  109. /* TCP receive window. */
  110. #define RT_LWIP_TCP_WND 1024*8
  111. /* Enable SNMP protocol */
  112. /* #define RT_LWIP_SNMP */
  113. /* Using DHCP */
  114. /* #define RT_LWIP_DHCP */
  115. /* ip address of target */
  116. #define RT_LWIP_IPADDR0 192
  117. #define RT_LWIP_IPADDR1 168
  118. #define RT_LWIP_IPADDR2 1
  119. #define RT_LWIP_IPADDR3 30
  120. /* gateway address of target */
  121. #define RT_LWIP_GWADDR0 192
  122. #define RT_LWIP_GWADDR1 168
  123. #define RT_LWIP_GWADDR2 1
  124. #define RT_LWIP_GWADDR3 1
  125. /* mask address of target */
  126. #define RT_LWIP_MSKADDR0 255
  127. #define RT_LWIP_MSKADDR1 255
  128. #define RT_LWIP_MSKADDR2 255
  129. #define RT_LWIP_MSKADDR3 0
  130. /* the number of blocks for pbuf */
  131. #define RT_LWIP_PBUF_NUM 16
  132. /* the number of simultaneously queued TCP */
  133. #define RT_LWIP_TCP_SEG_NUM 40
  134. /* thread priority of tcpip thread */
  135. #define RT_LWIP_TCPTHREAD_PRIORITY 128
  136. /* mail box size of tcpip thread to wait for */
  137. #define RT_LWIP_TCPTHREAD_MBOX_SIZE 32
  138. /* thread stack size of tcpip thread */
  139. #define RT_LWIP_TCPTHREAD_STACKSIZE 4096
  140. /* thread priority of ethnetif thread */
  141. #define RT_LWIP_ETHTHREAD_PRIORITY 144
  142. /* mail box size of ethnetif thread to wait for */
  143. #define RT_LWIP_ETHTHREAD_MBOX_SIZE 32
  144. /* thread stack size of ethnetif thread */
  145. #define RT_LWIP_ETHTHREAD_STACKSIZE 1024
  146. /* SECTION: RTGUI support */
  147. /* using RTGUI support */
  148. #define RT_USING_RTGUI
  149. /* name length of RTGUI object */
  150. #define RTGUI_NAME_MAX 16
  151. /* support 16 weight font */
  152. #define RTGUI_USING_FONT16
  153. /* support 16 weight font */
  154. #define RTGUI_USING_FONT12
  155. /* support Chinese font */
  156. #define RTGUI_USING_FONTHZ
  157. /* use DFS as file interface */
  158. #define RTGUI_USING_DFS_FILERW
  159. /* use font file as Chinese font */
  160. /* #define RTGUI_USING_HZ_FILE */
  161. /* use Chinese bitmap font */
  162. #define RTGUI_USING_HZ_BMP
  163. /* use small size in RTGUI */
  164. /* #define RTGUI_USING_SMALL_SIZE */
  165. /* use mouse cursor */
  166. /* #define RTGUI_USING_MOUSE_CURSOR */
  167. /* RTGUI image options */
  168. //#define RTGUI_IMAGE_XPM
  169. //#define RTGUI_IMAGE_JPEG
  170. //#define RTGUI_IMAGE_PNG
  171. //#define RTGUI_IMAGE_BMP
  172. /* SECTION: FTK support */
  173. /* using FTK support */
  174. /* #define RT_USING_FTK */
  175. /*
  176. * Note on FTK:
  177. *
  178. * FTK depends :
  179. * #define RT_USING_NEWLIBC
  180. * #define DFS_USING_WORKDIR
  181. *
  182. * And the maximal length must great than 64
  183. * #define RT_DFS_ELM_MAX_LFN 128
  184. */
  185. #endif