Door Open Switch and LED´s
-
@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........
-
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.
-
@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....
-
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:
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...
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 thishttps://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!!!
-
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.]
-
Ok thank you...and both work with USB connection from Raspberry?
-
@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.
-
Ok Thanks! I will test it ...
-
@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.
-
Unfortunately, M25 does not work with a print via USB. See error message
any recommendations?
New Firmware Version
-
@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.
-
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: ReasonThe 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!
-
@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?
-
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">//\saction: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.
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. ...
-
To do this properly, the GCode sender would need to tag each line with a file address or line number or similar (line numbers are a standard but optional feature of GCode) and RRF keep track of them. Then in the resume message, RRF would tell the sender which line to resume from. That way, RRF can do an early pause, throwing away moves that have been queued but not yet executed - just as it does when you print from SD card.
Without this, RRF will need to send the pause response, complete all the moves in the queue, and complete any additional moves that the host has already send or is in the process of sending (otherwise it won't be able to read the resume command from the host). So the pause will be delayed significantly.
It really is much simpler to print from SD card, also that way you are not dependent on a host computer to send the GCode stream fast enough - which is a problem not only with a Windows host but, according to reports, even when using a dedicated Raspberry Pi as the sender.
-
Yes I know that SD would be much easier... i will focus this in the next time... but for other Machines a USB Print is needed.
The delayed pause is ok... I know this...A resume isn´t needed....
Would adding the pause function possible?
-
What is the reason that you want the Duet to be able to initiate the pause? Is it because the reason for the pause is out-of-filament, or something like that? If not, why can't you initiate the pause from Repetier?
-
Yes on the one hand out of filament, but above all the opening of a door. Even if there is a delay, it is better if he still pauses.
-
@cr3d, try setting up a trigger macro (see M581) to run when when the door is opened. In the macro file use this command:
M118 P1 S"// action:pause"
That will send the string to USB.
-
@dc42 said in Door Open Switch and LED´s:
M118 P1 S"// action:pause"
@dc42 -> you are the best!!!!!! Everything is running now!! Thank you so much!