How do I use multiple ZED cameras on one computer?

It is possible to connect multiple ZED cameras to a single host, such as a Windows or Linux PC, a server, or an NVIDIA® Jetson™ board. For sample code, check out the Multi-Camera sample on GitHub.

StereoLabs cameras come in two connectivity families, and the hardware recommendations depend on which one you use:

  • USB 3.0 cameras: ZED, ZED Mini, ZED 2, ZED 2i. They connect to any Windows or Linux host. Note: the ZED and ZED 2 models are out of production.
  • GMSL2 cameras: ZED X, ZED X Mini, ZED X Nano, ZED X One S/GS, ZED X One 4K. They connect through a ZED Link GMSL2 capture card and are only compatible with NVIDIA® Jetson™ platforms.

Both families can be combined on the same host.

Hardware Recommendations for USB cameras

  • Watch the USB bandwidth: The ZED in 1080p30 mode generates around 250MB/s of image data. The maximum USB 3.0 bandwidth is around 620MB/s, so the number of cameras, resolutions, and frame rates you can use on a single machine is limited by the USB 3.0 controller on the motherboard. When the bandwidth limit is exceeded, corrupted frames (green or purple frames, tearing) can appear, and cameras may even disconnect.
  • Use PCIe expansion cards: To use multiple USB ZED cameras at full speed on a single computer, we recommend distributing them across several USB controllers by adding USB 3.0 multi-channel PCIe expansion cards.

Hardware Recommendations for GMSL2 cameras

GMSL2 cameras do not connect over USB; they use dedicated, low-latency serial links provided by the ZED Link capture card. This removes the USB-controller bottleneck and makes GMSL2 the recommended option for dense multi-camera rigs.

  • Choose the right capture card: each GMSL2 link drives one camera. Pick the capture card according to the number of cameras to be connected to a single Jetson™: ZED Link Mono for 1 camera, ZED Link Duo for up to 4 cameras, ZED Link Quad for up to 8 cameras.
  • Mind the power budget: connecting several GMSL2 cameras increases the current draw on the capture card, especially when powering accessories over the GMSL2 link. Check the GMSL2 Power Requirements before scaling up a rig.
  • Install the ZED Link driver: GMSL2 cameras require the ZED Link driver to be installed on the Jetson™ before they can be opened by the ZED SDK. See Install and Upgrade the Drivers.

Increase GPU memory

The ZED SDK needs up to 750MB of GPU memory when retrieving depth information in NEURAL LIGHT mode. To make sure you don't run out of GPU memory when using the SDK with multiple cameras, we recommend an NVIDIA® GPU with at least 6GB of memory. On NVIDIA® Jetson™ platforms, where memory is shared between CPU and GPU, make sure the device has enough total RAM for the number of cameras and depth modes you plan to run.

Frame synchronization

  • GMSL2 (hardware triggering): cameras connected to the same ZED Link Duo or Quad capture card are automatically frame-synchronized. The capture card can also act as a trigger master or slave, and multiple capture cards can be chained so all their cameras share the same trigger. See the GPIO triggering guides for the ZED Link Mono, ZED Link Duo, and ZED Link Quad.
  • USB: USB cameras do not expose a hardware trigger. To align frames across USB cameras, rely on the image timestamps provided by the ZED SDK, or use a local network setup with PTP synchronization.

How to List Connected Cameras

The ZED SDK can list the connected cameras using getDeviceList(), and provide their serial number for identification. Once you know which ZED should be opened, you can request a specific serial number with InitParameters.input.setFromSerialNumber(1010).

For more details, see the full documentation page: Setting Up Multiple 3D Cameras.