In our system we have FX3 controller used to control various IMX image sensors through FPGA. In FX3 we have implemented the firmware from AN75779 (as a starting point) which makes our system recognized as UVC-class device from the Host PC.
There is a need to dynamically change the resolution of the video streams during runtime of the system. In this thread, you explained how we can change the resolution of the stream when the request is initiated by the Host PC.
1) Now, there is one more use case when the request for the resolution change will come from the FX3 device. This is the request to change the resolution from the default one to the desired one.
Namely, our system is designed to support different image sensors from IMX family. Consequently, we would like to be able to start streaming different resolutions depending on the IMX sensor connected (e.g. IMX250, IMX253, IMX420...). We are able to get the IMX sensor ID within CyFxUVCApplnInit() function. However, I am not sure how to inform the Host which resolution will be played. Host expects DEFAULT resolution to be played which is always THE LAST Class specific Uncompressed VS frame descriptor described in CyFxUSBSSConfigDscr descriptor!
I tried with sending
CyU3PUsbSendEP0Data (CY_FX_UVC_MAX_PROBE_SETTING, (uint8_t *)glProbeCtrl_1934x1094_30fps);
to the Host as soon as I get IMX sensor ID but to no avail! It seems something more is needed.
What I am missing here? How FX3 can tell the Host during start-up process which resolution will be played?
2) We need to have a closer communication between the Host and FX3. In addition to requesting basic parameters like change resolution, get gain etc. we would like to be able to send some more requests from the Host to FX3 like:
- Start playing patterns
- Read the value of image sensor register and send it to me (e.g. register value that stores temperature).
To the best of my understanding, extension unit can be used to implement custom (vendor-specific) features (I am aware we need to customize Host application for that).
On page 11 (Section 18.104.22.168) of AN75779 document, you give some explanations on how to design UVC extension unit in FX3 firmware (this thread). I would like to try my luck and implement that. At the same place you mention uvc_extension_app_x64.exe file as well as
"Guidelines to run the Host application is provided in the readme.txt file in the attached project"
Where I can find that uvc_extension_app_x64.exe file and attached project you are talking about?
Thanks for your time and efforts.