rtconfig.h 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. /* RT-Thread config file */
  2. #ifndef __RTTHREAD_CFG_H__
  3. #define __RTTHREAD_CFG_H__
  4. /* RT_NAME_MAX*/
  5. #define RT_NAME_MAX 8
  6. /* RT_ALIGN_SIZE*/
  7. #define RT_ALIGN_SIZE 4
  8. /* PRIORITY_MAX */
  9. #define RT_THREAD_PRIORITY_MAX 32
  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. /* SECTION: IPC */
  19. /* Using Semaphore*/
  20. #define RT_USING_SEMAPHORE
  21. /* Using Mutex */
  22. #define RT_USING_MUTEX
  23. /* Using Event */
  24. #define RT_USING_EVENT
  25. /* Using MailBox */
  26. #define RT_USING_MAILBOX
  27. /* Using Message Queue */
  28. #define RT_USING_MESSAGEQUEUE
  29. /* SECTION: Memory Management */
  30. /* Using Memory Pool Management*/
  31. #define RT_USING_MEMPOOL
  32. /* Using Dynamic Heap Management */
  33. #define RT_USING_HEAP
  34. /* Using Small MM */
  35. #define RT_USING_SMALL_MEM
  36. #define RT_USING_COMPONENTS_INIT
  37. /* SECTION: Device System */
  38. /* Using Device System */
  39. #define RT_USING_DEVICE
  40. #define RT_USING_DEVICE_IPC
  41. #define RT_USING_SERIAL
  42. /* SECTION: Console options */
  43. #define RT_USING_CONSOLE
  44. /* the buffer size of console*/
  45. #define RT_CONSOLEBUF_SIZE 128
  46. #define RT_CONSOLE_DEVICE_NAME "uart2"
  47. /* SECTION: finsh, a C-Express shell */
  48. #define RT_USING_FINSH
  49. /* Using symbol table */
  50. #define FINSH_USING_SYMTAB
  51. #define FINSH_USING_DESCRIPTION
  52. #define FINSH_USING_MSH
  53. //#define FINSH_USING_MSH_ONLY
  54. #define RT_USING_LIBC
  55. /* SECTION: device filesystem */
  56. /* #define RT_USING_DFS */
  57. #define RT_USING_DFS_ELMFAT
  58. #define RT_DFS_ELM_REENTRANT
  59. #define RT_DFS_ELM_WORD_ACCESS
  60. #define RT_DFS_ELM_DRIVES 1
  61. #define RT_DFS_ELM_USE_LFN 2
  62. #define RT_DFS_ELM_MAX_LFN 255
  63. #define RT_DFS_ELM_MAX_SECTOR_SIZE 512
  64. /* the max number of mounted filesystem */
  65. #define DFS_FILESYSTEMS_MAX 2
  66. /* the max number of opened files */
  67. #define DFS_FD_MAX 4
  68. /* SECTION: lwip, a lighwight TCP/IP protocol stack */
  69. #define RT_USING_LWIP
  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. /* Enable DHCP */
  79. // #define RT_LWIP_DHCP
  80. /* the number of simulatenously active TCP connections*/
  81. #define RT_LWIP_TCP_PCB_NUM 3
  82. /* ip address of target */
  83. #define RT_LWIP_IPADDR "192.168.1.30"
  84. /* gateway address of target */
  85. #define RT_LWIP_GWADDR "192.168.1.1"
  86. /* mask address of target */
  87. #define RT_LWIP_MSKADDR "255.255.255.0"
  88. /* tcp thread options */
  89. #define RT_LWIP_TCPTHREAD_PRIORITY 12
  90. #define RT_LWIP_TCPTHREAD_MBOX_SIZE 4
  91. #define RT_LWIP_TCPTHREAD_STACKSIZE 1024
  92. #define RT_LWIP_ETHTHREAD_PRIORITY 15
  93. #define RT_LWIP_ETHTHREAD_MBOX_SIZE 4
  94. #define RT_LWIP_ETHTHREAD_STACKSIZE 512
  95. // <bool name="RT_USING_CMSIS_OS" description="Using CMSIS OS API" default="true" />
  96. // #define RT_USING_CMSIS_OS
  97. // <bool name="RT_USING_RTT_CMSIS" description="Using CMSIS in RTT" default="true" />
  98. #define RT_USING_RTT_CMSIS
  99. #endif