slightly change cdc_msc_freertos example

This commit is contained in:
hathach
2024-02-22 19:20:28 +07:00
parent d241f32342
commit 13d26d2166
2 changed files with 32 additions and 25 deletions

View File

@@ -368,6 +368,8 @@ typedef struct TU_ATTR_PACKED {
uint8_t bCopyProtect;
} tusb_desc_video_format_uncompressed_t;
TU_VERIFY_STATIC(sizeof(tusb_desc_video_format_uncompressed_t) == 27, "size is not correct");
// Uncompressed payload specs: 3.1.2 frame descriptor
#define tusb_desc_video_frame_uncompressed_nint_t(_nint) \
struct TU_ATTR_PACKED { \
@@ -381,7 +383,7 @@ typedef struct TU_ATTR_PACKED {
uint32_t dwMinBitRate; \
uint32_t dwMaxBitRate; \
uint32_t dwMaxVideoFrameBufferSize; /* deprecated in 1.5 */ \
uint32_t dwDefaultFrameInterval; \
uint32_t dwDefaultFrameInterval; /* 100ns unit */\
uint8_t bFrameIntervalType; \
uint32_t dwFrameInterval[_nint]; \
}
@@ -413,6 +415,8 @@ typedef struct TU_ATTR_PACKED {
uint8_t bCopyProtect;
} tusb_desc_video_format_mjpeg_t;
TU_VERIFY_STATIC(sizeof(tusb_desc_video_format_mjpeg_t) == 11, "size is not correct");
// MJPEG payload specs: 3.1.2 frame descriptor (same as uncompressed)
typedef tusb_desc_video_frame_uncompressed_t tusb_desc_video_frame_mjpeg_t;
typedef tusb_desc_video_frame_uncompressed_1int_t tusb_desc_video_frame_mjpeg_1int_t;