Skip to content

Commit

Permalink
driver/usbvideodriver: add support for newer C920 Webcam
Browse files Browse the repository at this point in the history
This supports only raw and jpeg capture.

Signed-off-by: Jan Luebbe <[email protected]>
  • Loading branch information
jluebbe committed Oct 28, 2021
1 parent 35f534a commit bc8efbd
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions labgrid/driver/usbvideodriver.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ def get_qualities(self):
("mid", "image/jpeg,width=1280,height=720,framerate=15/2"),
("high", "image/jpeg,width=1920,height=1080,framerate=10/1"),
])
if match == (0x046d, 0x08e5): # Logitech HD Pro Webcam C920
return ("mid", [
("low", "image/jpeg,width=640,height=360,framerate=5/1"),
("mid", "image/jpeg,width=1280,height=720,framerate=15/2"),
("high", "image/jpeg,width=1920,height=1080,framerate=10/1"),
])
if match == (0x534d, 0x2109): # MacroSilicon
return ("mid", [
("low", "image/jpeg,width=720,height=480,framerate=10/1"),
Expand All @@ -54,6 +60,9 @@ def get_pipeline(self, path, caps, controls=None):
elif match == (0x046d, 0x0892):
controls = controls or "focus_auto=1"
inner = None
elif match == (0x046d, 0x08e5):
controls = controls or "focus_auto=1"
inner = None
elif match == (0x534d, 0x2109):
inner = None # just forward the jpeg frames
else:
Expand Down

0 comments on commit bc8efbd

Please sign in to comment.