Kconfig 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634
  1. config SOC_SERIES_M032
  2. bool
  3. select ARCH_ARM_CORTEX_M0
  4. select SOC_FAMILY_NUMICRO
  5. select RT_USING_COMPONENTS_INIT
  6. select RT_USING_USER_MAIN
  7. default y
  8. config BSP_USE_STDDRIVER_SOURCE
  9. bool "Build StdDriver source"
  10. default n
  11. menuconfig BSP_USING_PDMA
  12. bool "Enable Peripheral Direct Memory Access Controller(PDMA)"
  13. default y
  14. if BSP_USING_PDMA
  15. config NU_PDMA_MEMFUN_ACTOR_MAX
  16. int "Specify maximum mem actor for memfun"
  17. range 1 4
  18. default 4
  19. config NU_PDMA_SGTBL_POOL_SIZE
  20. int "Specify maximum scatter-gather pool size"
  21. range 1 32
  22. default 16
  23. endif
  24. config BSP_USING_FMC
  25. bool "Enable Flash Memory Controller(FMC)"
  26. select RT_USING_FAL
  27. default n
  28. config BSP_USING_GPIO
  29. bool "Enable General Purpose I/O(GPIO)"
  30. select RT_USING_PIN
  31. default y
  32. menuconfig BSP_USING_CLK
  33. bool "Enable Clock Controller(CLK)"
  34. select RT_USING_PM
  35. select BSP_USING_TMR
  36. default y
  37. help
  38. Choose this option if you need CLK/PM function.
  39. Notice: Enable the option will hold timer3 resource
  40. if BSP_USING_CLK
  41. config NU_CLK_INVOKE_WKTMR
  42. bool "Enable SPD1 and DPD mode wakeup timer. (About 6.6 Secs)"
  43. default y
  44. endif
  45. menuconfig BSP_USING_RTC
  46. bool "Enable Real Time Clock(RTC)"
  47. select RT_USING_RTC
  48. config NU_RTC_SUPPORT_IO_RW
  49. bool "Support device RW entry"
  50. depends on BSP_USING_RTC && RT_USING_RTC
  51. config NU_RTC_SUPPORT_MSH_CMD
  52. bool "Support module shell command"
  53. depends on BSP_USING_RTC && RT_USING_RTC
  54. menuconfig BSP_USING_ADC
  55. bool "Enable Enhanced Analog-to-Digital Converter(ADC)"
  56. select RT_USING_ADC
  57. if BSP_USING_ADC
  58. config BSP_USING_ADC0
  59. bool "Enable ADC0"
  60. endif
  61. menuconfig BSP_USING_TMR
  62. bool "Enable Timer Controller(TIMER)"
  63. config BSP_USING_TIMER
  64. bool
  65. config BSP_USING_TIMER_CAPTURE
  66. bool
  67. config BSP_USING_TMR0
  68. bool "Enable TIMER0"
  69. depends on BSP_USING_TMR
  70. if BSP_USING_TMR0
  71. choice
  72. prompt "Select TIMER0 function mode"
  73. config BSP_USING_TIMER0
  74. select BSP_USING_TIMER
  75. select RT_USING_HWTIMER
  76. bool "TIMER"
  77. help
  78. Choose this option if you need TIMER function mode.
  79. config BSP_USING_TIMER0_CAPTURE
  80. select BSP_USING_TIMER_CAPTURE
  81. select RT_USING_INPUT_CAPTURE
  82. bool "TIMER CAPTURE"
  83. help
  84. Choose this option if you need CAPTURE function mode.
  85. endchoice
  86. endif
  87. config BSP_USING_TMR1
  88. bool "Enable TIMER1"
  89. depends on BSP_USING_TMR
  90. if BSP_USING_TMR1
  91. choice
  92. prompt "Select TIMER1 function mode"
  93. config BSP_USING_TIMER1
  94. select BSP_USING_TIMER
  95. select RT_USING_HWTIMER
  96. bool "TIMER"
  97. help
  98. Choose this option if you need TIMER function mode.
  99. config BSP_USING_TIMER1_CAPTURE
  100. select BSP_USING_TIMER_CAPTURE
  101. select RT_USING_INPUT_CAPTURE
  102. bool "TIMER CAPTURE"
  103. help
  104. Choose this option if you need CAPTURE function mode.
  105. endchoice
  106. endif
  107. config BSP_USING_TMR2
  108. bool "Enable TIMER2"
  109. depends on BSP_USING_TMR
  110. if BSP_USING_TMR2
  111. choice
  112. prompt "Select TIMER2 function mode"
  113. config BSP_USING_TIMER2
  114. select BSP_USING_TIMER
  115. select RT_USING_HWTIMER
  116. bool "TIMER"
  117. help
  118. Choose this option if you need TIMER function mode.
  119. config BSP_USING_TIMER2_CAPTURE
  120. select BSP_USING_TIMER_CAPTURE
  121. select RT_USING_INPUT_CAPTURE
  122. bool "TIMER CAPTURE"
  123. help
  124. Choose this option if you need CAPTURE function mode.
  125. endchoice
  126. endif
  127. config BSP_USING_TMR3
  128. bool "Enable TIMER3"
  129. depends on BSP_USING_TMR && !BSP_USING_CLK
  130. if BSP_USING_TMR3
  131. choice
  132. prompt "Select TIMER3 function mode"
  133. config BSP_USING_TIMER3
  134. select BSP_USING_TIMER
  135. select RT_USING_HWTIMER
  136. bool "TIMER"
  137. help
  138. Choose this option if you need TIMER function mode.
  139. config BSP_USING_TIMER3_CAPTURE
  140. select BSP_USING_TIMER_CAPTURE
  141. select RT_USING_INPUT_CAPTURE
  142. bool "TIMER CAPTURE"
  143. help
  144. Choose this option if you need CAPTURE function mode.
  145. endchoice
  146. endif
  147. menuconfig BSP_USING_UART
  148. bool "Enable Universal Asynchronous Receiver/Transmitters(UART)"
  149. select RT_USING_SERIAL
  150. if BSP_USING_UART
  151. config BSP_USING_UART0
  152. bool "Enable UART0"
  153. config BSP_USING_UART0_TX_DMA
  154. bool "Enable UART0 TX DMA"
  155. depends on BSP_USING_UART0 && RT_SERIAL_USING_DMA
  156. config BSP_USING_UART0_RX_DMA
  157. bool "Enable UART0 RX DMA"
  158. depends on BSP_USING_UART0 && RT_SERIAL_USING_DMA
  159. config BSP_USING_UART1
  160. bool "Enable UART1"
  161. config BSP_USING_UART1_TX_DMA
  162. bool "Enable UART1 TX DMA"
  163. depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA
  164. config BSP_USING_UART1_RX_DMA
  165. bool "Enable UART1 RX DMA"
  166. depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA
  167. config BSP_USING_UART2
  168. bool "Enable UART2"
  169. config BSP_USING_UART2_TX_DMA
  170. bool "Enable UART2 TX DMA"
  171. depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA
  172. config BSP_USING_UART2_RX_DMA
  173. bool "Enable UART2 RX DMA"
  174. depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA
  175. config BSP_USING_UART3
  176. bool "Enable UART3"
  177. config BSP_USING_UART3_TX_DMA
  178. bool "Enable UART3 TX DMA"
  179. depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA
  180. config BSP_USING_UART3_RX_DMA
  181. bool "Enable UART3 RX DMA"
  182. depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA
  183. config BSP_USING_UART4
  184. bool "Enable UART4"
  185. config BSP_USING_UART4_TX_DMA
  186. bool "Enable UART4 TX DMA"
  187. depends on BSP_USING_UART4 && RT_SERIAL_USING_DMA
  188. config BSP_USING_UART4_RX_DMA
  189. bool "Enable UART4 RX DMA"
  190. depends on BSP_USING_UART4 && RT_SERIAL_USING_DMA
  191. config BSP_USING_UART5
  192. bool "Enable UART5"
  193. config BSP_USING_UART5_TX_DMA
  194. bool "Enable UART5 TX DMA"
  195. depends on BSP_USING_UART5 && RT_SERIAL_USING_DMA
  196. config BSP_USING_UART5_RX_DMA
  197. bool "Enable UART5 RX DMA"
  198. depends on BSP_USING_UART5 && RT_SERIAL_USING_DMA
  199. config BSP_USING_UART6
  200. bool "Enable UART6"
  201. config BSP_USING_UART6_TX_DMA
  202. bool "Enable UART6 TX DMA"
  203. depends on BSP_USING_UART6 && RT_SERIAL_USING_DMA
  204. config BSP_USING_UART6_RX_DMA
  205. bool "Enable UART6 RX DMA"
  206. depends on BSP_USING_UART6 && RT_SERIAL_USING_DMA
  207. config BSP_USING_UART7
  208. bool "Enable UART7"
  209. config BSP_USING_UART7_TX_DMA
  210. bool "Enable UART7 TX DMA"
  211. depends on BSP_USING_UART7 && RT_SERIAL_USING_DMA
  212. config BSP_USING_UART7_RX_DMA
  213. bool "Enable UART7 RX DMA"
  214. depends on BSP_USING_UART7 && RT_SERIAL_USING_DMA
  215. endif
  216. menuconfig BSP_USING_I2C
  217. bool "Enable I2C Serial Interface Controller(I2C)"
  218. select RT_USING_I2C
  219. if BSP_USING_I2C
  220. config BSP_USING_I2C0
  221. bool "Enable I2C0"
  222. config BSP_USING_I2C1
  223. bool "Enable I2C1"
  224. endif
  225. menuconfig BSP_USING_USCI
  226. bool "Enable Universal Serial Control Interface Controller(USCI)"
  227. if BSP_USING_USCI
  228. config BSP_USING_UUART
  229. bool
  230. config BSP_USING_USPI
  231. bool
  232. config BSP_USING_USPI_PDMA
  233. bool
  234. default n
  235. config BSP_USING_UI2C
  236. bool
  237. config BSP_USING_USCI0
  238. bool "Enable USCI0"
  239. if BSP_USING_USCI0
  240. choice
  241. prompt "Select USCI0 function mode"
  242. config BSP_USING_UUART0
  243. select RT_USING_SERIAL
  244. select BSP_USING_UUART
  245. bool "UUART0"
  246. help
  247. Choose this option if you need UART function mode.
  248. config BSP_USING_UI2C0
  249. select RT_USING_I2C
  250. select BSP_USING_UI2C
  251. bool "UI2C0"
  252. help
  253. Choose this option if you need I2C function mode.
  254. config BSP_USING_USPI0
  255. select RT_USING_SPI
  256. select BSP_USING_USPI
  257. bool "USPI0"
  258. help
  259. Choose this option if you need SPI function mode.
  260. endchoice
  261. config BSP_USING_UUART0_TX_DMA
  262. bool "Enable UUART0 TX DMA"
  263. depends on BSP_USING_UUART0 && RT_SERIAL_USING_DMA
  264. config BSP_USING_UUART0_RX_DMA
  265. bool "Enable UUART0 RX DMA"
  266. depends on BSP_USING_UUART0 && RT_SERIAL_USING_DMA
  267. config BSP_USING_USPI0_PDMA
  268. bool "Use PDMA for data transferring"
  269. select BSP_USING_USPI_PDMA
  270. depends on BSP_USING_USPI0
  271. endif
  272. config BSP_USING_USCI1
  273. bool "Enable USCI1"
  274. if BSP_USING_USCI1
  275. choice
  276. prompt "Select USCI1 function mode"
  277. config BSP_USING_UUART1
  278. select RT_USING_SERIAL
  279. select BSP_USING_UUART
  280. bool "UUART1"
  281. help
  282. Choose this option if you need UART function mode.
  283. config BSP_USING_UI2C1
  284. select RT_USING_I2C
  285. select BSP_USING_UI2C
  286. bool "UI2C1"
  287. help
  288. Choose this option if you need I2C function mode.
  289. config BSP_USING_USPI1
  290. select RT_USING_SPI
  291. select BSP_USING_USPI
  292. bool "USPI1"
  293. help
  294. Choose this option if you need SPI function mode.
  295. endchoice
  296. config BSP_USING_UUART1_TX_DMA
  297. bool "Enable UUART1 TX DMA"
  298. depends on BSP_USING_UUART1 && RT_SERIAL_USING_DMA
  299. config BSP_USING_UUART1_RX_DMA
  300. bool "Enable UUART1 RX DMA"
  301. depends on BSP_USING_UUART1 && RT_SERIAL_USING_DMA
  302. config BSP_USING_USPI1_PDMA
  303. bool "Use PDMA for data transferring"
  304. select BSP_USING_USPI_PDMA
  305. depends on BSP_USING_USPI1
  306. endif
  307. endif
  308. menuconfig BSP_USING_BPWM
  309. bool "Enable Basic PWM Generator and Capture Timer(BPWM)"
  310. select RT_USING_PWM
  311. if BSP_USING_BPWM
  312. config BSP_USING_BPWM_CAPTURE
  313. bool
  314. choice
  315. prompt "Select BPWM0 function mode"
  316. config BSP_USING_BPWM0
  317. select RT_USING_PWM
  318. bool "Enable BPWM0"
  319. help
  320. Choose this option if you need PWM function mode.
  321. config BSP_USING_BPWM0_CAPTURE
  322. select RT_USING_INPUT_CAPTURE
  323. select BSP_USING_BPWM_CAPTURE
  324. bool "Enable BPWM0_CAPTURE"
  325. help
  326. Choose this option if you need PWM capture function mode.
  327. endchoice
  328. if BSP_USING_BPWM0_CAPTURE
  329. config BSP_USING_BPWM0_CAPTURE_CHMSK
  330. hex "Specify channel mask for BPWM0_CAP channel."
  331. range 0 0x3F
  332. default 0
  333. endif
  334. choice
  335. prompt "Select BPWM1 function mode"
  336. config BSP_USING_BPWM1
  337. select RT_USING_PWM
  338. bool "Enable BPWM1"
  339. help
  340. Choose this option if you need PWM function mode.
  341. config BSP_USING_BPWM1_CAPTURE
  342. select RT_USING_INPUT_CAPTURE
  343. select BSP_USING_BPWM_CAPTURE
  344. bool "Enable BPWM1_CAPTURE"
  345. help
  346. Choose this option if you need PWM capture function mode.
  347. endchoice
  348. if BSP_USING_BPWM1_CAPTURE
  349. config BSP_USING_BPWM1_CAPTURE_CHMSK
  350. hex "Specify channel mask for BPWM1_CAP channel."
  351. range 0 0x3F
  352. default 0
  353. endif
  354. endif
  355. menuconfig BSP_USING_PWM
  356. bool "Enable PWM Generator and Capture Timer(PWM)"
  357. if BSP_USING_PWM
  358. config BSP_USING_PWM_CAPTURE
  359. bool
  360. choice
  361. prompt "Select PWM0 function mode"
  362. config BSP_USING_PWM0
  363. select RT_USING_PWM
  364. bool "Enable PWM0"
  365. help
  366. Choose this option if you need PWM function mode.
  367. config BSP_USING_PWM0_CAPTURE
  368. select RT_USING_INPUT_CAPTURE
  369. select BSP_USING_PWM_CAPTURE
  370. bool "Enable PWM0_CAPTURE"
  371. help
  372. Choose this option if you need PWM capture function mode.
  373. endchoice
  374. if BSP_USING_PWM0_CAPTURE
  375. config BSP_USING_PWM0_CAPTURE_CHMSK
  376. hex "Specify channel mask for PWM0_CAP channel."
  377. range 0 0x3F
  378. default 0
  379. endif
  380. choice
  381. prompt "Select PWM1 function mode"
  382. config BSP_USING_PWM1
  383. select RT_USING_PWM
  384. bool "Enable PWM1"
  385. help
  386. Choose this option if you need PWM function mode.
  387. config BSP_USING_PWM1_CAPTURE
  388. select RT_USING_INPUT_CAPTURE
  389. select BSP_USING_PWM_CAPTURE
  390. bool "Enable PWM1_CAPTURE"
  391. help
  392. Choose this option if you need PWM capture function mode.
  393. endchoice
  394. if BSP_USING_PWM1_CAPTURE
  395. config BSP_USING_PWM1_CAPTURE_CHMSK
  396. hex "Specify channel mask for PWM1_CAP channel."
  397. range 0 0x3F
  398. default 0
  399. endif
  400. endif
  401. menuconfig BSP_USING_SPI
  402. bool "Enable Serial Peripheral Interface(SPI)"
  403. select RT_USING_SPI
  404. if BSP_USING_SPI
  405. config BSP_USING_SPI_PDMA
  406. bool
  407. default n
  408. config BSP_USING_SPII2S
  409. bool
  410. default n
  411. choice
  412. prompt "Select SPI0 function mode"
  413. config BSP_USING_SPI0_NONE
  414. bool "NONE"
  415. help
  416. Choose this option if you need not SPI0.
  417. config BSP_USING_SPI0
  418. bool "Enable SPI0"
  419. help
  420. Choose this option if you need SPI function mode.
  421. config BSP_USING_SPII2S0
  422. select RT_USING_AUDIO
  423. select BSP_USING_SPII2S
  424. bool "Enable SPII2S0"
  425. help
  426. Choose this option if you need SPII2S function mode.
  427. endchoice
  428. if BSP_USING_SPI0
  429. config BSP_USING_SPI0_PDMA
  430. bool "Enable PDMA for SPI0"
  431. select BSP_USING_SPI_PDMA
  432. depends on BSP_USING_SPI0
  433. endif
  434. endif
  435. menuconfig BSP_USING_QSPI
  436. bool "Enable Quad Serial Peripheral Interface(QSPI)"
  437. select RT_USING_SPI
  438. select RT_USING_QSPI
  439. select BSP_USING_SPI
  440. if BSP_USING_QSPI
  441. config BSP_USING_QSPI0
  442. bool "Enable QSPI0"
  443. config BSP_USING_QSPI0_PDMA
  444. bool "Enable PDMA for QSPI0"
  445. select BSP_USING_SPI_PDMA
  446. depends on BSP_USING_QSPI0
  447. endif
  448. menuconfig BSP_USING_CRC
  449. bool "Enable Cyclic Redundancy Check Generator(CRC)"
  450. select BSP_USING_CRYPTO
  451. select RT_USING_HWCRYPTO
  452. select RT_HWCRYPTO_USING_CRC
  453. select RT_HWCRYPTO_USING_CRC_07
  454. select RT_HWCRYPTO_USING_CRC_8005
  455. select RT_HWCRYPTO_USING_CRC_1021
  456. select RT_HWCRYPTO_USING_CRC_04C11DB7
  457. if BSP_USING_CRC
  458. config NU_CRC_USE_PDMA
  459. bool "Use PDMA for data transferring."
  460. select BSP_USING_PDMA
  461. default y
  462. endif
  463. menuconfig BSP_USING_SOFT_I2C
  464. bool "Enable SOFT I2C"
  465. if BSP_USING_SOFT_I2C
  466. config BSP_USING_SOFT_I2C0
  467. bool "Enable SOFT I2C0"
  468. select RT_USING_I2C
  469. select RT_USING_I2C_BITOPS
  470. default n
  471. if BSP_USING_SOFT_I2C0
  472. config BSP_SOFT_I2C0_SCL_PIN
  473. hex "Specify the pin index of SCL of SOFT I2C0"
  474. range 0 0x7F
  475. default 0x18
  476. config BSP_SOFT_I2C0_SDA_PIN
  477. hex "Specify the pin index of SDA of SOFT I2C0"
  478. range 0 0x7F
  479. default 0x17
  480. endif
  481. config BSP_USING_SOFT_I2C1
  482. bool "Enable SOFT I2C1"
  483. select RT_USING_I2C
  484. select RT_USING_I2C_BITOPS
  485. default n
  486. if BSP_USING_SOFT_I2C1
  487. config BSP_SOFT_I2C1_SCL_PIN
  488. hex "Specify the pin index of SCL of SOFT I2C1"
  489. range 0 0x7F
  490. default 0x0B
  491. config BSP_SOFT_I2C1_SDA_PIN
  492. hex "Specify the pin index of SDA of SOFT I2C1"
  493. range 0 0x7F
  494. default 0x0A
  495. endif
  496. endif
  497. config BSP_USING_WDT
  498. bool "Enable Watchdog Timer(WDT)"
  499. select RT_USING_WDT
  500. default y
  501. config BSP_USING_EBI
  502. bool "Enable External Bus Interface(EBI)"
  503. default n
  504. config BSP_USING_USBD
  505. bool "Enable Full-Speed USB Device Controller(USBD)"
  506. select RT_USING_USB_DEVICE