Connect USB Webcam to UR Control Box USB3.0 just to take images

our goal is to connect a usb webcam to the usb 3 port on the UR control box and trigger it to take images as the robot moves around. These images will be saved onto either the control box itself or on a usb storage stick located on the second usb 2.0 port on the control box.

Is this Doable?

Option 1: URCAP

One way to do it is by developing a URCAP.

For example if you wanted to take a picture at a specific point in the program, you could create a URCap node that takes a picture (e.g. by sending a command to a daemon) when the node is reached in the program.

Another example is if you want a picture to be taken every few seconds, you can create a background thread that takes a picture. Just make sure you have some way of managing the number of pictures taken as this could end up filling up the storage!

You could also create an installation node where you can set various parameters/calibrate the camera.

I would say this is probably the best option if you’d like the camera to be fully controlled directly from the robot controller.

Option 2: External PC

You can connect the webcam to an external PC and use a communication interface (i.e. ethernet) to connect it to the robot. With that you can set-up a program in the PC that opens a socket and waits for a “take picture” command which can be sent from the the UR Controller.

Option 3: Camera I/O Trigger

Another way is to use some form of external trigger option that some cameras provide and connect it with a digital out pin from the robot controller. Then in the program tree you can simply use the set node to set the output high/send a pulse signal. The camera would need some form of internal memory however.

You can also look for industrial cameras that have this functionality built-in.

Feel free to DM me if you need further info on the URCAP option.

Thanks for the awesome and quick reply! We ended up doing Option 3 using a 24V to 3.3V Level shifter between the UR Control Box and a RaspberryPi

1 Like