rtconfig.h 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616
  1. #ifndef RT_CONFIG_H__
  2. #define RT_CONFIG_H__
  3. /* RT-Thread Kernel */
  4. /* klibc options */
  5. /* rt_vsnprintf options */
  6. /* end of rt_vsnprintf options */
  7. /* rt_vsscanf options */
  8. /* end of rt_vsscanf options */
  9. /* rt_memset options */
  10. /* end of rt_memset options */
  11. /* rt_memcpy options */
  12. /* end of rt_memcpy options */
  13. /* rt_memmove options */
  14. /* end of rt_memmove options */
  15. /* rt_memcmp options */
  16. /* end of rt_memcmp options */
  17. /* rt_strstr options */
  18. /* end of rt_strstr options */
  19. /* rt_strcasecmp options */
  20. /* end of rt_strcasecmp options */
  21. /* rt_strncpy options */
  22. /* end of rt_strncpy options */
  23. /* rt_strcpy options */
  24. /* end of rt_strcpy options */
  25. /* rt_strncmp options */
  26. /* end of rt_strncmp options */
  27. /* rt_strcmp options */
  28. /* end of rt_strcmp options */
  29. /* rt_strlen options */
  30. /* end of rt_strlen options */
  31. /* rt_strnlen options */
  32. /* end of rt_strnlen options */
  33. /* end of klibc options */
  34. #define RT_NAME_MAX 16
  35. #define RT_USING_SMP
  36. #define RT_CPUS_NR 4
  37. #define RT_ALIGN_SIZE 4
  38. #define RT_THREAD_PRIORITY_32
  39. #define RT_THREAD_PRIORITY_MAX 32
  40. #define RT_TICK_PER_SECOND 1000
  41. #define RT_USING_OVERFLOW_CHECK
  42. #define RT_USING_HOOK
  43. #define RT_HOOK_USING_FUNC_PTR
  44. #define RT_USING_IDLE_HOOK
  45. #define RT_IDLE_HOOK_LIST_SIZE 4
  46. #define IDLE_THREAD_STACK_SIZE 4096
  47. #define SYSTEM_THREAD_STACK_SIZE 4096
  48. #define RT_USING_TIMER_SOFT
  49. #define RT_TIMER_THREAD_PRIO 4
  50. #define RT_TIMER_THREAD_STACK_SIZE 4096
  51. /* kservice options */
  52. /* end of kservice options */
  53. #define RT_USING_DEBUG
  54. #define RT_DEBUGING_ASSERT
  55. #define RT_DEBUGING_COLOR
  56. #define RT_DEBUGING_CONTEXT
  57. /* Inter-Thread communication */
  58. #define RT_USING_SEMAPHORE
  59. #define RT_USING_MUTEX
  60. #define RT_USING_EVENT
  61. #define RT_USING_MAILBOX
  62. #define RT_USING_MESSAGEQUEUE
  63. #define RT_USING_MESSAGEQUEUE_PRIORITY
  64. /* end of Inter-Thread communication */
  65. /* Memory Management */
  66. #define RT_USING_MEMPOOL
  67. #define RT_USING_SLAB
  68. #define RT_USING_MEMHEAP
  69. #define RT_MEMHEAP_FAST_MODE
  70. #define RT_USING_SLAB_AS_HEAP
  71. #define RT_USING_HEAP_ISR
  72. #define RT_USING_HEAP
  73. /* end of Memory Management */
  74. #define RT_USING_DEVICE
  75. #define RT_USING_CONSOLE
  76. #define RT_CONSOLEBUF_SIZE 256
  77. #define RT_CONSOLE_DEVICE_NAME "uart1"
  78. #define RT_VER_NUM 0x50200
  79. #define RT_BACKTRACE_LEVEL_MAX_NR 32
  80. /* end of RT-Thread Kernel */
  81. #define RT_USING_CACHE
  82. #define RT_USING_HW_ATOMIC
  83. #define RT_USING_CPU_FFS
  84. #define ARCH_MM_MMU
  85. #define ARCH_ARM
  86. #define ARCH_ARM_MMU
  87. #define ARCH_ARM_CORTEX_A
  88. #define RT_USING_GIC_V3
  89. /* RT-Thread Components */
  90. #define RT_USING_COMPONENTS_INIT
  91. #define RT_USING_USER_MAIN
  92. #define RT_MAIN_THREAD_STACK_SIZE 8192
  93. #define RT_MAIN_THREAD_PRIORITY 10
  94. #define RT_USING_MSH
  95. #define RT_USING_FINSH
  96. #define FINSH_USING_MSH
  97. #define FINSH_THREAD_NAME "tshell"
  98. #define FINSH_THREAD_PRIORITY 20
  99. #define FINSH_THREAD_STACK_SIZE 4096
  100. #define FINSH_USING_HISTORY
  101. #define FINSH_HISTORY_LINES 5
  102. #define FINSH_USING_SYMTAB
  103. #define FINSH_CMD_SIZE 80
  104. #define MSH_USING_BUILT_IN_COMMANDS
  105. #define FINSH_USING_DESCRIPTION
  106. #define FINSH_ARG_MAX 10
  107. #define FINSH_USING_OPTION_COMPLETION
  108. /* DFS: device virtual file system */
  109. #define RT_USING_DFS
  110. #define DFS_USING_POSIX
  111. #define DFS_USING_WORKDIR
  112. #define DFS_FD_MAX 16
  113. #define RT_USING_DFS_V1
  114. #define DFS_FILESYSTEMS_MAX 4
  115. #define DFS_FILESYSTEM_TYPES_MAX 4
  116. #define RT_USING_DFS_ELMFAT
  117. /* elm-chan's FatFs, Generic FAT Filesystem Module */
  118. #define RT_DFS_ELM_CODE_PAGE 437
  119. #define RT_DFS_ELM_WORD_ACCESS
  120. #define RT_DFS_ELM_USE_LFN_3
  121. #define RT_DFS_ELM_USE_LFN 3
  122. #define RT_DFS_ELM_LFN_UNICODE_0
  123. #define RT_DFS_ELM_LFN_UNICODE 0
  124. #define RT_DFS_ELM_MAX_LFN 255
  125. #define RT_DFS_ELM_DRIVES 2
  126. #define RT_DFS_ELM_MAX_SECTOR_SIZE 512
  127. #define RT_DFS_ELM_REENTRANT
  128. #define RT_DFS_ELM_MUTEX_TIMEOUT 3000
  129. /* end of elm-chan's FatFs, Generic FAT Filesystem Module */
  130. #define RT_USING_DFS_DEVFS
  131. #define RT_USING_DFS_RAMFS
  132. #define RT_USING_DFS_MQUEUE
  133. /* end of DFS: device virtual file system */
  134. /* Device Drivers */
  135. #define RT_USING_DEV_BUS
  136. #define RT_USING_DEVICE_IPC
  137. #define RT_UNAMED_PIPE_NUMBER 64
  138. #define RT_USING_SYSTEM_WORKQUEUE
  139. #define RT_SYSTEM_WORKQUEUE_STACKSIZE 4096
  140. #define RT_SYSTEM_WORKQUEUE_PRIORITY 23
  141. #define RT_USING_SERIAL
  142. #define RT_USING_SERIAL_V1
  143. #define RT_SERIAL_USING_DMA
  144. #define RT_SERIAL_RB_BUFSZ 1024
  145. #define RT_USING_CAN
  146. #define RT_CAN_USING_CANFD
  147. #define RT_USING_I2C
  148. #define RT_USING_I2C_BITOPS
  149. #define RT_USING_NULL
  150. #define RT_USING_ZERO
  151. #define RT_USING_RANDOM
  152. #define RT_USING_PWM
  153. #define RT_USING_RTC
  154. #define RT_USING_SDIO
  155. #define RT_SDIO_STACK_SIZE 4096
  156. #define RT_SDIO_THREAD_PRIORITY 15
  157. #define RT_MMCSD_STACK_SIZE 4096
  158. #define RT_MMCSD_THREAD_PRIORITY 22
  159. #define RT_MMCSD_MAX_PARTITION 16
  160. #define RT_USING_SPI
  161. #define RT_USING_QSPI
  162. #define RT_USING_AUDIO
  163. #define RT_AUDIO_REPLAY_MP_BLOCK_SIZE 4096
  164. #define RT_AUDIO_REPLAY_MP_BLOCK_COUNT 2
  165. #define RT_AUDIO_RECORD_PIPE_SIZE 2048
  166. #define RT_USING_BLK
  167. /* Partition Types */
  168. #define RT_BLK_PARTITION_DFS
  169. #define RT_BLK_PARTITION_EFI
  170. /* end of Partition Types */
  171. #define RT_USING_PIN
  172. #define RT_USING_KTIME
  173. #define RT_LWIP_PBUF_POOL_BUFSIZE 1700
  174. /* end of Device Drivers */
  175. /* C/C++ and POSIX layer */
  176. /* ISO-ANSI C layer */
  177. /* Timezone and Daylight Saving Time */
  178. #define RT_LIBC_USING_LIGHT_TZ_DST
  179. #define RT_LIBC_TZ_DEFAULT_HOUR 8
  180. #define RT_LIBC_TZ_DEFAULT_MIN 0
  181. #define RT_LIBC_TZ_DEFAULT_SEC 0
  182. /* end of Timezone and Daylight Saving Time */
  183. /* end of ISO-ANSI C layer */
  184. /* POSIX (Portable Operating System Interface) layer */
  185. #define RT_USING_POSIX_FS
  186. #define RT_USING_POSIX_DEVIO
  187. #define RT_USING_POSIX_STDIO
  188. #define RT_USING_POSIX_POLL
  189. #define RT_USING_POSIX_SELECT
  190. #define RT_USING_POSIX_TERMIOS
  191. #define RT_USING_POSIX_AIO
  192. #define RT_USING_POSIX_DELAY
  193. #define RT_USING_POSIX_CLOCK
  194. #define RT_USING_POSIX_TIMER
  195. /* Interprocess Communication (IPC) */
  196. #define RT_USING_POSIX_PIPE
  197. #define RT_USING_POSIX_PIPE_SIZE 512
  198. #define RT_USING_POSIX_MESSAGE_QUEUE
  199. #define RT_USING_POSIX_MESSAGE_SEMAPHORE
  200. /* Socket is in the 'Network' category */
  201. /* end of Interprocess Communication (IPC) */
  202. /* end of POSIX (Portable Operating System Interface) layer */
  203. /* end of C/C++ and POSIX layer */
  204. /* Network */
  205. #define RT_USING_SAL
  206. #define SAL_INTERNET_CHECK
  207. /* Docking with protocol stacks */
  208. #define SAL_USING_LWIP
  209. /* end of Docking with protocol stacks */
  210. #define SAL_USING_POSIX
  211. #define RT_USING_NETDEV
  212. #define NETDEV_USING_IFCONFIG
  213. #define NETDEV_USING_PING
  214. #define NETDEV_USING_NETSTAT
  215. #define NETDEV_USING_AUTO_DEFAULT
  216. #define NETDEV_IPV4 1
  217. #define NETDEV_IPV6 0
  218. #define RT_USING_LWIP
  219. #define RT_USING_LWIP212
  220. #define RT_USING_LWIP_VER_NUM 0x20102
  221. #define RT_LWIP_MEM_ALIGNMENT 64
  222. #define RT_LWIP_IGMP
  223. #define RT_LWIP_ICMP
  224. #define RT_LWIP_DNS
  225. /* Static IPv4 Address */
  226. #define RT_LWIP_IPADDR "192.168.4.10"
  227. #define RT_LWIP_GWADDR "192.168.4.1"
  228. #define RT_LWIP_MSKADDR "255.255.255.0"
  229. /* end of Static IPv4 Address */
  230. #define RT_LWIP_UDP
  231. #define RT_LWIP_TCP
  232. #define RT_LWIP_RAW
  233. #define RT_MEMP_NUM_NETCONN 8
  234. #define RT_LWIP_PBUF_NUM 512
  235. #define RT_LWIP_RAW_PCB_NUM 4
  236. #define RT_LWIP_UDP_PCB_NUM 4
  237. #define RT_LWIP_TCP_PCB_NUM 4
  238. #define RT_LWIP_TCP_SEG_NUM 40
  239. #define RT_LWIP_TCP_SND_BUF 8196
  240. #define RT_LWIP_TCP_WND 8196
  241. #define RT_LWIP_TCPTHREAD_PRIORITY 16
  242. #define RT_LWIP_TCPTHREAD_MBOX_SIZE 8
  243. #define RT_LWIP_TCPTHREAD_STACKSIZE 16184
  244. #define RT_LWIP_ETHTHREAD_PRIORITY 12
  245. #define RT_LWIP_ETHTHREAD_STACKSIZE 8192
  246. #define RT_LWIP_ETHTHREAD_MBOX_SIZE 8
  247. #define RT_LWIP_REASSEMBLY_FRAG
  248. #define LWIP_NETIF_STATUS_CALLBACK 1
  249. #define LWIP_NETIF_LINK_CALLBACK 1
  250. #define RT_LWIP_NETIF_NAMESIZE 6
  251. #define SO_REUSE 1
  252. #define LWIP_SO_RCVTIMEO 1
  253. #define LWIP_SO_SNDTIMEO 1
  254. #define LWIP_SO_RCVBUF 1
  255. #define LWIP_SO_LINGER 0
  256. #define LWIP_NETIF_LOOPBACK 0
  257. #define RT_LWIP_USING_PING
  258. /* end of Network */
  259. /* Memory protection */
  260. /* end of Memory protection */
  261. /* Utilities */
  262. #define RT_USING_RYM
  263. #define YMODEM_USING_FILE_TRANSFER
  264. #define RT_USING_UTEST
  265. #define UTEST_THR_STACK_SIZE 4096
  266. #define UTEST_THR_PRIORITY 20
  267. #define RT_USING_RESOURCE_ID
  268. #define RT_USING_ADT
  269. #define RT_USING_ADT_AVL
  270. #define RT_USING_ADT_BITMAP
  271. #define RT_USING_ADT_HASHMAP
  272. #define RT_USING_ADT_REF
  273. /* end of Utilities */
  274. /* Memory management */
  275. #define RT_PAGE_AFFINITY_BLOCK_SIZE 0x1000
  276. #define RT_PAGE_MAX_ORDER 11
  277. /* Debugging */
  278. /* end of Debugging */
  279. /* end of Memory management */
  280. /* Using USB legacy version */
  281. /* end of Using USB legacy version */
  282. /* end of RT-Thread Components */
  283. /* RT-Thread Utestcases */
  284. /* end of RT-Thread Utestcases */
  285. /* RT-Thread online packages */
  286. /* IoT - internet of things */
  287. /* Wi-Fi */
  288. /* Marvell WiFi */
  289. /* end of Marvell WiFi */
  290. /* Wiced WiFi */
  291. /* end of Wiced WiFi */
  292. /* CYW43012 WiFi */
  293. /* end of CYW43012 WiFi */
  294. /* BL808 WiFi */
  295. /* end of BL808 WiFi */
  296. /* CYW43439 WiFi */
  297. /* end of CYW43439 WiFi */
  298. /* end of Wi-Fi */
  299. /* IoT Cloud */
  300. /* end of IoT Cloud */
  301. /* end of IoT - internet of things */
  302. /* security packages */
  303. /* end of security packages */
  304. /* language packages */
  305. /* JSON: JavaScript Object Notation, a lightweight data-interchange format */
  306. /* end of JSON: JavaScript Object Notation, a lightweight data-interchange format */
  307. /* XML: Extensible Markup Language */
  308. /* end of XML: Extensible Markup Language */
  309. /* end of language packages */
  310. /* multimedia packages */
  311. /* LVGL: powerful and easy-to-use embedded GUI library */
  312. /* end of LVGL: powerful and easy-to-use embedded GUI library */
  313. /* u8g2: a monochrome graphic library */
  314. /* end of u8g2: a monochrome graphic library */
  315. /* end of multimedia packages */
  316. /* tools packages */
  317. /* end of tools packages */
  318. /* system packages */
  319. /* enhanced kernel services */
  320. /* end of enhanced kernel services */
  321. /* acceleration: Assembly language or algorithmic acceleration packages */
  322. /* end of acceleration: Assembly language or algorithmic acceleration packages */
  323. /* CMSIS: ARM Cortex-M Microcontroller Software Interface Standard */
  324. /* end of CMSIS: ARM Cortex-M Microcontroller Software Interface Standard */
  325. /* Micrium: Micrium software products porting for RT-Thread */
  326. /* end of Micrium: Micrium software products porting for RT-Thread */
  327. /* end of system packages */
  328. /* peripheral libraries and drivers */
  329. /* HAL & SDK Drivers */
  330. /* STM32 HAL & SDK Drivers */
  331. /* end of STM32 HAL & SDK Drivers */
  332. /* Kendryte SDK */
  333. /* end of Kendryte SDK */
  334. /* end of HAL & SDK Drivers */
  335. /* sensors drivers */
  336. /* end of sensors drivers */
  337. /* touch drivers */
  338. /* end of touch drivers */
  339. /* end of peripheral libraries and drivers */
  340. /* AI packages */
  341. /* end of AI packages */
  342. /* Signal Processing and Control Algorithm Packages */
  343. /* end of Signal Processing and Control Algorithm Packages */
  344. /* miscellaneous packages */
  345. /* project laboratory */
  346. /* end of project laboratory */
  347. /* samples: kernel and components samples */
  348. /* end of samples: kernel and components samples */
  349. /* entertainment: terminal games and other interesting software packages */
  350. /* end of entertainment: terminal games and other interesting software packages */
  351. /* end of miscellaneous packages */
  352. /* Arduino libraries */
  353. /* Projects and Demos */
  354. /* end of Projects and Demos */
  355. /* Sensors */
  356. /* end of Sensors */
  357. /* Display */
  358. /* end of Display */
  359. /* Timing */
  360. /* end of Timing */
  361. /* Data Processing */
  362. /* end of Data Processing */
  363. /* Data Storage */
  364. /* Communication */
  365. /* end of Communication */
  366. /* Device Control */
  367. /* end of Device Control */
  368. /* Other */
  369. /* end of Other */
  370. /* Signal IO */
  371. /* end of Signal IO */
  372. /* Uncategorized */
  373. /* end of Arduino libraries */
  374. /* end of RT-Thread online packages */
  375. /* Hardware Drivers */
  376. /* On-chip Peripheral Drivers */
  377. #define BSP_USING_IOPAD
  378. #define BSP_USING_UART
  379. #define RT_USING_UART0
  380. #define RT_USING_UART1
  381. #define BSP_USING_SPI
  382. #define RT_USING_SPIM2
  383. #define BSP_USING_CAN
  384. #define RT_USING_CANFD
  385. #define RT_USING_CAN0
  386. #define RT_USING_CAN1
  387. #define BSP_USING_GPIO
  388. #define BSP_USING_QSPI
  389. #define RT_USING_QSPI0
  390. #define USING_QSPI_CHANNEL0
  391. #define BSP_USING_ETH
  392. #define BSP_USING_PWM
  393. #define RT_USING_PWM2
  394. #define BSP_USING_I2C
  395. #define I2C_USE_MIO
  396. #define RT_USING_MIO15
  397. #define BSP_USING_SDIF
  398. #define BSP_USING_SDCARD_FATFS
  399. #define USING_SDIF0
  400. #define USE_SDIF0_EMMC
  401. #define USING_SDIF1
  402. #define USE_SDIF1_TF
  403. #define BSP_USING_DC
  404. #define RT_USING_DC_CHANNEL0
  405. #define RT_USING_DC_CHANNEL1
  406. #define BSP_USING_I2S
  407. #define RT_I2S_SAMPLERATE 8000
  408. #define RT_I2S_SAMPLEBITS 16
  409. #define RT_USING_I2S0
  410. /* end of On-chip Peripheral Drivers */
  411. /* Board extended module Drivers */
  412. /* end of Hardware Drivers */
  413. #define PHYTIUM_ARCH_AARCH32
  414. /* Standalone Setting */
  415. #define TARGET_ARMV8_AARCH32
  416. #define USE_AARCH64_L1_TO_AARCH32
  417. /* Soc configuration */
  418. #define TARGET_E2000Q
  419. #define SOC_NAME "e2000"
  420. #define TARGET_TYPE_NAME "q"
  421. #define SOC_CORE_NUM 4
  422. #define F32BIT_MEMORY_ADDRESS 0x80000000
  423. #define F32BIT_MEMORY_LENGTH 0x80000000
  424. #define F64BIT_MEMORY_ADDRESS 0x2000000000
  425. #define F64BIT_MEMORY_LENGTH 0x800000000
  426. #define TARGET_E2000
  427. #define DEFAULT_DEBUG_PRINT_UART1
  428. /* end of Soc configuration */
  429. /* Board Configuration */
  430. #define BOARD_NAME "demo"
  431. #define E2000Q_DEMO_BOARD
  432. /* IO mux configuration when board start up */
  433. /* end of IO mux configuration when board start up */
  434. /* end of Board Configuration */
  435. /* Sdk common configuration */
  436. #define ELOG_LINE_BUF_SIZE 0x100
  437. #define LOG_ERROR
  438. #define USE_DEFAULT_INTERRUPT_CONFIG
  439. #define INTERRUPT_ROLE_MASTER
  440. /* end of Sdk common configuration */
  441. /* end of Standalone Setting */
  442. #endif