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

    Timelapses, are they possible?

    Scheduled Pinned Locked Moved
    Third-party software
    4
    44
    2.6k
    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.
    • A Former User?
      A Former User @Veti
      last edited by

      @Veti said in Timelapses, are they possible?:

      see
      https://github.com/kriechi/DuetRRF-timelapse

      It's exactly what I've read but I can't find a Wiki to understand how to use it...I'm not a Raspberry expert so for me the issue are:

      • Raspberry Pi / Single-Board Computer on the same network as your Duet
        with Python 3 and the requests package
      • Webcam that returns snapshot pictures (still image) via an URL
        mjpg-streamer or similiar: http://127.0.0.1:8080/?action=snapshot

      I think that I had to "throw away" motion eye, right? Or is it possible to use it feature to have an URL fort he still images?

      37bb2018-56e6-46e9-b017-8624057ef1cc-image.png

      In case not should I install only Python 3 and mjpg-streamer to my Raspy?

      Thanks
      Andrea

      p.s.
      as you can see I'm not a Raspberry/Linux expert....sorry

      1 Reply Last reply Reply Quote 0
      • Vetiundefined
        Veti
        last edited by

        @the_dragonlord said in Timelapses, are they possible?:

        I think that I had to "throw away" motion eye, right? Or is it possible to use it feature to have an URL fort he still images?

        if it can produce single images then no, otherwise yes.

        A Former User? 1 Reply Last reply Reply Quote 0
        • A Former User?
          A Former User @Veti
          last edited by A Former User

          @Veti said in Timelapses, are they possible?:

          @the_dragonlord said in Timelapses, are they possible?:

          I think that I had to "throw away" motion eye, right? Or is it possible to use it feature to have an URL fort he still images?

          if it can produce single images then no, otherwise yes.

          It produces single images

          0f64af5d-1fa9-4c7a-9a5f-abe30d44c61f-image.png

          But I can't undesrstand how the command M118 P4 S"LAYER CHANGE" ; take a picture could trigger the shooting of a pic....where do I have to put the URL given? In the web control? I am missing something...

          1 Reply Last reply Reply Quote 0
          • Vetiundefined
            Veti
            last edited by

            @the_dragonlord said in Timelapses, are they possible?:

            But I can't undesrstand how the command M118 P4 S"LAYER CHANGE" ; take a picture could trigger the shooting of a pic....where do I have to put the URL given? In the web control? I am missing something...

            the python script enables a telnet connection to the duet and listens for the "LAYER CHANGE" info
            the webcam url is an option for the python script

            1 Reply Last reply Reply Quote 0
            • resamundefined
              resam
              last edited by

              I'm the author of https://github.com/kriechi/DuetRRF-timelapse - Ask me Anything 😃

              Generating timelapse videos is quiet an opinionated topic in 3D-printing - everybody has a slightly different setup and preferred way of doing it. This is how I currently run my printer setup:

              There are two things needed to make print-synced timelapses:

              • your slicer needs to insert the M118 commands on every layer change
              • your raspberry pi needs to run the timelapse.py script

              You need to enable Telnet support in your Duet board with M586 P2 S1.
              You can start the timelapse script on your RaspberryPi like this:
              ./timelapse.py some-folder-for-all-images/ 192.168.1.42 http://127.0.0.1:8080/?action=snapshot
              (with the IP address of the Duet printer, and the URL is in my case mjpg-streamer returning a single jpg image)

              A Former User? 2 Replies Last reply Reply Quote 1
              • A Former User?
                A Former User @resam
                last edited by

                @resam said in Timelapses, are they possible?:

                I'm the author of https://github.com/kriechi/DuetRRF-timelapse - Ask me Anything 😃

                Generating timelapse videos is quiet an opinionated topic in 3D-printing - everybody has a slightly different setup and preferred way of doing it. This is how I currently run my printer setup:

                There are two things needed to make print-synced timelapses:

                • your slicer needs to insert the M118 commands on every layer change
                • your raspberry pi needs to run the timelapse.py script

                You need to enable Telnet support in your Duet board with M586 P2 S1.
                You can start the timelapse script on your RaspberryPi like this:
                ./timelapse.py some-folder-for-all-images/ 192.168.1.42 http://127.0.0.1:8080/?action=snapshot
                (with the IP address of the Duet printer, and the URL is in my case mjpg-streamer returning a single jpg image)

                ok, now the fog starts to raise a little....so, in order:

                1. I can keep motion eye on my Raspy and install Python 3 and then copy timelapse.py on the Raspy SD
                2. I have to insert the M118 in the layer change as you wrote on github:
                  M400 ; wait for all movement to complete
                  M118 P4 S"LAYER CHANGE" ; take a picture
                  G4 P500 ; wait a bit
                  does this work on IdeaMaker too (I think so)
                3. Do I have to execute manually each time the launch of the script and the timelapse rendering? Isn't it possible to execute them automatically in some way?
                4. Least and last I didn't understand where the final timelapse MP4 will be stored...

                Thanks for your help

                1 Reply Last reply Reply Quote 0
                • resamundefined
                  resam
                  last edited by

                  1. I'm not familiar with motioneye - if you find a URL that you can call and it returns a single still frame as jpg or png, then yes.
                  2. I'm not familiar with IdeaMaker - most slicers have some "on layer change" script section were you can enter a few g-code commands
                  3. with a bit of Linux knowledge it should be easy to do - with varying levels of complexity. I would recommend searching the web for "crontab" or "systemd" in this context
                  4. All the still frames and the final rendered movie will be in the folder path you passed to the timelapse script as first argument
                  A Former User? 2 Replies Last reply Reply Quote 0
                  • A Former User?
                    A Former User @resam
                    last edited by

                    @resam said in Timelapses, are they possible?:

                    1. I'm not familiar with motioneye - if you find a URL that you can call and it returns a single still frame as jpg or png, then yes.
                    2. I'm not familiar with IdeaMaker - most slicers have some "on layer change" script section were you can enter a few g-code commands
                    3. with a bit of Linux knowledge it should be easy to do - with varying levels of complexity. I would recommend searching the web for "crontab" or "systemd" in this context
                    4. All the still frames and the final rendered movie will be in the folder path you passed to the timelapse script as first argument

                    ok, thanks! I'll do some searching and testing!

                    1 Reply Last reply Reply Quote 0
                    • A Former User?
                      A Former User @resam
                      last edited by A Former User

                      @resam said in Timelapses, are they possible?:

                      1. I'm not familiar with motioneye - if you find a URL that you can call and it returns a single still frame as jpg or png, then yes.
                      2. I'm not familiar with IdeaMaker - most slicers have some "on layer change" script section were you can enter a few g-code commands
                      3. with a bit of Linux knowledge it should be easy to do - with varying levels of complexity. I would recommend searching the web for "crontab" or "systemd" in this context
                      4. All the still frames and the final rendered movie will be in the folder path you passed to the timelapse script as first argument

                      Hi, I've installed everything but it doesn't work (of course I've missed something).

                      If can help when the I connect with putty I get this error message:

                      956b8e51-4f89-424f-a9e4-8cdef2627330-image.png

                      this is what I've inserted in etc/profile:
                      sudo python /home/pi/timelapse.py timelapses/ 192.168.1.7 http://192.1.168.13:8080/?action=snapshot

                      1 Reply Last reply Reply Quote 0
                      • resamundefined
                        resam
                        last edited by

                        try with sudo python3 ....

                        python is the old version - python3 is the new one (which you need).

                        A Former User? 1 Reply Last reply Reply Quote 0
                        • A Former User?
                          A Former User @resam
                          last edited by A Former User

                          This post is deleted!
                          1 Reply Last reply Reply Quote 0
                          • resamundefined
                            resam
                            last edited by

                            go and run: python -V and then python3 -V

                            You will probably see that the first one returns 2.7.something and the other one 3.something.else.
                            We need 3.something for the timelapse script to work.

                            You can also avoid this monkey dance by simply calling the timelapse script itself:
                            sudo /home/pi/timelapse.py timelapses/ 192.168.1.7 http://192.1.168.13:8080/?action=snapshot

                            A Former User? 2 Replies Last reply Reply Quote 0
                            • A Former User?
                              A Former User @resam
                              last edited by

                              @resam said in Timelapses, are they possible?:

                              go and run: python -V and then python3 -V

                              You will probably see that the first one returns 2.7.something and the other one 3.something.else.
                              We need 3.something for the timelapse script to work.

                              You can also avoid this monkey dance by simply calling the timelapse script itself:
                              sudo /home/pi/timelapse.py timelapses/ 192.168.1.7 http://192.1.168.13:8080/?action=snapshot

                              uh ok....I'm not a Linux expert....I've change from python to python3 and now no error appear logging into....I've started a trial print to see if all works...I'll let you know in few minutes!

                              1 Reply Last reply Reply Quote 0
                              • A Former User?
                                A Former User @resam
                                last edited by

                                @resam said in Timelapses, are they possible?:

                                go and run: python -V and then python3 -V

                                You will probably see that the first one returns 2.7.something and the other one 3.something.else.
                                We need 3.something for the timelapse script to work.

                                You can also avoid this monkey dance by simply calling the timelapse script itself:
                                sudo /home/pi/timelapse.py timelapses/ 192.168.1.7 http://192.1.168.13:8080/?action=snapshot

                                it's printing but I don't see images going into the folder as long as layers changes

                                1 Reply Last reply Reply Quote 0
                                • resamundefined
                                  resam
                                  last edited by

                                  just start the script in the interactive console (putty) directly. It should print a few log lines so we can see what is happening.

                                  A Former User? 1 Reply Last reply Reply Quote 0
                                  • A Former User?
                                    A Former User @resam
                                    last edited by

                                    @resam said in Timelapses, are they possible?:

                                    just start the script in the interactive console (putty) directly. It should print a few log lines so we can see what is happening.

                                    dde198c5-4298-45a4-ab05-5d539bdbc6db-image.png

                                    1 Reply Last reply Reply Quote 0
                                    • resamundefined
                                      resam
                                      last edited by

                                      Did you enable Telnet in your printer config?

                                      A Former User? 1 Reply Last reply Reply Quote 0
                                      • A Former User?
                                        A Former User @resam
                                        last edited by A Former User

                                        @resam said in Timelapses, are they possible?:

                                        Did you enable Telnet in your printer config?

                                        yes
                                        a9c36ca6-4089-4013-ab98-eb107a8c3584-image.png

                                        1 Reply Last reply Reply Quote 0
                                        • resamundefined
                                          resam
                                          last edited by

                                          ok - that looks right. However it is failing to send commands to the printer...
                                          Does the error message repeat after 15-20 seconds?

                                          A Former User? 1 Reply Last reply Reply Quote 0
                                          • A Former User?
                                            A Former User @resam
                                            last edited by

                                            @resam said in Timelapses, are they possible?:

                                            ok - that looks right. However it is failing to send commands to the printer...
                                            Does the error message repeat after 15-20 seconds?

                                            yes it does

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