rtconfig.h 3.6 KB

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