Creating a safety interlock on an enclosure with PWNCNC vfd

Hi all
I’ve just fitted the 2.2kw @PwnCNC kit and z-20 to our x-35 woodworker. I’m now trying to figure out how to interlock the enclosure as it’s used in a teaching lab and we need to prevent accidental loss of limbs (as much as possible)
Does anyone know if there is an external pause “trigger” via the 25pin breakout connector?
Ideally I need it to pause the motion and spindle, but spindle only would do.
Previously we had a microswitch on the enclosure door that simply interrupted the power to the makita.
I’m not sure doing this to the VFD would be a good idea and hopefully there’s a smarter way…
Any thoughts?

1 Like

Hey Andrew,

unfortunately there is no hardware-based pause button to use for this purpose on the buildbotics-based Onefinity controller. The only pin that is available is ‘estop’ on pin 23 of 25-pin I/O port which will trigger the ‘estopped’ mode (configure it on the I/O page) which will not only stop the steppers, but also the VFD/spindle if connected via RS-485 Modbus pins 13 and 14, or a router or VFD if attached via ‘tool-enable’ pin 15. Unfortunately ‘estopped’ mode does not pause program, but definitively stops the program, and all position and homing information is lost. The yellow ring on the display blinks between orange and yellow then. You can also enter the ‘estopped’ mode by clicking on the red button yellow ring on the display (but not by hitting the button on the controller box)

1 Like

Thanks, that’s basically confirming what I thought.
The virtual is E-stop useful but if it’s connected to an enclosure door you’re not able to job the machine around.
Next question is; if I want to just stop the spindle with a door open, can I interrupt the signal from the VFD somehow without just turning it off?

Hey Andrew,

  1. on VFDs controlled by Modbus communication over a RS-485 serial line, most cheaper VFDs do not support the START/STOP function on the VFD keypad or by a switch wired to one of the input terminals at the same time, so the CNC controller has to send the STOP command via Modbus. There however is the possibility to enter a ‘ModBus Override Mode’ on Omron MX2 (PDF Manual) or Hitachi WJ200 (PDF Manual) (which are practically nearly identical) or on Hitachi S1 VFDs. With these, you can temporaraly override the ModBus control by CNC controller at any time by a switch “Modbus override” wired to the VFD and another switch at same time serving as “STOP” switch, and this way stop the spindle. This is described here and here.

  2. On VFDs that run on controllers like the Masso which is incapable of Modbus communication, speed is controlled by an analog voltage and START/STOP is controlled via an input terminal by a hi/lo state change from a digital output from the VFD, or by a switch. This input can also be used to simply trigger STOP on these VFDs.

As far as I know, PwnCNC offers their VFD in both configurations, Modbus for the Onefinity Standard series, control lines for the Elite (Masso) Series. Is your model controlled by Modbus or by control lines? If the first, I would ask Daniel @PwnCNC if your model supports Modbus override.

Note that industrial VFDs like Omron MX2 have Intelligent Terminals which you can program to serve as ISO 13849-1 Safety Inputs, and support safety wiring with a safety relay like Omron G9SE. A CNC controller would be integrated into this safety circuit, including door sensor. However the limitation that the Onefinity controller cannot pause and resume by a hardware input remains, it’s only ‘estopped’ mode that is available.

However, if you stop the spindle, but not the g-code program, the bit is likely to break, which can be dangerous too.

:warning: In any case, never interrupt the spindle power between spindle and VFD! Your VFD may get damaged. A spindle must only be stopped by the STOP function of the VFD. Also a VFD must only be powered off when the spindle is stopped.

1 Like

Hmm that’s interesting. So the pwn VFD kit has an auto-manual mode switch on it.
I wonder if I could use that as a way to stop the spindle without powering off the VFD…?
It should satisfy our requirements for a spindle cutout with the enclosure open (of sorts).
As long as the spindle re-starts once the mode is switched back, we might be onto a winner.
I’ll have a test tomorrow and see what happens.
Thanks.

Good morning Andrew,

I think I remember that it was mentioned somewhere, but I am not sure.
I don’t know what exact functionality your VFD offers, as Daniel @PwnCNC programs them in different configurations. You got to ask him.

If there is such a Modbus override mode, it would be possible. The other way would be to not use Modbus at all, but to control the VFD like the Masso does: With analog voltage for speed and a control line for START/STOP. With this, you could at any time trigger STOP on the VFD by an additional switch. The difference is with speed, with Modbus you send an exact rpm value, but with analog voltage just a voltage, so you got to fine-tune the speed accuracy. But this is how the Masso controls the VFD. The VFD has to be programmed differently then, though.

But how will you solve the problem that when you stop the spindle, but not the g-code program, the machine will try to drive a bit that is not rotating through the workpiece?

1 Like

Thanks for the information @Aiph5u
I’ll try and see what Daniel @PwnCNC has to say regarding this. If possible I’d like to retain the modbus functionality as there will be multiple users and retaining the standard Fusion360 post processor is the ideal situation.
The interlock is there to mainly prevent the spindle from running with the doors open.
The user would need to pause or stop the machine before opening the doors, otherwise, like you say, the machine will crash. It’s not perfect but it seems at the limit of what this controller can achieve.

Hey Andrew,

the postprocessor will not be affected by this choice. A VFD controlled by analog voltage for speed and control line for START/STOP is still using the same g-code, with M3/M5 and S. The difference is you will set “PWM spindle” as tool-type and you will put a little pwm-to-voltage converter on the pwm output on 25-pin I/O port, and START/STOP on ‘tool-enable’ pin.

1 Like

Ok, this is definitely something to look into. Thanks again!

Hey Andrew, did you ever get the stop to work on the door enclosure? I am looking at a CNC for my school, but it must have this safety enclosure.

1 Like

Sort of, I sent you a DM.