rtconfig.h 3.9 KB

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