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

    Door Open Switch and LED´s

    Scheduled Pinned Locked Moved
    Duet Hardware and wiring
    duet leds trigger door door open pause command
    6
    27
    3.3k
    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.
    • Martin1454undefined
      Martin1454
      last edited by

      Which kind of LED's are you using? It it is a LED strip that runs the same voltage as your PSU (12/24V?) then connect it to a spare FAN connector and use the FAN speed to control the brightness

      1 Reply Last reply Reply Quote 0
      • deckingmanundefined
        deckingman @CR3D
        last edited by

        @cr3d M582 is really just to check the state of a trigger which is defined using M581. So the easiest way to configure a door switch is to connect it to a spare end stop input, then use M581.

        As for your LED lights, under what condition do you want to turn them on or off? If it's simply manually at any time, then the obvious answer is to fit a simple on/off switch.

        Ian
        https://somei3deas.wordpress.com/
        https://www.youtube.com/@deckingman

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

          Curious to see how you activate the LED, I chose to make them as a thermostat controlled fan output, enabling whenever bed of hotend is over ambient temperature.

          M106 P1 S1 I0 F500 H0:1 T25 Basic thermostatic control for FAN1 either heater over 25C lights on.

          But I would like to make it so LEDs turn on whenever motors are active as well as when the temperature is high.

          deckingmanundefined zaptaundefined 2 Replies Last reply Reply Quote 0
          • CR3Dundefined
            CR3D
            last edited by

            Thank you for your answers 🙂

            @Martin1454 yes the LED Stripes work with 24V

            Normally my setup is following:

            The Duet is the controller board and the raspberry touch with repetier server is the HMI.
            In repetier server, there is a function Light on/off.

            In Repetier Firmware there is the command M355 S1 / S0 for this function.

            But I will test your solutions 😉

            @bearer i like your idea with the temperature control 🙂

            Christian from CR-3D
            Homepage:
            www.cr-3d.de

            Facebook:
            https://www.facebook.com/cr3d.official

            Our Discord Server
            https://discord.gg/SxRaPNuRdA

            Thingiverse Profile:
            https://www.thingiverse.com/cr-3d_official/about

            1 Reply Last reply Reply Quote 0
            • deckingmanundefined
              deckingman @A Former User
              last edited by

              @bearer said in Door Open Switch and LED´s:

              ............. I chose to make them as a thermostat controlled fan output, enabling whenever bed of hotend is over ambient temperature.

              M106 P1 S1 I0 F500 H0:1 T25 Basic thermostatic control for FAN1 either heater over 25C lights on.

              But I would like to make it so LEDs turn on whenever motors are active as well as when the temperature is high.

              Just out of curiosity, is that a "because I can" kind of thing or is there some practical reason?

              Ian
              https://somei3deas.wordpress.com/
              https://www.youtube.com/@deckingman

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

                @deckingman said in Door Open Switch and LED´s:

                @bearer said in Door Open Switch and LED´s:

                ............. I chose to make them as a thermostat controlled fan output, enabling whenever bed of hotend is over ambient temperature.

                M106 P1 S1 I0 F500 H0:1 T25 Basic thermostatic control for FAN1 either heater over 25C lights on.

                But I would like to make it so LEDs turn on whenever motors are active as well as when the temperature is high.

                Just out of curiosity, is that a "because I can" kind of thing or is there some practical reason?

                Printer is fully enclosed with relatively small windows so it gets relatively dark inside; temperature controlled works well enough when printing but for moving the axis when cold it would be nice to have light as well, and automatic is "always" better than manual:)

                deckingmanundefined 1 Reply Last reply Reply Quote 0
                • deckingmanundefined
                  deckingman @A Former User
                  last edited by

                  @bearer We'll just have to agree to differ on the "automatic is always better than manual" thing. ☺ I just use an on/off switch.....

                  However, in your case how about putting your M106 command in your slicer start gcode rather than config.g? That way, the lights would stay off until you start a print and the temperature gets above ambient. Or maybe, just use a couple of macros - one to turn them on and one to turn them off. Then you could call these from the slicer start and end gcodes as well as at any other time. Just a thought........

                  Ian
                  https://somei3deas.wordpress.com/
                  https://www.youtube.com/@deckingman

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

                    Possibly getting a little OT, but if I can keep the config isolated to the Duet and not the slicer thats a + in my book. Sometimes I do remote operations using a IP camera as well, so automagic or at least controllable is good for me.

                    I'm sure I'll come up with a better plan once I'm more familiar with the Duet and the firmware, but temperature control was quick, easy and 90% good enough, if need be I can heat the bed to 25C in seconds.

                    deckingmanundefined 1 Reply Last reply Reply Quote 0
                    • deckingmanundefined
                      deckingman @A Former User
                      last edited by

                      @bearer Fair comments. Just bear in mind that almost all gcodes can be input at any time - even "on the fly". Sometimes that can useful....

                      Ian
                      https://somei3deas.wordpress.com/
                      https://www.youtube.com/@deckingman

                      1 Reply Last reply Reply Quote 0
                      • CR3Dundefined
                        CR3D
                        last edited by

                        Hi all,

                        thanks again for your answers!

                        I want to show you the working results.

                        I connected the LED´s directly to the fan output and implemented the firmware like this:

                        0_1561054127501_2c61304a-13ec-4dda-b463-72430ca702a3-image.png

                        For the Open Door Switch I want to use M581. In principle it works...the macro is called, but for me M226 doesn´t work...

                        0_1561054244228_23659302-61e0-4ea7-a3a4-2be1a8f7f67c-image.png

                        I have to complete... i use a Raspberry Pi with repetier server as User Interface. The connection is USB.
                        So I have read a lot about USB and Pause...for example this

                        https://forum.duet3d.com/topic/8065/m226-pause-gcode-ignored/12

                        I also updated to the last firmware version...

                        My Pause gets ignored... how to fix it?

                        Thank you a lot!!! 🙂

                        Christian from CR-3D
                        Homepage:
                        www.cr-3d.de

                        Facebook:
                        https://www.facebook.com/cr3d.official

                        Our Discord Server
                        https://discord.gg/SxRaPNuRdA

                        Thingiverse Profile:
                        https://www.thingiverse.com/cr-3d_official/about

                        dc42undefined 1 Reply Last reply Reply Quote 0
                        • dc42undefined
                          dc42 administrators @CR3D
                          last edited by dc42

                          M226 is for use within the GCode file being executed, for example where you want to pause at a particular point to change filament, or insert an object to be embedded within the print. Elsewhere, use M25. [M25 should also work where you are supposed to use M226.]

                          Duet WiFi hardware designer and firmware engineer
                          Please do not ask me for Duet support via PM or email, use the forum
                          http://www.escher3d.com, https://miscsolutions.wordpress.com

                          1 Reply Last reply Reply Quote 0
                          • CR3Dundefined
                            CR3D
                            last edited by

                            Ok thank you...and both work with USB connection from Raspberry?

                            Christian from CR-3D
                            Homepage:
                            www.cr-3d.de

                            Facebook:
                            https://www.facebook.com/cr3d.official

                            Our Discord Server
                            https://discord.gg/SxRaPNuRdA

                            Thingiverse Profile:
                            https://www.thingiverse.com/cr-3d_official/about

                            dc42undefined 1 Reply Last reply Reply Quote 0
                            • dc42undefined
                              dc42 administrators @CR3D
                              last edited by

                              @cr3d said in Door Open Switch and LED´s:

                              Ok thank you...and both work with USB connection from Raspberry?

                              M25 will work. M226 should only be used from within an SD card print.

                              Duet WiFi hardware designer and firmware engineer
                              Please do not ask me for Duet support via PM or email, use the forum
                              http://www.escher3d.com, https://miscsolutions.wordpress.com

                              1 Reply Last reply Reply Quote 0
                              • CR3Dundefined
                                CR3D
                                last edited by

                                Ok Thanks! I will test it ...

                                Christian from CR-3D
                                Homepage:
                                www.cr-3d.de

                                Facebook:
                                https://www.facebook.com/cr3d.official

                                Our Discord Server
                                https://discord.gg/SxRaPNuRdA

                                Thingiverse Profile:
                                https://www.thingiverse.com/cr-3d_official/about

                                1 Reply Last reply Reply Quote 0
                                • zaptaundefined
                                  zapta @A Former User
                                  last edited by

                                  @bearer said in Door Open Switch and LED´s:

                                  But I would like to make it so LEDs turn on whenever motors are active as well as when the temperature is high.

                                  I did something similar by sniffing the serial communication of the Panel Due with a small Arduino board and controlling RGB LEDs colors based on the status, temp, etc. There is a recent thread about it here, with pictures and a link to the source files.

                                  1 Reply Last reply Reply Quote 0
                                  • CR3Dundefined
                                    CR3D
                                    last edited by

                                    Unfortunately, M25 does not work with a print via USB. See error message

                                    any recommendations?

                                    0_1561224612859_ed502ebe-eced-41f4-8137-8cd738ce3d66-image.png

                                    New Firmware Version

                                    0_1561224648034_9cd23856-f659-45bb-8670-bb5c556d1093-image.png

                                    Christian from CR-3D
                                    Homepage:
                                    www.cr-3d.de

                                    Facebook:
                                    https://www.facebook.com/cr3d.official

                                    Our Discord Server
                                    https://discord.gg/SxRaPNuRdA

                                    Thingiverse Profile:
                                    https://www.thingiverse.com/cr-3d_official/about

                                    dc42undefined 1 Reply Last reply Reply Quote 0
                                    • dc42undefined
                                      dc42 administrators @CR3D
                                      last edited by

                                      @cr3d said in Door Open Switch and LED´s:

                                      Unfortunately, M25 does not work with a print via USB. See error message

                                      That's as expected. The headline description of M25 is "Pause SD print". When printing over USB (which we don't recommend anyway), the program that sends the data has to handle pausing. That's what Octoprint and similar programs do.

                                      Duet WiFi hardware designer and firmware engineer
                                      Please do not ask me for Duet support via PM or email, use the forum
                                      http://www.escher3d.com, https://miscsolutions.wordpress.com

                                      1 Reply Last reply Reply Quote 0
                                      • CR3Dundefined
                                        CR3D
                                        last edited by

                                        Yes I know... repetier Server is something like octoprint.
                                        And I know that you don´t recommend it...

                                        I have to use this as my user interface, because my customers want this.... is there no other possibility to control the pause?

                                        I spoke with the guys from repetier, they said that it was possible to request a break.
                                        RequestPause: Reason

                                        The server also understands @Pause
                                        Is it possible to send such commands to the server?

                                        The same problem exists for me with the filament runoutsensor...

                                        Would be glad if you can help me! 🙂

                                        Christian from CR-3D
                                        Homepage:
                                        www.cr-3d.de

                                        Facebook:
                                        https://www.facebook.com/cr3d.official

                                        Our Discord Server
                                        https://discord.gg/SxRaPNuRdA

                                        Thingiverse Profile:
                                        https://www.thingiverse.com/cr-3d_official/about

                                        dc42undefined 1 Reply Last reply Reply Quote 0
                                        • dc42undefined
                                          dc42 administrators @CR3D
                                          last edited by

                                          @cr3d said in Door Open Switch and LED´s:

                                          I spoke with the guys from repetier, they said that it was possible to request a break.
                                          RequestPause: Reason
                                          The server also understands @Pause
                                          Is it possible to send such commands to the server?

                                          Please clarify: what inputs does Repetier Server have for requesting a break?

                                          What is it that your customers don't like about using Duet Web Control as the main user interface?

                                          Duet WiFi hardware designer and firmware engineer
                                          Please do not ask me for Duet support via PM or email, use the forum
                                          http://www.escher3d.com, https://miscsolutions.wordpress.com

                                          1 Reply Last reply Reply Quote 0
                                          • CR3Dundefined
                                            CR3D
                                            last edited by

                                            So now here is the answer from Roland Littwin .. the programmer of Repetier... The answer in the picture is in german... here the translation from the mail:


                                            <response type="requestPause" string="true">//\saction:pause\b\s(.)</response>
                                            <response type="continuePause">//\s
                                            action:resume\b</response>

                                            Recently there was a discussion with the Marlin developers and Gina from Octoprint to correctly implement the official solution. As a result, you can
                                            // action: break
                                            send from the firmware to tell the host to pause. (RequestPause: The reason is the solution only Repetier host / server understand, therefore, if it is officially implemented better you use action commands.)
                                            // action: resume
                                            would make the host talk again.
                                            This was wrong in older server versions because the description was too spongy. But with the last version it should work correctly. Marlin is still echoing: before that what is accepted by the server.
                                            So if the sensors are connected to the printer you have to bring the firmware only to send this. How does David know who wrote the firmware? Logic would then perhaps if sd pressure as always else host ask for break. Whether he also installs a continue or if you should always explicitly click on the server afterwards is then a matter of taste.
                                            Hope that helps to solve it on the firmware side.


                                            0_1561319088281_e72c0d45-7f43-47bc-a866-0345c625d7ac-image.png

                                            In my opinion, a break function is enough. that would continue in my opinion then synonymous over the server suffice.
                                            Is it possible to add this command ... ? 🙂

                                            Thanks a lot!!!

                                            And about Duet interface:

                                            I try to use it more in the future, but companies often like a clear and simple design, file management on the server, display of files etc ... actually things that are less related to printing, but unfortunately it is. ...

                                            Christian from CR-3D
                                            Homepage:
                                            www.cr-3d.de

                                            Facebook:
                                            https://www.facebook.com/cr3d.official

                                            Our Discord Server
                                            https://discord.gg/SxRaPNuRdA

                                            Thingiverse Profile:
                                            https://www.thingiverse.com/cr-3d_official/about

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