• Tags
  • Documentation
  • Order
  • Register
  • Login
Duet3D Logo Duet3D
  • Tags
  • Documentation
  • Order
  • Register
  • Login

ELP usb camera

Scheduled Pinned Locked Moved
Duet Hardware and wiring
5
15
1.0k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • undefined
    jaygrovr
    last edited by 30 Sept 2020, 05:26

    Does anyone know how to get an 8mp ELP usb camera to work on duet or DWC running on a pi? Thanks

    1 Reply Last reply Reply Quote 0
    • undefined
      T3P3Tony administrators
      last edited by 30 Sept 2020, 06:52

      please can you link to the datasheet and what you have tried so far..

      also have you seen:

      https://forum.duet3d.com/topic/18869/duet-3-rrf-3-1-1-sbc-usb-webcam

      www.duet3d.com

      undefined 1 Reply Last reply 30 Sept 2020, 17:13 Reply Quote 0
      • undefined
        jaygrovr @T3P3Tony
        last edited by 30 Sept 2020, 17:13

        @T3P3Tony yes I tried motion, it seems that there is an issue with selecting the right input on the camera. Btw this camera works out of the box on octoprint. I will find a cut sheet and attach when I get a minute.

        1 Reply Last reply Reply Quote 0
        • undefined
          jay_s_uk
          last edited by 30 Sept 2020, 17:29

          This works apparently https://www.instructables.com/id/How-to-Make-Raspberry-Pi-Webcam-Server-and-Stream-/

          Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

          1 Reply Last reply Reply Quote 0
          • undefined
            jaygrovr
            last edited by 1 Oct 2020, 05:33

            I actually followed that guide and the camera is still not working. The log is complaining something about the camera input not correct as shown here.

            cap.driver: "uvcvideo"
            cap.card: "HD USB Camera: HD USB Camera"
            cap.bus_info: "usb-0000:01:00.0-1.3"
            cap.capabilities=0x84A00001
            ------------------------
            [1:ml1] [NTC] [VID] [Sep 29 17:21:30] v4l2_get_capability: - VIDEO_CAPTURE
            [1:ml1] [NTC] [VID] [Sep 29 17:21:30] v4l2_get_capability: - STREAMING
            [1:ml1] [NTC] [VID] [Sep 29 17:21:30] v4l2_select_input: name = "Camera 1", type 0x00000002, status 00000000
            [1:ml1] [NTC] [VID] [Sep 29 17:21:30] v4l2_select_input: - CAMERA
            [1:ml1] [ERR] [VID] [Sep 29 17:21:30] v4l2_select_input: Error selecting input 0 VIDIOC_S_INPUT: Device or resource busy
            [1:ml1] [ERR] [ALL] [Sep 29 17:21:30] mlp_capture: Video device fatal error - Closing video device
            [1:ml1] [NTC] [VID] [Sep 29 17:21:30] vid_close: Cleaning up V4L2 device
            [1:ml1] [NTC] [VID] [Sep 29 17:21:30] v4l2_cleanup: Closing video device /dev/video0
            [1:ml1] [NTC] [ALL] [Sep 29 17:21:37] mlp_actions: End of event 3
            1 Reply Last reply Reply Quote 0
            • undefined
              jaygrovr
              last edited by 1 Oct 2020, 05:34

              Also its not showing a name of the camera as a device, but I know its the 32e4: since it goes away when I unplug it

              Bus 002 Device 002: ID 2357:0601 TP-Link
              Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
              Bus 001 Device 004: ID 32e4:8830
              Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
              Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
              1 Reply Last reply Reply Quote 0
              • undefined
                jay_s_uk
                last edited by 1 Oct 2020, 05:38

                maybe motion is keeping the camera busy if you've already tried installing that?

                Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

                1 Reply Last reply Reply Quote 0
                • undefined
                  jaygrovr
                  last edited by 2 Oct 2020, 04:19

                  I only installed motion, not sure what else would be keeping it busy.

                  1 Reply Last reply Reply Quote 0
                  • undefined
                    stuartofmt
                    last edited by 2 Oct 2020, 05:37

                    I am using motion on Pi but with the Pi camera - so things may be a bit different but ....

                    Can I suggest that you

                    1. unplug the usb camera

                    2. make sure motion is off
                      sudo systemctl stop motion

                    3. plug the usb camera back in and see if it is "seen" by the OS (I assume you are using debian buster ?) using one or a combination of
                      lsusb
                      dmesg | grep -i usb
                      ls /dev

                    4. assuming that the usb camera is "seen" and shows up as /dev/video0 - check that the motion config file /etc/motion/motion.config has a line with videodevice /dev/video0

                    5. If all is well - restart motion
                      sudo systemctl start motion

                    If this is instructions on how to "suck eggs" please disregard.

                    1 Reply Last reply Reply Quote 0
                    • undefined
                      jaygrovr
                      last edited by 2 Oct 2020, 17:01

                      Looks like it was found.

                      dmesg | grep -i usb
                      1: New USB device fo[ 0.128801] usbcore: registered new interface driver usbfs
                      [ 0.128857] usbcore: registered new interface driver hub
                      [ 0.128982] usbcore: registered new device driver usb
                      [ 1.191613] usbcore: registered new interface driver r8152
                      [ 1.191677] usbcore: registered new interface driver lan78xx
                      [ 1.191744] usbcore: registered new interface driver smsc95xx
                      [ 1.192212] xhci_hcd 0000:01:00.0: new USB bus registered, assigned bus number 1
                      [ 1.195748] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.04
                      [ 1.195765] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
                      [ 1.195780] usb usb1: Product: xHCI Host Controller
                      [ 1.195794] usb usb1: Manufacturer: Linux 5.4.51-v7l+ xhci-hcd
                      [ 1.195808] usb usb1: SerialNumber: 0000:01:00.0
                      [ 1.196390] hub 1-0:1.0: USB hub found
                      [ 1.197053] xhci_hcd 0000:01:00.0: new USB bus registered, assigned bus number 2
                      [ 1.197075] xhci_hcd 0000:01:00.0: Host supports USB 3.0 SuperSpeed
                      [ 1.197515] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003, bcdDevice= 5.04
                      [ 1.197531] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
                      [ 1.197546] usb usb2: Product: xHCI Host Controller
                      [ 1.197560] usb usb2: Manufacturer: Linux 5.4.51-v7l+ xhci-hcd
                      [ 1.197574] usb usb2: SerialNumber: 0000:01:00.0
                      [ 1.198117] hub 2-0:1.0: USB hub found
                      [ 1.200339] usbcore: registered new interface driver uas
                      [ 1.200441] usbcore: registered new interface driver usb-storage
                      [ 1.209395] usbcore: registered new interface driver usbhid
                      [ 1.209406] usbhid: USB HID core driver
                      [ 1.560558] usb 1-1: new high-speed USB device number 2 using xhci_hcd
                      [ 1.743251] usb 1-1: New USB device found, idVendor=2109, idProduct=3431, bcdDevice= 4.21
                      [ 1.743268] usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
                      [ 1.743283] usb 1-1: Product: USB2.0 Hub
                      [ 1.745310] hub 1-1:1.0: USB hub found
                      [ 1.890814] usb 2-1: new SuperSpeed Gen 1 USB device number 2 using xhci_hcd
                      [ 1.921749] usb 2-1: New USB device found, idVendor=2357, idProduct=0601, bcdDevice=30.00
                      [ 1.921766] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=6
                      [ 1.921781] usb 2-1: Product: USB 10/100/1000 LAN
                      [ 1.921795] usb 2-1: Manufacturer: TP-LINK
                      [ 1.921808] usb 2-1: SerialNumber: 000001000000
                      [ 2.091325] usb 2-1: reset SuperSpeed Gen 1 USB device number 2 using xhci_hcd
                      [ 59.510562] usb 1-1.3: new high-speed USB device number 3 using xhci_hcd
                      [ 59.664628] usb 1-1.3: New USB device found, idVendor=32e4, idProduct=8830, bcdDevice= 1.00
                      [ 59.664648] usb 1-1.3: New USB device strings: Mfr=2, Product=1, SerialNumber=3
                      [ 59.664665] usb 1-1.3: Product: HD USB Camera
                      [ 59.664680] usb 1-1.3: Manufacturer: HD USB Camera
                      [ 59.664694] usb 1-1.3: SerialNumber: 2020040501
                      [ 59.729505] uvcvideo: Found UVC 1.00 device HD USB Camera (32e4:8830)
                      [ 59.740595] input: HD USB Camera: HD USB Camera as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3:1.0/input/input1
                      [ 59.741127] usbcore: registered new interface driver uvcvideo
                      [ 59.741141] USB Video Class driver (1.1.1)
                      [110273.729856] usb 1-1.3: USB disconnect, device number 3
                      [110289.379592] usb 1-1.3: new high-speed USB device number 4 using xhci_hcd
                      [110289.532788] usb 1-1.3: New USB device found, idVendor=32e4, idProduct=8830, bcdDevice= 1.00
                      [110289.532797] usb 1-1.3: New USB device strings: Mfr=2, Product=1, SerialNumber=3
                      [110289.532804] usb 1-1.3: Product: HD USB Camera
                      [110289.532810] usb 1-1.3: Manufacturer: HD USB Camera
                      [110289.532815] usb 1-1.3: SerialNumber: 2020040501
                      [110289.535595] uvcvideo: Found UVC 1.00 device HD USB Camera (32e4:8830)
                      [110289.544150] input: HD USB Camera: HD USB Camera as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3:1.0/input/input2
                      [289864.432365] usb 2-1: USB disconnect, device number 2
                      [289864.922629] usb 2-1: new SuperSpeed Gen 1 USB device number 3 using xhci_hcd
                      [289864.953396] usb 2-1: New USB device found, idVendor=2357, idProduct=0601, bcdDevice=30.00
                      [289864.953412] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=6
                      [289864.953425] usb 2-1: Product: USB 10/100/1000 LAN
                      [289864.953438] usb 2-1: Manufacturer: TP-LINK
                      [289864.953450] usb 2-1: SerialNumber: 000001000000
                      [289865.113055] usb 2-1: reset SuperSpeed Gen 1 USB device number 3 using xhci_hcd
                      [289865.274136] usbcore: registered new interface driver cdc_ether
                      [344417.271957] usb 1-1.3: USB disconnect, device number 4
                      [344530.420204] usb 1-1.3: new high-speed USB device number 5 using xhci_hcd
                      [344530.583587] usb 1-1.3: New USB device found, idVendor=32e4, idProduct=8830, bcdDevice= 1.00
                      [344530.583606] usb 1-1.3: New USB device strings: Mfr=2, Product=1, SerialNumber=3
                      [344530.583623] usb 1-1.3: Product: HD USB Camera
                      [344530.583638] usb 1-1.3: Manufacturer: HD USB Camera
                      [344530.583653] usb 1-1.3: SerialNumber: 2020040501
                      [344530.587243] uvcvideo: Found UVC 1.00 device HD USB Camera (32e4:8830)
                      [344530.606258] input: HD USB Camera: HD USB Camera as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3:1.0/input/input3

                      My dev folder has many video lines.. video0 through video16

                      So now I think my camera is actually video1. It seems happier on the log. How can I tell what the URL will be for the camera stream to work with DWC? I understand it has to be an image sequence. Do I need to set the url in the motion.conf properly for that? Can someone give me an example?

                      thanks again everyone

                      Jason

                      undefined 1 Reply Last reply 2 Oct 2020, 19:31 Reply Quote 0
                      • undefined
                        Phaedrux Moderator @jaygrovr
                        last edited by 2 Oct 2020, 19:31

                        @jaygrovr said in ELP usb camera:

                        How can I tell what the URL will be for the camera stream to work with DWC?

                        The URL should be the IP of the Pi with the port you've configured.

                        Z-Bot CoreXY Build | Thingiverse Profile

                        1 Reply Last reply Reply Quote 0
                        • undefined
                          stuartofmt
                          last edited by 3 Oct 2020, 15:41

                          The port is set in /etc/motion/motion.conf

                          I cannot remember the default (8080? 8081?). Look for the line like this

                          # The port number for the live stream.
                          stream_port 8081

                          You can then access it with http://[IP]:8081 (in the example above)

                          1 Reply Last reply Reply Quote 0
                          • undefined
                            jaygrovr
                            last edited by 7 Oct 2020, 04:29

                            Yes, I did both of those things, but i cant get it to work on both the local pi screen and the web page on another pc, either local port or remote, it seems like it has to be one or another. there is an option in the motion setup "stream_localhost" has to be on for it to work locally on attached PI screen and has to be off to work on a remote web browser. How do i make it work on both at the same time? Also the update rate seems to be about 1hz or worse.

                            jason

                            1 Reply Last reply Reply Quote 0
                            • undefined
                              stuartofmt
                              last edited by stuartofmt 10 Jul 2020, 15:55 7 Oct 2020, 15:52

                              I have

                              stream_localhost off 
                              

                              and use a browser to connect. You can use the browser on the Pi to do the same thing (but not sure what the utility is there).

                              Frame rate is set in the motion.conf (15fps default from memory) but this is not the browser refresh rate (closer to 1 per sec). I have not tried to set-up for full real-time streaming since the bandwidth required would be quite high.

                              1 Reply Last reply Reply Quote 0
                              • undefined
                                jaygrovr
                                last edited by 7 Oct 2020, 17:07

                                Stuartofmt, thank you. So you get an image on both a local PI screen and another pc browsing in? What URL did you provide to the DWC configuration?

                                1 Reply Last reply Reply Quote 0
                                3 out of 15
                                • First post
                                  3/15
                                  Last post
                                Unless otherwise noted, all forum content is licensed under CC-BY-SA