Kconfig 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. menu "Hardware Drivers Config"
  2. config SOC_STM32F103ZE
  3. bool
  4. select SOC_SERIES_STM32F1
  5. default y
  6. menu "Onboard Peripheral Drivers"
  7. config BSP_USING_USB_TO_USART
  8. bool "Enable USB TO USART (uart1)"
  9. select BSP_USING_UART
  10. select BSP_USING_UART1
  11. default y
  12. config BSP_USING_RS485_OR_RS232
  13. bool "Enable RS485/RS232 (uart2 be shared)"
  14. select BSP_USING_UART2
  15. default n
  16. config BSP_USING_SPI_FLASH
  17. bool "Enable SPI FLASH (W25Q64 spi1)"
  18. select BSP_USING_SPI
  19. select BSP_USING_SPI1
  20. select RT_USING_SFUD
  21. select RT_SFUD_USING_SFDP
  22. default n
  23. config BSP_USING_RGB
  24. bool "Enable RGB LED (timer3 channel2 - 4)"
  25. select RT_USING_PWM
  26. select BSP_USING_PWM
  27. select BSP_USING_PWM3
  28. select BSP_USING_PWM3_CH2
  29. select BSP_USING_PWM3_CH3
  30. select BSP_USING_PWM3_CH4
  31. default n
  32. config BSP_USING_POT
  33. bool "Enable potentiometer"
  34. select BSP_USING_ADC
  35. select BSP_USING_ADC1
  36. default n
  37. config BSP_USING_EEPROM
  38. bool "Enable I2C EEPROM (i2c1)"
  39. select BSP_USING_I2C1
  40. default n
  41. config BSP_USING_ETH
  42. bool "Enable Ethernet Driver (spi2)"
  43. default n
  44. select PKG_USING_WIZNET
  45. select WIZNET_DEVICE_EXTERN_CONFIG
  46. select BSP_USING_SPI2
  47. if BSP_USING_ETH
  48. if WIZNET_DEVICE_EXTERN_CONFIG
  49. config WIZ_SPI_DEVICE
  50. string
  51. default "spi20"
  52. config WIZ_RST_PIN
  53. int
  54. default 111
  55. config WIZ_IRQ_PIN
  56. int
  57. default 104
  58. endif
  59. config EXTERNAL_PHY_ADDRESS
  60. hex
  61. default 0x00
  62. endif
  63. config BSP_USING_SDCARD
  64. bool "Enable SDCARD (sdio)"
  65. select BSP_USING_SDIO
  66. select RT_USING_DFS
  67. select RT_USING_DFS_ELMFAT
  68. default n
  69. endmenu
  70. menu "On-chip Peripheral Drivers"
  71. config BSP_USING_GPIO
  72. bool "Enable GPIO"
  73. select RT_USING_PIN
  74. default y
  75. menuconfig BSP_USING_UART
  76. bool "Enable UART"
  77. default y
  78. select RT_USING_SERIAL
  79. if BSP_USING_UART
  80. config BSP_USING_UART1
  81. bool "Enable UART1"
  82. default y
  83. config BSP_UART1_RX_USING_DMA
  84. bool "Enable UART1 RX DMA"
  85. depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA
  86. default n
  87. config BSP_USING_UART2
  88. bool "Enable UART2"
  89. default n
  90. config BSP_UART2_RX_USING_DMA
  91. bool "Enable UART2 RX DMA"
  92. depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA
  93. default n
  94. config BSP_USING_UART3
  95. bool "Enable UART3"
  96. default n
  97. config BSP_UART3_RX_USING_DMA
  98. bool "Enable UART3 RX DMA"
  99. depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA
  100. default n
  101. endif
  102. config BSP_USING_ON_CHIP_FLASH
  103. bool "Enable on-chip FLASH"
  104. default n
  105. menuconfig BSP_USING_SPI
  106. bool "Enable SPI BUS"
  107. default n
  108. select RT_USING_SPI
  109. if BSP_USING_SPI
  110. config BSP_USING_SPI1
  111. bool "Enable SPI1 BUS"
  112. default n
  113. config BSP_SPI1_TX_USING_DMA
  114. bool "Enable SPI1 TX DMA"
  115. depends on BSP_USING_SPI1
  116. default n
  117. config BSP_SPI1_RX_USING_DMA
  118. bool "Enable SPI1 RX DMA"
  119. depends on BSP_USING_SPI1
  120. select BSP_SPI1_TX_USING_DMA
  121. default n
  122. config BSP_USING_SPI2
  123. bool "Enable SPI2 BUS"
  124. default n
  125. config BSP_SPI2_TX_USING_DMA
  126. bool "Enable SPI2 TX DMA"
  127. depends on BSP_USING_SPI2
  128. default n
  129. config BSP_SPI2_RX_USING_DMA
  130. bool "Enable SPI2 RX DMA"
  131. depends on BSP_USING_SPI2
  132. select BSP_SPI2_TX_USING_DMA
  133. default n
  134. config BSP_USING_SPI3
  135. bool "Enable SPI3 BUS"
  136. default n
  137. config BSP_SPI3_TX_USING_DMA
  138. bool "Enable SPI3 TX DMA"
  139. depends on BSP_USING_SPI3
  140. default n
  141. config BSP_SPI3_RX_USING_DMA
  142. bool "Enable SPI3 RX DMA"
  143. depends on BSP_USING_SPI3
  144. select BSP_SPI3_TX_USING_DMA
  145. default n
  146. endif
  147. menuconfig BSP_USING_I2C1
  148. bool "Enable I2C1 BUS (software simulation)"
  149. default n
  150. select RT_USING_I2C
  151. select RT_USING_I2C_BITOPS
  152. select RT_USING_PIN
  153. if BSP_USING_I2C1
  154. config BSP_I2C1_SCL_PIN
  155. int "i2c1 scl pin number"
  156. range 0 175
  157. default 22
  158. config BSP_I2C1_SDA_PIN
  159. int "I2C1 sda pin number"
  160. range 0 175
  161. default 23
  162. endif
  163. menuconfig BSP_USING_TIM
  164. bool "Enable timer"
  165. default n
  166. select RT_USING_HWTIMER
  167. if BSP_USING_TIM
  168. config BSP_USING_TIM2
  169. bool "Enable TIM2"
  170. default n
  171. config BSP_USING_TIM3
  172. bool "Enable TIM3"
  173. default n
  174. config BSP_USING_TIM4
  175. bool "Enable TIM4"
  176. default n
  177. config BSP_USING_TIM5
  178. bool "Enable TIM5"
  179. default n
  180. endif
  181. menuconfig BSP_USING_PWM
  182. bool "Enable pwm"
  183. default n
  184. select RT_USING_PWM
  185. if BSP_USING_PWM
  186. menuconfig BSP_USING_PWM3
  187. bool "Enable timer3 output pwm"
  188. default n
  189. if BSP_USING_PWM3
  190. config BSP_USING_PWM3_CH2
  191. bool "Enable PWM3 channel2"
  192. default n
  193. config BSP_USING_PWM3_CH3
  194. bool "Enable PWM3 channel3"
  195. default n
  196. config BSP_USING_PWM3_CH4
  197. bool "Enable PWM3 channel4"
  198. default n
  199. endif
  200. endif
  201. menuconfig BSP_USING_ADC
  202. bool "Enable ADC"
  203. default n
  204. select RT_USING_ADC
  205. if BSP_USING_ADC
  206. config BSP_USING_ADC1
  207. bool "Enable ADC1"
  208. default n
  209. endif
  210. menuconfig BSP_USING_ONCHIP_RTC
  211. bool "Enable RTC"
  212. select RT_USING_RTC
  213. select RT_USING_LIBC
  214. default n
  215. if BSP_USING_ONCHIP_RTC
  216. choice
  217. prompt "Select clock source"
  218. default BSP_RTC_USING_LSE
  219. config BSP_RTC_USING_LSE
  220. bool "RTC USING LSE"
  221. config BSP_RTC_USING_LSI
  222. bool "RTC USING LSI"
  223. endchoice
  224. endif
  225. config BSP_USING_WDT
  226. bool "Enable Watchdog Timer"
  227. select RT_USING_WDT
  228. default n
  229. config BSP_USING_SDIO
  230. bool "Enable SDIO"
  231. select RT_USING_SDIO
  232. select RT_USING_DFS
  233. default n
  234. menuconfig BSP_USING_CAN
  235. bool "Enable CAN"
  236. default n
  237. select RT_USING_CAN
  238. if BSP_USING_CAN
  239. config BSP_USING_CAN1
  240. bool "using CAN1"
  241. default n
  242. endif
  243. source "../libraries/HAL_Drivers/Kconfig"
  244. endmenu
  245. menu "Board extended module Drivers"
  246. endmenu
  247. endmenu