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

    C290 With Duet lapse

    Scheduled Pinned Locked Moved
    Third-party software
    3
    19
    887
    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.
    • stuartofmtundefined
      stuartofmt @TRATOON
      last edited by stuartofmt

      @tratoon

      Yes - this is entirely possible.

      For the most part, the camera libraries in the Pi only allow one connection at a time. This is in part why I wrote videostream. It provides a http interface that can handle multiple connections to the video feed.
      I use it all the time with DuetLapse and a browser. The camera display in DWC can also be connected to videostream as the connection is the same as using a browser.

      It's all documented fairly comprehensively, if there is something that needs clarification, let me know.

      One thing I would say (if you are not overly familiar with the Pi etc.) - take it a step at a time.
      For example - make sure that the camera works using fswebcam first, then get videostream working and finally DuetLapse3.

      code7undefined TRATOONundefined 5 Replies Last reply Reply Quote 0
      • code7undefined
        code7 @stuartofmt
        last edited by

        @stuartofmt I am receiving this error message while testing to see if the USB camera will work with DuetLapse3. Does this response mean the camera is not compatible or might I be overlooking something else?

        pi@duet3:~/DuetLapse3 $ fswebcam image.jpg
        --- Opening /dev/video0...
        Trying source module v4l2...
        Error opening device: /dev/video0
        open: Permission denied
        Trying source module v4l1...
        Error opening device: /dev/video0
        open: Permission denied
        Unable to find a source module that can read /dev/video0.
        

        Delta Printer Using a Duet 2 Wifi v1.04c, FW3.4.0beta2, Duet WiFi sever 1.26, Duet Web Control 3.3.0

        stuartofmtundefined 1 Reply Last reply Reply Quote 0
        • stuartofmtundefined
          stuartofmt @code7
          last edited by

          @code7

          A couple of questions:
          What OS are you using?

          cat /etc/os-release
          

          The camera may not be /dev/video0.

          With the camera unplugged.

          1. What is the output of :
          v4l2-ctl --list-devices
          
          1. What is the output of:
          ls /dev/video*
          

          Plug in the camera and repeat the two commands above as well as:

          dmesg
          

          What new device showed up ?

          fswebcam can be directed to explicitly a particular camera with the form:

          fswebcam --device /dev/video[x] image.jpg
          

          Depending on how your Pi is set up there can be multiple logical camera's identified.

          You can also try these test programs:
          https://github.com/stuartofmt/Pi-Notes/blob/master/Resolution Testing.md

          stuartofmtundefined 1 Reply Last reply Reply Quote 1
          • stuartofmtundefined
            stuartofmt @stuartofmt
            last edited by

            @code7

            Have you had success?

            code7undefined 1 Reply Last reply Reply Quote 0
            • code7undefined
              code7 @stuartofmt
              last edited by

              @stuartofmt Thanks for your recommendations. I actually found another camera that worked instead.

              Delta Printer Using a Duet 2 Wifi v1.04c, FW3.4.0beta2, Duet WiFi sever 1.26, Duet Web Control 3.3.0

              1 Reply Last reply Reply Quote 0
              • TRATOONundefined
                TRATOON @stuartofmt
                last edited by

                @stuartofmt Hello, I got fswebcam to take a picture. However, I am having trouble with vidstream. I'm on Pi4 so I'm using libcam, I put in python3 ./videostream.py -port 8090 -pires "--width 800 --height 600"`. And I got a > on the console, I then went to pi'sip:8090/stream] and http://pi'sip:8090/stream, it says failed to open the page. Please help.

                1 Reply Last reply Reply Quote 0
                • TRATOONundefined
                  TRATOON @stuartofmt
                  last edited by

                  @stuartofmt Just checked my OS, I' on Buster. So I tried installing opencv but the running setup.py bdist_wheel for opencv-contrib-python is taking a while

                  1 Reply Last reply Reply Quote 0
                  • TRATOONundefined
                    TRATOON
                    last edited by

                    This post is deleted!
                    1 Reply Last reply Reply Quote 0
                    • TRATOONundefined
                      TRATOON @stuartofmt
                      last edited by

                      @stuartofmt I installed DuetLapse and got videostream streaming, how do I tell duetlapse to start recording when I start a print, take a pic every 10 seconds, and when print is finished or canceled, compile it into a video?
                      So far I did

                      mkdir DuetLapse - or other directory of your choice
                      cd DuetLapse
                      wget https://github.com/stuartofmt/DuetLapse3/raw/main/DuetLapse3.py
                      chmod 744 DuetLapse3.py

                      1 Reply Last reply Reply Quote 0
                      • TRATOONundefined
                        TRATOON @stuartofmt
                        last edited by

                        @stuartofmt Also, how do I have videostream autmatically run when pi starts?

                        stuartofmtundefined 1 Reply Last reply Reply Quote 0
                        • stuartofmtundefined
                          stuartofmt @TRATOON
                          last edited by

                          @tratoon
                          I have been offline for a couple of weeks.. have you tried following the examples in the documentation? If so, what issues are you seeing.

                          TRATOONundefined 2 Replies Last reply Reply Quote 0
                          • TRATOONundefined
                            TRATOON @stuartofmt
                            last edited by

                            @stuartofmt every time I shut down and power the pi on, I have to send the nohup command to run video stream anyway to automate this.

                            1 Reply Last reply Reply Quote 0
                            • TRATOONundefined
                              TRATOON @stuartofmt
                              last edited by

                              @stuartofmt I will try to figure duet lapse 3 over weekend

                              stuartofmtundefined 1 Reply Last reply Reply Quote 0
                              • stuartofmtundefined
                                stuartofmt @TRATOON
                                last edited by

                                @tratoon

                                In my view - the best way to control videostream at startup is with systemctl.
                                There is an example unit file and instructions in the documentation.

                                You don't need to run it with nohup.

                                Give systemctl a go and if you have issues I can help.

                                TRATOONundefined 1 Reply Last reply Reply Quote 0
                                • TRATOONundefined
                                  TRATOON @stuartofmt
                                  last edited by

                                  @stuartofmt sudo -H -u pi python3 /home/pi/DuetLapse/DuetLapse3.py -duet 192.168.1.217 -seconds 20 -detect none -camera1 web -weburl1 http://192.168.1.217:8090/stream I have this line In rctest.local along with a line that starts videostream.

                                  In my DuetLapse/duet3/192-168-1-217 I have 2 folders: 603 & 1639 Both with JPEGS that give errors when I try opening something about it starts with some character. I also have a bunch of logs in there.

                                  stuartofmtundefined 1 Reply Last reply Reply Quote 0
                                  • stuartofmtundefined
                                    stuartofmt @TRATOON
                                    last edited by

                                    @tratoon said in C290 With Duet lapse:

                                    @stuartofmt sudo -H -u pi python3 /home/pi/DuetLapse/DuetLapse3.py -duet 192.168.1.217 -seconds 20 -detect none -camera1 web -weburl1 http://192.168.1.217:8090/stream I have this line In rctest.local along with a line that starts videostream.

                                    In my DuetLapse/duet3/192-168-1-217 I have 2 folders: 603 & 1639 Both with JPEGS that give errors when I try opening something about it starts with some character. I also have a bunch of logs in there.

                                    Also - if you are having problems, its best to run the program from the command line and include -verbose. That way you will get a log file and be able to see if there are issues being reported on the console.

                                    When you view http://192.168.1.217:8090/stream from a browser, does it display ok?

                                    I cannot do much to help you without seeing the logfile (using -verbose). My guess is that there is an issue with ffmpeg.

                                    What output do you get from running:

                                    ffmpeg --version
                                    
                                    1 Reply Last reply Reply Quote 0
                                    • First post
                                      Last post
                                    Unless otherwise noted, all forum content is licensed under CC-BY-SA