Door Switch

If you have a question about the software please ask it here.

Door Switch

Postby Delco » Mon Apr 29, 2024 3:34 am

I am trying to impliment a door switch for a mill in a school enviroment.

I have a npn sensor on the door and have added a input trigger to activate when the door is open and the signal goes low by assigning stop gcode execution to that pin port setup.

It all works to stop gcode and the spindle BUT if the spindle command is executed with the door open then spindle will ramp up to speed. If I assign it to estop that works but the machine cant be jogged with the door open .

How can I assign a input trigger to ensure the spindle cannot be turned on but the machine can still be jogged so they can set zero with a piece of paper ?
Delco
 
Posts: 356
Joined: Tue Apr 02, 2019 4:23 am

Re: Door Switch

Postby ger21 » Mon Apr 29, 2024 10:35 am

The proper way to do it is with a safety relay that kills all power when the door is open.
Gerry
UCCNC 2022 Screenset - http://www.thecncwoodworker.com/2022.html
ger21
 
Posts: 2680
Joined: Sat Sep 03, 2016 2:17 am

Re: Door Switch

Postby cncdrive » Tue Apr 30, 2024 3:41 am

You could write a macroloop, read your door switch input and check if the M3 is active then call the M5 button code, that will kill the M3 command before it could actually do the M3 switching.
cncdrive
Site Admin
 
Posts: 4741
Joined: Tue Aug 12, 2014 11:17 pm


Return to Ask a question from support here

Who is online

Users browsing this forum: Bing [Bot] and 4 guests