Capture format. Linux only. On macOS the camera negotiates its own and this
is ignored.
Keep pixel_format="mjpeg" on any host with more than one camera. Uncompressed
video needs about 18 MB per second per camera, and two of those do not fit on
one USB bus.
from videosdk_teleop import (list_cameras, list_serial, resolve_camera, resolve_serial)list_cameras() # every camera, with its by-path namelist_serial() # every serial device, for servo busesresolve_camera(handle) # by-path name to a /dev/video noderesolve_serial(handle) # by-path name to a /dev/ttyACM node
Use the by-path name, never /dev/video0 or /dev/ttyACM0. Those
numbers change across reboots, so two identical cameras can swap places
between runs.
Tired of long names? Register your own short ones once, then use those
anywhere a handle is accepted.
from videosdk_teleop import devicesdevices.CAMERA_ALIASES["wrist"] = "platform-3610000.usb-...-video-index0"
An index, or the camera’s name. There is no path to resolve.
teleop.CameraConfig("0", label="wrist")teleop.CameraConfig("FaceTime HD Camera", label="wrist")
List them with ffmpeg, which uses the same backend:
ffmpeg -f avfoundation -list_devices true -i ""
python -m videosdk_teleop.devices is Linux only, since it reads udev
paths. The alias table is Linux only for the same reason.
The device name. video= is added for you if you leave it off.
Camera indexes and device names are not stable the way a by-path name is.
On a machine with more than one camera, confirm which is which before a
session rather than during one.