Kconfig 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356
  1. # Kconfig file for CherryUSB
  2. menuconfig CHERRYUSB
  3. bool "CherryUSB Configuration"
  4. default n
  5. if CHERRYUSB
  6. menuconfig CHERRYUSB_DEVICE
  7. bool "Enable usb device mode"
  8. default n
  9. if CHERRYUSB_DEVICE
  10. choice
  11. prompt "Select usb device speed"
  12. default CHERRYUSB_DEVICE_SPEED_FS
  13. config CHERRYUSB_DEVICE_SPEED_FS
  14. bool "FS"
  15. config CHERRYUSB_DEVICE_SPEED_HS
  16. bool "HS"
  17. config CHERRYUSB_DEVICE_SPEED_AUTO
  18. bool "AUTO"
  19. endchoice
  20. choice
  21. prompt "Select usb device ip, and some ip need config in usb_config.h, please check"
  22. default CHERRYUSB_DEVICE_CUSTOM
  23. config CHERRYUSB_DEVICE_CUSTOM
  24. bool "CUSTOM (Implement it yourself)"
  25. config CHERRYUSB_DEVICE_FSDEV_ST
  26. bool "fsdev_st"
  27. config CHERRYUSB_DEVICE_FSDEV_CUSTOM
  28. bool "fsdev_custom"
  29. config CHERRYUSB_DEVICE_DWC2_ST
  30. bool "dwc2_st"
  31. config CHERRYUSB_DEVICE_DWC2_ESP
  32. bool "dwc2_esp"
  33. config CHERRYUSB_DEVICE_DWC2_KENDRYTE
  34. bool "dwc2_kendryte"
  35. config CHERRYUSB_DEVICE_DWC2_AT
  36. bool "dwc2_at"
  37. config CHERRYUSB_DEVICE_DWC2_HC
  38. bool "dwc2_hc"
  39. config CHERRYUSB_DEVICE_DWC2_NATION
  40. bool "dwc2_nation"
  41. config CHERRYUSB_DEVICE_DWC2_GD
  42. bool "dwc2_gd"
  43. config CHERRYUSB_DEVICE_DWC2_CUSTOM
  44. bool "dwc2_custom"
  45. config CHERRYUSB_DEVICE_MUSB_ES
  46. bool "musb_es"
  47. config CHERRYUSB_DEVICE_MUSB_SUNXI
  48. bool "musb_sunxi"
  49. config CHERRYUSB_DEVICE_MUSB_BK
  50. bool "musb_bk"
  51. config CHERRYUSB_DEVICE_MUSB_CUSTOM
  52. bool "musb_custom"
  53. config CHERRYUSB_DEVICE_CHIPIDEA_MCX
  54. bool "chipidea_mcx"
  55. config CHERRYUSB_DEVICE_CHIPIDEA_CUSTOM
  56. bool "chipidea_custom"
  57. config CHERRYUSB_DEVICE_KINETIS_MCX
  58. bool "kinetis_mcx"
  59. config CHERRYUSB_DEVICE_KINETIS_MM32
  60. bool "kinetis_mm32"
  61. config CHERRYUSB_DEVICE_KINETIS_CUSTOM
  62. bool "kinetis_custom"
  63. config CHERRYUSB_DEVICE_BL
  64. bool "bouffalo"
  65. config CHERRYUSB_DEVICE_HPM
  66. bool "hpm"
  67. config CHERRYUSB_DEVICE_AIC
  68. bool "aic"
  69. config CHERRYUSB_DEVICE_RP2040
  70. bool "rp2040"
  71. config CHERRYUSB_DEVICE_CH32
  72. bool "ch32"
  73. config CHERRYUSB_DEVICE_PUSB2
  74. bool "pusb2"
  75. endchoice
  76. config CHERRYUSB_DEVICE_CDC_ACM
  77. bool
  78. prompt "Enable usb cdc acm device"
  79. default n
  80. config CHERRYUSB_DEVICE_HID
  81. bool
  82. prompt "Enable usb hid device"
  83. default n
  84. config CHERRYUSB_DEVICE_MSC
  85. bool
  86. prompt "Enable usb msc device"
  87. default n
  88. config CHERRYUSB_DEVICE_AUDIO
  89. bool
  90. prompt "Enable usb audio device"
  91. default n
  92. config CHERRYUSB_DEVICE_VIDEO
  93. bool
  94. prompt "Enable usb video device"
  95. default n
  96. config CHERRYUSB_DEVICE_CDC_RNDIS
  97. bool
  98. prompt "Enable usb cdc rndis device"
  99. default n
  100. config CHERRYUSB_DEVICE_CDC_ECM
  101. bool
  102. prompt "Enable usb cdc ecm device"
  103. default n
  104. config CHERRYUSB_DEVICE_CDC_NCM
  105. bool
  106. prompt "Enable usb cdc ncm device"
  107. default n
  108. config CHERRYUSB_DEVICE_DFU
  109. bool
  110. prompt "Enable usb dfu device"
  111. default n
  112. config CHERRYUSB_DEVICE_ADB
  113. bool
  114. prompt "Enable usb adb device"
  115. default n
  116. choice
  117. prompt "Select usb device template"
  118. default CHERRYUSB_DEVICE_TEMPLATE_NONE
  119. config CHERRYUSB_DEVICE_TEMPLATE_NONE
  120. bool "none (Implement it yourself)"
  121. config CHERRYUSB_DEVICE_TEMPLATE_CDC_ACM
  122. bool "cdc_acm"
  123. config CHERRYUSB_DEVICE_TEMPLATE_MSC
  124. bool "msc"
  125. config CHERRYUSB_DEVICE_TEMPLATE_HID_KEYBOARD
  126. bool "hid_keyboard"
  127. config CHERRYUSB_DEVICE_TEMPLATE_HID_MOUSE
  128. bool "hid_mouse"
  129. config CHERRYUSB_DEVICE_TEMPLATE_HID_CUSTOM
  130. bool "hid_custom"
  131. config CHERRYUSB_DEVICE_TEMPLATE_VIDEO
  132. bool "video"
  133. config CHERRYUSB_DEVICE_TEMPLATE_AUDIO_V1_MIC_SPEAKER
  134. bool "audio_v1_mic_speaker_multichan"
  135. config CHERRYUSB_DEVICE_TEMPLATE_AUDIO_V2_MIC_SPEAKER
  136. bool "audio_v2_mic_speaker_multichan"
  137. config CHERRYUSB_DEVICE_TEMPLATE_CDC_RNDIS
  138. bool "cdc_rndis"
  139. config CHERRYUSB_DEVICE_TEMPLATE_CDC_ECM
  140. bool "cdc_ecm"
  141. config CHERRYUSB_DEVICE_TEMPLATE_CDC_NCM
  142. bool "cdc_ncm"
  143. config CHERRYUSB_DEVICE_TEMPLATE_CDC_ACM_MSC
  144. bool "cdc_acm_msc"
  145. config CHERRYUSB_DEVICE_TEMPLATE_CDC_ACM_MSC_HID
  146. bool "cdc_acm_msc_hid"
  147. config CHERRYUSB_DEVICE_TEMPLATE_WINUSBV1
  148. bool "winusbv1"
  149. config CHERRYUSB_DEVICE_TEMPLATE_WINUSBV2_CDC
  150. bool "winusbv2_cdc"
  151. config CHERRYUSB_DEVICE_TEMPLATE_WINUSBV2_HID
  152. bool "winusbv2_hid"
  153. endchoice
  154. endif
  155. menuconfig CHERRYUSB_HOST
  156. bool "Enable usb host mode"
  157. default n
  158. if CHERRYUSB_HOST
  159. choice
  160. prompt "Select usb host ip, and some ip need config in usb_config.h, please check"
  161. default CHERRYUSB_HOST_CUSTOM
  162. config CHERRYUSB_HOST_CUSTOM
  163. bool "CUSTOM (Implement it yourself)"
  164. config CHERRYUSB_HOST_EHCI_BL
  165. bool "ehci_bouffalo"
  166. config CHERRYUSB_HOST_EHCI_HPM
  167. bool "ehci_hpm"
  168. config CHERRYUSB_HOST_EHCI_AIC
  169. bool "ehci_aic"
  170. config CHERRYUSB_HOST_EHCI_MCX
  171. bool "ehci_mcx"
  172. config CHERRYUSB_HOST_EHCI_NUC980
  173. bool "ehci_nuc980"
  174. config CHERRYUSB_HOST_EHCI_MA35D0
  175. bool "ehci_ma35d0"
  176. config CHERRYUSB_HOST_EHCI_CUSTOM
  177. bool "ehci_custom"
  178. config CHERRYUSB_HOST_DWC2_ST
  179. bool "dwc2_st"
  180. config CHERRYUSB_HOST_DWC2_ESP
  181. bool "dwc2_esp"
  182. config CHERRYUSB_HOST_DWC2_KENDRYTE
  183. bool "dwc2_kendryte"
  184. config CHERRYUSB_HOST_DWC2_HC
  185. bool "dwc2_hc"
  186. config CHERRYUSB_HOST_DWC2_NATION
  187. bool "dwc2_nation"
  188. config CHERRYUSB_HOST_DWC2_CUSTOM
  189. bool "dwc2_custom"
  190. config CHERRYUSB_HOST_MUSB_ES
  191. bool "musb_es"
  192. config CHERRYUSB_HOST_MUSB_SUNXI
  193. bool "musb_sunxi"
  194. config CHERRYUSB_HOST_MUSB_BK
  195. bool "musb_bk"
  196. config CHERRYUSB_HOST_MUSB_CUSTOM
  197. bool "musb_custom"
  198. config CHERRYUSB_HOST_PUSB2
  199. bool "pusb2"
  200. config CHERRYUSB_HOST_XHCI_PHYTIUM
  201. bool "xhci_phytium"
  202. config CHERRYUSB_HOST_XHCI_CUSTOM
  203. bool "xhci"
  204. config CHERRYUSB_HOST_KINETIS_MCX
  205. bool "kinetis_mcx"
  206. config CHERRYUSB_HOST_KINETIS_MM32
  207. bool "kinetis_mm32"
  208. config CHERRYUSB_HOST_KINETIS_CUSTOM
  209. bool "kinetis_custom"
  210. config CHERRYUSB_HOST_RP2040
  211. bool "rp2040"
  212. endchoice
  213. config CHERRYUSB_HOST_CDC_ACM
  214. bool
  215. prompt "Enable usb cdc acm driver"
  216. default n
  217. config CHERRYUSB_HOST_HID
  218. bool
  219. prompt "Enable usb hid driver"
  220. default n
  221. config CHERRYUSB_HOST_MSC
  222. bool
  223. prompt "Enable usb msc driver"
  224. default n
  225. config CHERRYUSB_HOST_CDC_ECM
  226. bool
  227. prompt "Enable usb cdc ecm driver"
  228. select USBHOST_PLATFORM_CDC_ECM
  229. default n
  230. config CHERRYUSB_HOST_CDC_RNDIS
  231. bool
  232. prompt "Enable usb rndis driver"
  233. select USBHOST_PLATFORM_CDC_RNDIS
  234. default n
  235. config CHERRYUSB_HOST_CDC_NCM
  236. bool
  237. prompt "Enable usb cdc ncm driver"
  238. select USBHOST_PLATFORM_CDC_NCM
  239. default n
  240. config CHERRYUSB_HOST_VIDEO
  241. bool
  242. prompt "Enable usb video driver, it is commercial charge"
  243. default n
  244. config CHERRYUSB_HOST_AUDIO
  245. bool
  246. prompt "Enable usb audio driver, it is commercial charge"
  247. default n
  248. config CHERRYUSB_HOST_BLUETOOTH
  249. bool
  250. prompt "Enable usb bluetooth driver"
  251. default n
  252. config CHERRYUSB_HOST_ASIX
  253. bool
  254. prompt "Enable usb asix driver"
  255. select USBHOST_PLATFORM_ASIX
  256. default n
  257. config CHERRYUSB_HOST_RTL8152
  258. bool
  259. prompt "Enable usb rtl8152 driver"
  260. select USBHOST_PLATFORM_RTL8152
  261. default n
  262. config CHERRYUSB_HOST_FTDI
  263. bool
  264. prompt "Enable usb ftdi driver"
  265. default n
  266. config CHERRYUSB_HOST_CH34X
  267. bool
  268. prompt "Enable usb ch34x driver"
  269. default n
  270. config CHERRYUSB_HOST_CP210X
  271. bool
  272. prompt "Enable usb cp210x driver"
  273. default n
  274. config CHERRYUSB_HOST_PL2303
  275. bool
  276. prompt "Enable usb pl2303 driver"
  277. default n
  278. config CHERRYUSB_HOST_AOA
  279. bool
  280. prompt "Enable usb aoa driver"
  281. default n
  282. config USBHOST_PLATFORM_CDC_ECM
  283. bool
  284. config USBHOST_PLATFORM_CDC_RNDIS
  285. bool
  286. config USBHOST_PLATFORM_CDC_NCM
  287. bool
  288. config USBHOST_PLATFORM_ASIX
  289. bool
  290. config USBHOST_PLATFORM_RTL8152
  291. bool
  292. config CHERRYUSB_HOST_TEMPLATE
  293. bool
  294. prompt "Use usb host template"
  295. default n
  296. if CHERRYUSB_HOST_TEMPLATE
  297. config TEST_USBH_CDC_ACM
  298. int
  299. prompt "demo for test cdc acm"
  300. default 0
  301. depends on CHERRYUSB_HOST_CDC_ACM
  302. config TEST_USBH_HID
  303. int
  304. prompt "demo for test hid"
  305. default 0
  306. depends on CHERRYUSB_HOST_HID
  307. config TEST_USBH_MSC
  308. int
  309. prompt "demo for test msc"
  310. default 0
  311. depends on CHERRYUSB_HOST_MSC
  312. endif
  313. endif
  314. endif