|
| 1 | +# Copyright (c) 2025 tinyVision.ai Inc. |
| 2 | +# |
| 3 | +# SPDX-License-Identifier: Apache-2.0 |
| 4 | + |
| 5 | +config USBD_VIDEO_CLASS |
| 6 | + bool "USB Video Class implementation [EXPERIMENTAL]" |
| 7 | + depends on DT_HAS_ZEPHYR_UVC_DEVICE_ENABLED |
| 8 | + select EXPERIMENTAL |
| 9 | + help |
| 10 | + USB Device Video Class (UVC) implementation. |
| 11 | + |
| 12 | +if USBD_VIDEO_CLASS |
| 13 | + |
| 14 | +config USBD_VIDEO_HEADER_SIZE |
| 15 | + int "USB Video payload header size" |
| 16 | + range 2 255 |
| 17 | + default 8 |
| 18 | + help |
| 19 | + Sets the size of the video payload header to allow custom data to be |
| 20 | + added after the mandatory fields. |
| 21 | + The default value is arbitrary, made to fit situations, preserving a |
| 22 | + 64-bit alignment of the payload data for ease of debugging. |
| 23 | + |
| 24 | +config USBD_VIDEO_MAX_FORMATS |
| 25 | + int "Max number of format descriptors" |
| 26 | + range 1 254 |
| 27 | + default 32 |
| 28 | + help |
| 29 | + The table of format descriptors are generated at runtime. This options plans the |
| 30 | + storage at build time to allow enough descriptors to be generated. The default value |
| 31 | + aims a compromise between enough descriptors for most devices, but not too much memory |
| 32 | + being used. |
| 33 | + |
| 34 | +config USBD_VIDEO_MAX_FRMIVAL |
| 35 | + int "Max number of video output stream per USB Video interface" |
| 36 | + range 1 255 |
| 37 | + default 8 |
| 38 | + help |
| 39 | + Max number of Frame Interval listed on a frame descriptor. The |
| 40 | + default value is selected arbitrarily to fit most situations without |
| 41 | + requiring too much RAM. |
| 42 | + |
| 43 | +config USBD_VIDEO_NUM_BUFS |
| 44 | + int "Max number of buffers the UVC class can allocate" |
| 45 | + default 16 |
| 46 | + help |
| 47 | + Control the number of buffer UVC can allocate in parallel. |
| 48 | + The default is a compromise to allow enough concurrent buffers but not too much |
| 49 | + memory usage. |
| 50 | + |
| 51 | +module = USBD_VIDEO |
| 52 | +module-str = usbd uvc |
| 53 | +default-count = 1 |
| 54 | +source "subsys/logging/Kconfig.template.log_config" |
| 55 | + |
| 56 | +endif # USBD_VIDEO_CLASS |
0 commit comments