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