Welcome! Log In Create A New Profile

Advanced

Duet 0.6 and Repetier-Host's emergency stop button

Posted by David J 
Duet 0.6 and Repetier-Host's emergency stop button
December 11, 2015 02:22PM
I often like to use Repetier-Host (R-H) to control my printers via USB, but I've encountered a couple of problems with the one that has a Duet 0.6 board.

The first problem seems to have gone away since loading David's "m" version of the firmware - in the past R-H seemed to lose track of the temperature of the hot-end and heatbed. Now they seem to be reported correctly.

The other problem is less important, but annoying: R-H has an emergency stop button that is intended to halt all printer activity - in effect, a panic button. If I click this button when connected to the printer with a RAMPS board all activity stops and, a few seconds later, R-H reconnects and has full control of the printer again. If I do the same thing with the other Duet-powered printer, all activity stops (as it should) but then it stays stopped - R-H seems unable or unwilling to reconnect. The only solution seems to be to click on the disconnect button in R-H, switch off the printer, unplug the USB lead and start again. I suppose I could press the Duet board's reset button, but I can't reach that easily as it's under the covers!

I am not sure what message R-H sends when the button is pressed - maybe M112 - but is there any way to bring everything back to a static-but-communicating state without a total reboot (or the reset key)?
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 11, 2015 03:28PM
Looking at the circuit diagram for the Duet 0.6, it looks like the reset appears on pin 4 of the expansion header - would it be reasonable/safe to put a momentary push-button between pin 4 and pin 2 (ground) with a suitable resistor in series?

I could live with the above problem if the reset button was accessible.
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 11, 2015 05:08PM
Emergency stop halts the printer but does not reset it. This is deliberate, so that if you stop it from one command source e.g. the web interface, another source such as USB won't make it start moving again after a few seconds. After pressing emergency stop, you need to send M999 to reset the Duet.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 11, 2015 05:12PM
I'm sure I tried M999 - maybe I mistyped it. I'll give it another go tomorrow morning.

Thanks.
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 11, 2015 06:57PM
I know M999 works after an emergency stop sent from the web interface, but I guess it could be that it doesn't work from USB. Let me know what you find.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 12, 2015 05:39AM
OK - gave it a try just now.

1. Started a move on the Z axis (as it's the slowest) and hit the emergency stop half-way through. All activity stopped immediately, but I was unable to communicate any more (as described above).
2. Sent M999 and got disconnected from the printer - unable to reconnect again.

I listed the /dev directory and saw that the reset had affected the device name - it was now ttyACM1 instead of ttyACM0 as it was before the reset, and R-H is too dumb to go looking for it. I've had similar issues before in Linux with other devices, in that it doesn't 're-use' the port name when it tries to reconnect. If I unplug the USB and reconnect it goes back to ttyACM0.
Pronterface has the same issue, as does pressing the physical reset button on the Duet (I reached under the covers!). The programs still won't pick up the connection if I aim them at ttyACM1.

I also had a brief try on my Windows 10 machine - R-H didn't seem able to make a reconnection after a stop and reset there either. That needs more investigation though, as it's very difficult for me to connect to that box; I'll follow that up when I can find a longer USB lead.

Edited 1 time(s). Last edit at 12/12/2015 05:48AM by David J.
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 12, 2015 06:53AM
Afterthought: I think the Duet board is trying to remake the USB connection too fast for the Linux system. The OS thinks that the reconnect is actually a new connection, along the lines of "Oh, I have a new USB connection, I already have another called ttyACM0 so I'll call this one ttyACM1". I bet that if the reconnect request was delayed a few seconds so that the old connection was recognised as dropped then it would reappear as ttyACM0.

But this guess may be a load of old cobblers! smiling smiley

Another update: I tried this properly on my Windows 10 machine - the behaviour is much the same. Click on emergency stop, board no longer responsive. Send M999, board remains unresponsive. Disconnect & reconnect from R-H, still unresponsive. Have to disconnect the USB connection & reboot the printer before I get back to normal.

Edited 1 time(s). Last edit at 12/12/2015 07:02AM by David J.
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 15, 2015 07:46AM
David,

Did you have any further thoughts about this? It's not a show-stopper for me, just an inconvenience, as all I have to do is use the function only as an *emergency* stop, rather than a quick-stop as I've done in the past on the printer with the RAMPS board.

cheers,
David

P.S. I know you're very busy! winking smiley

Edited 1 time(s). Last edit at 12/15/2015 07:46AM by David J.
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 15, 2015 08:04AM
Quote
David J
David,

Did you have any further thoughts about this? It's not a show-stopper for me, just an inconvenience, as all I have to do is use the function only as an *emergency* stop, rather than a quick-stop as I've done in the past on the printer with the RAMPS board.

cheers,
David

P.S. I know you're very busy! winking smiley

In my experience, Windows 10 can be very slow at re-making a USB connection - about 5 seconds I think, much worse than Windows 7. I guess it would be possible to introduce a deliberate delay between startup and initializing the USB port, but it would need to be configurable, because other users would find it annoying. I will add it to the list of requested features; however most Duet users control their printers through the web interface, so it will have a low priority.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Duet 0.6 and Repetier-Host's emergency stop button
December 15, 2015 08:47AM
Fair enough! smiling smiley

Mind you - I'm not too bothered by Windows 10, it's Linux that's my main interest...

Edited 1 time(s). Last edit at 12/15/2015 08:52AM by David J.
Sorry, only registered users may post in this forum.

Click here to login