Multiple GMSL cameras by ID and consitency

Hi,

Looking at docs:
https://www.stereolabs.com/docs/api/structsl_1_1InitParameters.html#details

Select a camera by its ID (/dev/videoX on Linux, and 0 to N cameras connected on Windows)
InitParameters init_params; // Set initial parameters
init_params.sdk_verbose = 1; // Enable verbose mode
init_params.input.setFromCameraID(0); // Selects the camera with ID = 0

Is there some consistency in camera IDs guaranteed for GMSL cameras in the sense plugged hardware port of GMSL splitter/id mapping?

I expect for USB cameras on Linux it might be random cameras racing for init, is it similar for GMSL or is it deterministic?

Is GMSL camera identification by ID also done by /dev/videoX on Linux (as stated in docs) or is the mechanism different?

Kind regards

FWIW, doing some quick experiment

  • 2x camera
  • reboot and check which ID/serial got matched x times
  • swap GMSL connectors
  • reboot and check which ID/serial got matched x times

The results are consistent.

So it at least looks like hardware GMSL connectors are enumerated in order and IDs are assigned in that order.

Hi @bmegli
are you using the latest ZED SDK v4.2.1 with the latest ZED X Driver v1.1.1?

Hi @Myzhar,

Driver 1.0.5, Jetpack JP5.1.2, L4T35.4.

SDK from docker image:
stereolabs/zed:4.1-runtime-l4t-r35.4

So looks like 4.1.

This is used with ROS1 ecosystem. Not really an option to migrate to JP6, if that is only option for 1.1.1, at the moment.

Does that mean that behavior depends on driver version?

Hi @bmegli
with JP5 and driver v1.0.5 the camera ID can change when the Jetson reboots.
This behavior is not present in JP6 starting from ZED X Driver v1.1.1.

With JP5 you can use the serial number to uniquely identify the cameras instead of the ID.