Author: YangyangC_06 Version: **
Translation - Japanese: UVCファームウェアのビデオコントロール機能 - KBA225062 - Community Translated (JA)
How can I add video control feature in UVC firmware?
Consider the UVC example project to which you will add the video control feature.
Cypress provides UVC example project which is at C:\Program Files (x86)\Cypress\EZ-USB FX3\SDK\1.3\firmware\ cx3_examples. Build the Cx3UvcOV5640 project, and then download the image file to the Denebola board. In the MPC-HC viewer, notice that none of the video control feature is enabled (Figure 1).
Figure 1. Disabled Video Controls
This knowledge base article will explain the procedure to enable brightness control. You can enable other video control features in the same way.
Follow these steps to enable the brightness control feature in this firmware:
- The brightness control is defined in the processing unit. As mentioned in the UVC specification V1.1, enable brightness control by setting D0 of bmControls to 1 in the cycx3_uvcdscr.c file.
- Define the macros of feature selector and processing unit ID.
- Write the call back switch branch in CyCx3AppUSBSetupCB.
- Create an EP0 thread to handle the event which is set when the video control targeted command is received.
- Write the code to implement EP0 thread
- According to UVC specification v1.1, the firmware must support Set_Cur, Get_Cur, Get_Min, Get_Max, Get_Res, Get_Info, and Get_Def. Define UVCHandleProcessingUnitRqts as shown in the code snippet.
- Build and download the firmware on to the Denebola board. Brightness control is now enabled in the panel (see Figure 2).
Figure 2. Enabled Brightness Control