.. _camera_delay: Camera Delay Measurement =========================== Overview -------- The `ColorSyncNode` is a ROS (Robot Operating System) node that synchronizes the color display on a screen with image capture from a ZED camera, measures the delay between the two events, and logs the results for further analysis. This node is particularly useful for evaluating the performance and latency of camera systems. This documentation covers two scripts: 1. `ColorSyncNode`: A ROS node script for capturing and measuring delays. 2. Data Analysis Script: A Python script for analyzing the captured delay data. .. figure:: ../../img/zed_camera_delay.png :width: 400px :alt: ZED Camera Delay Recording :align: center Script 1: ColorSyncNode ----------------------- This script initializes a ROS node to display colors on a screen, capture images from a ZED camera, and measure the delay between color display and image capture. Prerequisites ^^^^^^^^^^^^^ - Monitor with low latency and high refresh rate - ZED camera - Running ZED Node Running the Script ^^^^^^^^^^^^^^^^^^ To run the script, change the `test_run` variable in the script and execute the following command: .. code-block:: shell rosrun utilities record_camera_delay.py Script 2: Data Analysis ----------------------- This script reads the delay data captured by the `ColorSyncNode`, adjusts for known delays, performs statistical analysis, and generates plots to visualize the data. Prerequisites ^^^^^^^^^^^^^ - Recorded data from the `ColorSyncNode` - Correct path in the script to the delay data file Running the Script ^^^^^^^^^^^^^^^^^^ To run the analysis script, execute the following command: .. code-block:: shell python src/utilities/evaluate_camera_delay.py