rtconfig.h 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. /* RT-Thread config file */
  2. #ifndef __RTTHREAD_CFG_H__
  3. #define __RTTHREAD_CFG_H__
  4. #if defined(__CC_ARM) || defined(__CLANG_ARM)
  5. #include "RTE_Components.h"
  6. #if defined(RTE_USING_FINSH)
  7. #define RT_USING_FINSH
  8. #endif //RTE_USING_FINSH
  9. #endif //(__CC_ARM) || (__CLANG_ARM)
  10. // <<< Use Configuration Wizard in Context Menu >>>
  11. // <h>Basic Configuration
  12. // <o>Maximal level of thread priority <8-256>
  13. // <i>Default: 32
  14. #define RT_THREAD_PRIORITY_MAX 16
  15. // <o>OS tick per second
  16. // <i>Default: 1000 (1ms)
  17. #define RT_TICK_PER_SECOND 1000
  18. // <o>Alignment size for CPU architecture data access
  19. // <i>Default: 4
  20. #define RT_ALIGN_SIZE 4
  21. // <o>the max length of object name<2-16>
  22. // <i>Default: 8
  23. #define RT_NAME_MAX 16
  24. // <c1>Using RT-Thread components initialization
  25. // <i>Using RT-Thread components initialization
  26. #define RT_USING_COMPONENTS_INIT
  27. // </c>
  28. #define RT_USING_USER_MAIN
  29. // <o>the stack size of main thread<1-4086>
  30. // <i>Default: 512
  31. #define RT_MAIN_THREAD_STACK_SIZE 2046
  32. // </h>
  33. // <h>Debug Configuration
  34. // <c1>enable kernel debug configuration
  35. // <i>Default: enable kernel debug configuration
  36. //#define RT_DEBUG
  37. // </c>
  38. // <o>enable components initialization debug configuration<0-1>
  39. // <i>Default: 0
  40. #define RT_DEBUG_INIT 0
  41. // <c1>thread stack over flow detect
  42. // <i> Diable Thread stack over flow detect
  43. //#define RT_USING_OVERFLOW_CHECK
  44. // </c>
  45. // </h>
  46. // <h>Hook Configuration
  47. // <c1>using hook
  48. // <i>using hook
  49. //#define RT_USING_HOOK
  50. // </c>
  51. // <c1>using idle hook
  52. // <i>using idle hook
  53. #define RT_USING_IDLE_HOOK
  54. // </c>
  55. // </h>
  56. // <e>Software timers Configuration
  57. // <i> Enables user timers
  58. #define RT_USING_TIMER_SOFT 0
  59. #if RT_USING_TIMER_SOFT == 0
  60. #undef RT_USING_TIMER_SOFT
  61. #endif
  62. // <o>The priority level of timer thread <0-31>
  63. // <i>Default: 4
  64. #define RT_TIMER_THREAD_PRIO 4
  65. // <o>The stack size of timer thread <0-8192>
  66. // <i>Default: 512
  67. #define RT_TIMER_THREAD_STACK_SIZE 512
  68. // </e>
  69. // <h>IPC(Inter-process communication) Configuration
  70. // <c1>Using Semaphore
  71. // <i>Using Semaphore
  72. #define RT_USING_SEMAPHORE
  73. // </c>
  74. // <c1>Using Mutex
  75. // <i>Using Mutex
  76. //#define RT_USING_MUTEX
  77. // </c>
  78. // <c1>Using Event
  79. // <i>Using Event
  80. #define RT_USING_EVENT
  81. // </c>
  82. // <c1>Using MailBox
  83. // <i>Using MailBox
  84. //#define RT_USING_MAILBOX
  85. // </c>
  86. // <c1>Using Message Queue
  87. // <i>Using Message Queue
  88. //#define RT_USING_MESSAGEQUEUE
  89. // </c>
  90. // </h>
  91. // <h>Memory Management Configuration
  92. // <c1>Dynamic Heap Management
  93. // <i>Dynamic Heap Management
  94. #define RT_USING_HEAP
  95. // </c>
  96. // <c1>using small memory
  97. // <i>using small memory
  98. #define RT_USING_SMALL_MEM
  99. // </c>
  100. // <c1>using tiny size of memory
  101. // <i>using tiny size of memory
  102. //#define RT_USING_TINY_SIZE
  103. // </c>
  104. // </h>
  105. // <h>Console Configuration
  106. // <c1>Using console
  107. // <i>Using console
  108. // #define RT_USING_CONSOLE
  109. // </c>
  110. // <o>the buffer size of console <1-1024>
  111. // <i>the buffer size of console
  112. // <i>Default: 128 (128Byte)
  113. #define RT_CONSOLEBUF_SIZE 128
  114. // </h>
  115. #if defined(RT_USING_FINSH)
  116. #define FINSH_USING_MSH
  117. #define FINSH_USING_MSH_ONLY
  118. // <h>Finsh Configuration
  119. // <o>the priority of finsh thread <1-7>
  120. // <i>the priority of finsh thread
  121. // <i>Default: 6
  122. #define __FINSH_THREAD_PRIORITY 5
  123. #define FINSH_THREAD_PRIORITY (RT_THREAD_PRIORITY_MAX / 8 * __FINSH_THREAD_PRIORITY + 1)
  124. // <o>the stack of finsh thread <1-4096>
  125. // <i>the stack of finsh thread
  126. // <i>Default: 4096 (4096Byte)
  127. #define FINSH_THREAD_STACK_SIZE 768
  128. // <o>the history lines of finsh thread <1-32>
  129. // <i>the history lines of finsh thread
  130. // <i>Default: 5
  131. #define FINSH_HISTORY_LINES 1
  132. #define FINSH_USING_SYMTAB
  133. // </h>
  134. #endif
  135. // <<< end of configuration section >>>
  136. #endif