rtconfig.h 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147
  1. /* RT-Thread config file */
  2. #ifndef __RTTHREAD_CFG_H__
  3. #define __RTTHREAD_CFG_H__
  4. // <RDTConfigurator URL="http://www.rt-thread.com/eclipse">
  5. // <integer name="RT_NAME_MAX" description="Maximal size of kernel object name length" default="6" />
  6. #define RT_NAME_MAX 6
  7. // <integer name="RT_ALIGN_SIZE" description="Alignment size for CPU architecture data access" default="4" />
  8. #define RT_ALIGN_SIZE 4
  9. // <integer name="RT_THREAD_PRIORITY_MAX" description="Maximal level of thread priority" default="32">
  10. // <item description="8">8</item>
  11. // <item description="32">32</item>
  12. // <item description="256">256</item>
  13. // </integer>
  14. #define RT_THREAD_PRIORITY_MAX 32
  15. // <integer name="RT_TICK_PER_SECOND" description="OS tick per second" default="1000" />
  16. #define RT_TICK_PER_SECOND 1000
  17. // <integer name="IDLE_THREAD_STACK_SIZE" description="The stack size of idle thread" default="512" />
  18. #define IDLE_THREAD_STACK_SIZE 512
  19. // <section name="RT_DEBUG" description="Kernel Debug Configuration" default="true" >
  20. #define RT_DEBUG
  21. //#define RT_DEBUG_SCHEDULER 1
  22. // <bool name="RT_THREAD_DEBUG" description="Thread debug enable" default="false" />
  23. // #define RT_THREAD_DEBUG
  24. // <bool name="RT_USING_OVERFLOW_CHECK" description="Thread stack over flow detect" default="true" />
  25. //#define RT_USING_OVERFLOW_CHECK
  26. // </section>
  27. // <bool name="RT_USING_HOOK" description="Using hook functions" default="true" />
  28. #define RT_USING_HOOK
  29. // <section name="RT_USING_TIMER_SOFT" description="Using software timer which will start a thread to handle soft-timer" default="true" >
  30. // #define RT_USING_TIMER_SOFT
  31. // <integer name="RT_TIMER_THREAD_PRIO" description="The priority level of timer thread" default="4" />
  32. #define RT_TIMER_THREAD_PRIO 4
  33. // <integer name="RT_TIMER_THREAD_STACK_SIZE" description="The stack size of timer thread" default="512" />
  34. #define RT_TIMER_THREAD_STACK_SIZE 512
  35. // <integer name="RT_TIMER_TICK_PER_SECOND" description="The soft-timer tick per second" default="10" />
  36. #define RT_TIMER_TICK_PER_SECOND 10
  37. // </section>
  38. // <section name="IPC" description="Inter-Thread communication" default="always" >
  39. // <bool name="RT_USING_SEMAPHORE" description="Using semaphore in the system" default="true" />
  40. #define RT_USING_SEMAPHORE
  41. // <bool name="RT_USING_MUTEX" description="Using mutex in the system" default="true" />
  42. #define RT_USING_MUTEX
  43. // <bool name="RT_USING_EVENT" description="Using event group in the system" default="true" />
  44. #define RT_USING_EVENT
  45. // <bool name="RT_USING_MAILBOX" description="Using mailbox in the system" default="true" />
  46. #define RT_USING_MAILBOX
  47. // <bool name="RT_USING_MESSAGEQUEUE" description="Using message queue in the system" default="true" />
  48. #define RT_USING_MESSAGEQUEUE
  49. // </section>
  50. // <section name="MM" description="Memory Management" default="always" >
  51. // <bool name="RT_USING_MEMPOOL" description="Using Memory Pool Management in the system" default="true" />
  52. #define RT_USING_MEMPOOL
  53. // <bool name="RT_USING_MEMHEAP" description="Using Memory Heap Object in the system" default="true" />
  54. // #define RT_USING_MEMHEAP
  55. // <bool name="RT_USING_HEAP" description="Using Dynamic Heap Management in the system" default="true" />
  56. #define RT_USING_HEAP
  57. // <bool name="RT_USING_MEMHEAP_AS_HEAP" description="Using Memory Heap Object as system heap" default="true" />
  58. // #define RT_USING_MEMHEAP_AS_HEAP
  59. // <bool name="RT_USING_SMALL_MEM" description="Optimizing for small memory" default="false" />
  60. #define RT_USING_SMALL_MEM
  61. // <bool name="RT_USING_SLAB" description="Using SLAB memory management for large memory" default="false" />
  62. // #define RT_USING_SLAB
  63. // </section>
  64. // <section name="RT_USING_DEVICE" description="Using Device Driver Framework" default="true" >
  65. #define RT_USING_DEVICE
  66. // <bool name=RT_USING_DEVICE_IPC description="Using IPC in Device Driver Framework" default="true" />
  67. #define RT_USING_DEVICE_IPC
  68. // <bool name="RT_USING_SERIAL" description="Using Serial Device Driver Framework" default="true" />
  69. #define RT_USING_SERIAL
  70. // <integer name="RT_UART_RX_BUFFER_SIZE" description="The buffer size for UART reception" default="64" />
  71. #define RT_UART_RX_BUFFER_SIZE 64
  72. // <bool name=RT_USING_INTERRUPT_INFO description="Using interrupt information description" default="true" />
  73. #define RT_USING_INTERRUPT_INFO
  74. // </section>
  75. // <section name="RT_USING_CONSOLE" description="Using console" default="true" >
  76. #define RT_USING_CONSOLE
  77. // <integer name="RT_CONSOLEBUF_SIZE" description="The buffer size for console output" default="128" />
  78. #define RT_CONSOLEBUF_SIZE 128
  79. // <string name="RT_CONSOLE_DEVICE_NAME" description="The device name for console" default="uart" />
  80. #define RT_CONSOLE_DEVICE_NAME "uart1"
  81. // </section>
  82. // <bool name="RT_USING_COMPONENTS_INIT" description="Using RT-Thread components initialization" default="true" />
  83. #define RT_USING_COMPONENTS_INIT
  84. // <section name="RT_USING_FINSH" description="Using finsh as shell, which is a C-Express shell" default="true" >
  85. #define RT_USING_FINSH
  86. // <bool name="FINSH_USING_MSH" description="Using module shell" default="true" />
  87. #define FINSH_USING_MSH
  88. // <bool name="FINSH_USING_MSH_DEFAULT" description="The default shell is msh" default="true" />
  89. //#define FINSH_USING_MSH_DEFAULT
  90. // <bool name="FINSH_USING_SYMTAB" description="Using symbol table in finsh shell" default="true" />
  91. #define FINSH_USING_SYMTAB
  92. // <bool name="FINSH_USING_DESCRIPTION" description="Keeping description in symbol table" default="true" />
  93. #define FINSH_USING_DESCRIPTION
  94. // <integer name="FINSH_THREAD_STACK_SIZE" description="The stack size for finsh thread" default="4096" />
  95. #define FINSH_THREAD_STACK_SIZE 4096
  96. // </section>
  97. // <section name="LIBC" description="C Runtime library setting" default="always" >
  98. // <bool name="RT_USING_NEWLIB" description="Using newlib library, only available under GNU GCC" default="true" />
  99. //#define RT_USING_NEWLIB
  100. // <bool name="RT_USING_PTHREADS" description="Using POSIX threads library" default="true" />
  101. #define RT_USING_PTHREADS
  102. // </section>
  103. // <section name="RT_USING_DFS" description="Device file system" default="true" >
  104. // #define RT_USING_DFS
  105. // <bool name="DFS_USING_WORKDIR" description="Using working directory" default="true" />
  106. // #define DFS_USING_WORKDIR
  107. // <integer name="DFS_FILESYSTEMS_MAX" description="The maximal number of mounted file system" default="4" />
  108. #define DFS_FILESYSTEMS_MAX 2
  109. // <integer name="DFS_FD_MAX" description="The maximal number of opened files" default="4" />
  110. #define DFS_FD_MAX 4
  111. // <bool name="RT_USING_DFS_ELMFAT" description="Using ELM FatFs" default="true" />
  112. #define RT_USING_DFS_ELMFAT
  113. // <integer name="RT_DFS_ELM_USE_LFN" description="Support long file name" default="0">
  114. // <item description="LFN1">1</item>
  115. // <item description="LFN1">2</item>
  116. // </integer>
  117. #define RT_DFS_ELM_USE_LFN 1
  118. // <integer name="RT_DFS_ELM_MAX_LFN" description="Maximal size of file name length" default="256" />
  119. #define RT_DFS_ELM_MAX_LFN 64
  120. // <bool name="RT_USING_DFS_YAFFS2" description="Using YAFFS2" default="false" />
  121. // #define RT_USING_DFS_YAFFS2
  122. // <bool name="RT_USING_DFS_UFFS" description="Using UFFS" default="false" />
  123. // #define RT_USING_DFS_UFFS
  124. // <bool name="RT_USING_DFS_DEVFS" description="Using devfs for device objects" default="true" />
  125. // #define RT_USING_DFS_DEVFS
  126. // <bool name="RT_USING_DFS_NFS" description="Using NFS v3 client file system" default="false" />
  127. // #define RT_USING_DFS_NFS
  128. // <string name="RT_NFS_HOST_EXPORT" description="NFSv3 host export" default="192.168.1.5:/" />
  129. #define RT_NFS_HOST_EXPORT "192.168.1.5:/"
  130. // </section>
  131. // </RDTConfigurator>
  132. #define __rt_ffs __builtin_ffs
  133. #endif