Camera Simulators FAQ
Last modified by Lev Andronov on 2025/05/19 13:42
The Chameleon Camera Simulator is designed to function as a camera device and requires a frame grabber to be connected and used as the host for proper operation. Attempting to use it outside this intended workflow may lead to unexpected behavior.
- How to work with camera simulator
- How to run file data continuously without changing buffer content
- How to set up trigger mode
How to work with camera simulator
This guide outlines the basic steps for connecting a Frame Grabber and the Chameleon Camera Simulator, and running them either with two instances of the Vision Point application or using API-based example applications.
- Launch Vision Point and select the Chameleon Camera Simulator device.
Alternatively, run the "KY_Chameleon_Example" application and choose the Chameleon Camera Simulator device. - Configure the initial settings for the Chameleon Simulator:
- Load the user XML file
- Set parameters such as "ConnectionConfigDefault", "AcquisitionFrameRate", etc.
- Do not start image transmission yet.
- Launch a second instance of Vision Point or your custom application, and select the Frame Grabber connected to the Camera Simulator.
- In the Frame Grabber application, click Detect Cameras.
- The Frame Grabber should detect one connected camera — this will be the Chameleon Camera Simulator.
From this point onward, once the Frame Grabber is connected to the Chameleon Simulator, all configuration changes for both the "camera" and the grabber should be made from the grabber side only. - This is necessary because there is no feedback channel from the camera to the grabber. Any changes made directly on the Chameleon side after detection will not be automatically reflected on the grabber.
- Although there is a Refresh button in the grabber’s Camera tab (to forcibly re-read parameters from the camera), it is recommended to make all changes from the grabber side.
- All updates made via the grabber are sent to the camera using the standard CoaXPress protocol — this applies to all cameras, including Chameleon.
- The Frame Grabber should detect one connected camera — this will be the Chameleon Camera Simulator.
- Start transmission from the Frame Grabber side.
- This ensures the grabber sends the start command to the camera and prepares to receive the video stream.
- If you start only from the Chameleon side, the grabber will not automatically begin receiving data.
- Similar to the Refresh operation, starting the camera on the Chameleon side and then separately starting it on the grabber is possible, but this is not typical for real camera workflows.
- Most physical cameras do not have a Start button. The start command is expected to be sent from the grabber over the CXP connection.
NOTES:
- When performing “Camera Detection” on the grabber side, any ongoing video generation on the newly connected camera (Chameleon) will be stopped.
- After detection, you will need to manually start the acquisition process again.
How to run file data continuously without changing buffer content
- Detect the device and camera
- Set initial camera configuration (including trigger configuration)
- Register even callback KYDeviceEventCallBackRegister() to get "KYDEVICE_EVENT_CAMERA_START_REQUEST" event when Frame Grabber sent the "AcquisitionStart" command
- Create a stream using KYFG_StreamCreate()
- Create user buffers using KYFG_BufferAnnounce()
- Register stream callback using KYFG_StreamBufferCallbackRegister() - this will be called each time a frame is sent from the Chameleon simulator.
- Use function KYFG_LoadFileData() to fill the buffer memory previously created.
If you want to fill data from several files, specify the path to DIRECTORY in the "path" input variable. - At this point, you should not touch the Chameleon. All other configurations and acquisition start should be performed by the Frame Grabber (i.e, DO NOT start generation in Chameleon application)
- KYFG_CameraStart() should be invoked when "KYDEVICE_EVENT_CAMERA_START_REQUEST" is received by callback function KYDeviceEventCallBackRegister().
NOTES:
- For non fixed Chameleon configurations (dynamic dimensions and data source) perform points .d-.g in callback registered by KYDeviceEventCallBackRegister().
- To change the data in the buffers in runtime, you should do the following:
a. In the stream callback, use KYFG_BufferGetInfo() function with "KY_STREAM_BUFFER_INFO_BASE" to get a buffer pointer.
b. Copy new data to this buffer. (KYFG_LoadFileData should not be used as it fills all specified buffers)
How to set up trigger mode
The following example illustrates how to configure the trigger to the Chameleon Simulator:
- To set the trigger in Chameleon use the following configurations:
- GUI:
- "Trigger Mode" = "Triggered"
- "Trigger Activation" = "RisingEdge"
- "Trigger Source" = "Camera Trigger"
- API:
- "SimulationTriggerMode" = "Triggered"
- "SimulationTriggerActivation" = "RisingEdge"
- "SimulationTriggerSource" = "KY_CAM_TRIG"
- Make sure Frame Grabber is configured to send triggers over the CoaXPress cable connected to the camera master link 0.
- The Frame Grabber counters should indicate whether a trigger is being sent and if any trigger ack received from the camera.