HP Truevision HD built-in webcam not working in ubuntu 18.04

I have a HP Notebook-15-ac603tu and after shifting to ubuntu from windows, the camera stopped working.

I have run the following commands with output:

  • lsusb :
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 042: ID 0bda:57d6 Realtek Semiconductor Corp. 
Bus 001 Device 003: ID 0bda:b006 Realtek Semiconductor Corp. 
Bus 001 Device 002: ID 25a7:fa23  
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  • v4l2-ctl --list-devices :
HP Truevision HD: HP Truevision (usb-0000:00:14.0-5):
    /dev/video0
  • ls -ltr /dev/video* :
crw-rw----+ 1 root video 81, 0 Mar 22 11:59 /dev/video0
  • cheese :
(cheese:6397): Gtk-WARNING **: 12:11:18.227: Theme parsing error: cheese.css:7:35: The style property GtkScrollbar:min-slider-length is deprecated and shouldn't be used anymore. It will be removed in a future version

** (cheese:6397): CRITICAL **: 12:11:18.789: cheese_preferences_dialog_on_source_change: assertion '_tmp2_ > ((guint) 0)' failed

(cheese:6397): cheese-CRITICAL **: 12:11:18.789: cheese_camera_device_get_name: assertion 'CHEESE_IS_CAMERA_DEVICE (device)' failed

(cheese:6397): GLib-CRITICAL **: 12:11:18.790: g_variant_new_string: assertion 'string != NULL' failed

(cheese:6397): GLib-CRITICAL **: 12:11:18.790: g_variant_ref_sink: assertion 'value != NULL' failed

(cheese:6397): GLib-GIO-CRITICAL **: 12:11:18.790: g_settings_schema_key_type_check: assertion 'value != NULL' failed

(cheese:6397): GLib-CRITICAL **: 12:11:18.790: g_variant_get_type_string: assertion 'value != NULL' failed

(cheese:6397): GLib-GIO-CRITICAL **: 12:11:18.790: g_settings_set_value: key 'camera' in 'org.gnome.Cheese' expects type 's', but a GVariant of type '(null)' was given

(cheese:6397): GLib-CRITICAL **: 12:11:18.791: g_variant_unref: assertion 'value != NULL' failed

** (cheese:6397): CRITICAL **: 12:11:18.791: cheese_preferences_dialog_setup_resolutions_for_device: assertion 'device != NULL' failed

** (cheese:6397): CRITICAL **: 12:11:20.317: cheese_preferences_dialog_on_source_change: assertion '_tmp2_ > ((guint) 0)' failed

(cheese:6397): cheese-CRITICAL **: 12:11:20.318: cheese_camera_device_get_name: assertion 'CHEESE_IS_CAMERA_DEVICE (device)' failed

screenshot of cheese displaying black screen

I tried almost everything and I don't know how to proceed further (basically am a noob user). Please help me out in working my webcam.


Solution 1:

The cheese error messages are similar to those in this report:

  • Webcam not working with cheese (unless sudo-ed)

The solution was to use sudo when calling cheese.

Other users in the link suggest other packages that work when cheese doesn't work.

That said use the following commands to make sure webcam is connected:

$ sudo apt install hwinfo

$ hwinfo --usb

11: USB 00.0: 0000 Unclassified device
  [Created at usb.122]
  Unique ID: X7GA.tCH1FaBg9PD
  Parent ID: k4bc.2DFUsyrieMD
  SysFS ID: /devices/pci0000:00/0000:00:14.0/usb1/1-7/1-7:1.0
  SysFS BusID: 1-7:1.0
  Hardware Class: unknown
  Model: "Sunplus Innovation Integrated_Webcam_HD"
  Hotplug: USB
  Vendor: usb 0x1bcf "Sunplus Innovation Technology Inc."
  Device: usb 0x2b8c "Integrated_Webcam_HD"
  Revision: "47.14"
  Driver: "uvcvideo"
  Driver Modules: "uvcvideo"
  Device File: /dev/input/event8
  Device Files: /dev/input/event8, /dev/input/by-id/usb-SunplusIT_Inc_Integrated_Webcam_HD-event-if00, /dev/input/by-path/pci-0000:00:14.0-usb-0:7:1.0-event
  Device Number: char 13:72
  Speed: 480 Mbps
  Module Alias: "usb:v1BCFp2B8Cd4714dcEFdsc02dp01ic0Eisc01ip00in00"
  Driver Info #0:
    Driver Status: uvcvideo is active
    Driver Activation Cmd: "modprobe uvcvideo"
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #14 (Hub)

You can get the much of the same information with lsbusb -v but it doesn't concisely provide it the same way.

Solution 2:

I encountered a similar webcam issue with the Ubuntu 18.04 distribution that was installed in an Acer notebook and posted a similar question 2 months ago. That notebook used a Webcam by Realtek Semiconductor Corp. I found that it is not a recognized USB Video Class Linux device. As such, this incompatability resulted in the cheese app giving a blank screen like what you have shown.

I suspect your notebook webcam device is either

Bus 001 Device 042: ID 0bda:57d6 Realtek Semiconductor Corp.,  or
Bus 001 Device 003: ID 0bda:b006 Realtek Semiconductor Corp. 

Either case, they do not appear to be a USB Video Class Linux device too. If so, uvcvideo would not be able to initialize it and that is why the cheese app appeared blank as is shown in your screenshot.

So it may be that until your webcam device becomes a USB Video Class Linux device, it will not work with uvcvideo.

Solution 3:

Check your userid is in the "video" group. I have an HP laptop with the same camera, and as far as I know, it's using standard "uvcvideo" driver module. But you can't use it from users not in the video group.