Multiple identical webcams - keeping them in order

This topic was touched on by Elso in '14 here

But he sort-of answered his own question without expanding on the cause and best fix for keeping the right camera on the right Video Device In TOP.

To restate the issue, I have two identical webcams on two VideoDeviceIn TOPs, and sometimes after a reboot, the TOPs swap cameras. This creates a problem for interactive installations.

Questions are, why does this happen?, and what’s the best way to prevent it?

Thanks in advance,


If you use the Info DAT on the Video Device In TOP, what kind of information is returned? What library are you using for the cameras? They should have a unique ID that is saved into the .toe file that it uses to try to match them up consistently. If the unique ID is changing for some reason though, then it’ll use the english readable name, which can be out of order depending on how the devices are enumerated on the system.

Hey Malcom,

Thanks for writing back. Here’s what I’m seeing in the info DAT:

Should this be enough for Touch to differentiate them and save the ID in the TOE?

So I guess the question is, are those unique USB identifiers changing on you. If they are then the camera will fall back to trying to match by the English name, which may change if the enumeration order of the cameras has changed. Notice that the identifier is based on the USB ID though, not the physical camera itself. So if you change ports they are plugged into, you may get new IDs.

I will keep an eye on it. This is the first time I recorded the info DAT output, so I’ll have to let you know.

The cameras have never switched ports, but over the duration of the installation (about 8 months so far) the cameras swapped about 3-4 times. I added a button to the interface to allow staff to invoke a camera swap, but I’d still like to try to understand the underlying cause. With 2 cameras it’s not terrible, but with 3 or 4 cameras the ordering fix becomes more complex.

So, this issue reared it’s ugly head again. This morning I had to field a call from staff at the museum because the cameras had spontaneously changed order again. Unfortunately, I didn’t get a screenshot of the “before” for comparison, but here’s what they were today, for the record. I’m just going to have to keep watching for it to occur again, and then we’ll do a comparison.

This setup is using 4 cameras at 720p @ 60fps.

Ok, so we had another occurrence this morning. After a system reboot, cameras 1 and 2 switched order. Here’s a screenshot of the camera info DAT:

It looks like just one of the identifiers changed, but this still doesn’t explain the change of the ordering.

From the DAT, one would think that camera 2’s ID merely changed, when in fact camera 2 somehow got camera 1’s ID, and camera 1 got a new ID and moved to position 2!


The short answer is that USB enumeration order on powerup / bus reset (in cases of power overdraw) is undefined. Some USB host controllers are consistent, some are not. I have observed this behavior over the past decade(s).

Good news – Thunderbolt / USB-C hubs seem to be consistent; they are deterministic between power cycles & disconnect / connect events. I have observed CalDigit & OWC Thunderbolt hubs.

Bad news – They are expensive ($300) for installations & require the CPU to have a Thunderbolt port.

Thanks for the info Adam. I’ll look into the thunderbolt option.

The order is unfortunately arbitrary, it’s however the OS gives us the cameras. We just try to match up with the unique IDs that we are given for run to run consistency.