Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

E-Stop implementation #7

Open
AlexT-38 opened this issue Jan 23, 2023 · 2 comments
Open

E-Stop implementation #7

AlexT-38 opened this issue Jan 23, 2023 · 2 comments
Labels
discussion electrical issues related to mains voltage circuitry electronics issues relating to low voltage circuits

Comments

@AlexT-38
Copy link
Collaborator

AlexT-38 commented Jan 23, 2023

See FluidNC E-Stop docs and onefinitycnc forum post.

E-Stop requirements

We need to ensure that the machine can be safely stopped in an emergency. This includes machine faults, as well as direct risk to life events.
The method used should fail safe. That is, if any part of the e-stop system fails, estop should be activated.
Loss of power to the control board or spindle should activate the estop.
After loss of power, restoring power should not allow the machine to move until estop condition is reset.
Operation of the door lock/interlock will be considered as a separate issue.

Recomendations

FluidNC docs recommend cutting the power.
The onefinity form post on the subject recommends against cutting power to a running VFD, but that if risk assessment requires cutting power, the entire machine should be cut off.

Cutting the power will not stop the machine until it has discharged any energy stored in the VFD, stepper drivers and stepper PSU (although in practice this may happen very quickly).

Digital e-stop methods

FluidNC can be reset via gpio, rather than the hardware reset pin.
This will immediately halt the machine and stop the spindle. Steppers will remain energised if the timeout is disabled (which currently it is, to avoid losing position when idle).

The stepper motor enable input is NO(normally open) and must be supplied with current to disable the motors. This isn't ideal because a break in the circuit would prevent the motors from being disabled.

The VFD has an 'estop' signal input. The docs give no detail on how it functions, but presumably it complies with the ISO standards and takes a NC (normally closed) input. Presumably this results in a coasting stop rather than the powered stop that the 'stop' signal would cause.

FluidNC should raise an alarm if the spindle speed falls below target speed, and may also raise an alarm if the VFD reports the estop or stop inputs.

Proposed Schemes

One or more of the following schemes should be implemented:

  1. estop button de-energises a 240V relay, K1, that cuts power to all parts of the machine
  2. estop button directly breaks FluidNC 'reset' signal, controlled stop of machine
  3. estop button directly breaks VFD 'stop' signal, FluidNC responds via comms, controlled stop of machine
  4. estop button directly breaks VFD 'estop' signal, FluidNC responds via comms, controlled stop of stages, spindle coasts to a stop
  5. estop button de-energises a 12V relay, K2, which breaks 'reset' and 'stop'/'estop' signal to FluidNC and VFD
  6. K2 also overrides stepper #Enable signal and de-energises steppers
  7. K2 also latches off, requiring the Power Button to be pressed after power is supplied to reset K2
  8. K2 makes MKS reset pin input instead of breaking FluidNC soft reset.

See this diagram.

Comments

The exact behaviour of FluidNC and the VFD with regards to stop signals and loss of communication needs to be examined before a scheme can be settled on.

@AlexT-38 AlexT-38 added electrical issues related to mains voltage circuitry electronics issues relating to low voltage circuits discussion labels Jan 23, 2023
AlexT-38 added a commit that referenced this issue Jan 23, 2023
Added a diagram showing some of the e-stop schemes described in issue #7
@AlexT-38
Copy link
Collaborator Author

FluidNC does not stop when VFD comms lost, despite setting an alarm.
VFD does not stop when comms lost. This is not ideal.

Spindle shuts down within 0.5s of loss of power. Not sure if it coasts.

FluidNC 'reset' input and VFD 'estop' functions not yet tested.

@AlexT-38
Copy link
Collaborator Author

The VFD reports an under voltage fault when power is cut.
The VFD can also be configured to raise faults for over temperature and over torque conditions.
The fault state of the VFD can be signalled using one of its digital outputs. It is not clear if its operation is NC or NO.
As FluidNC does not have a 'wait for spindle' input, we should use the general fault signal to stop all motion.

The three FluidNC inputs we can use for this are Feed Hold, Reset and Saftey Door.

Reset causes immediate stop of motion and disabling of axis motors. This would be the simplest implementation.

Feed Hold needs to be tested, but it might not respond immediately depending on how it's implemented. If it interrupts the current motion then it would be useful in case of an over torque or other VFD only fault. Estop would still need to be wired to the Reset signal so that a commanded estop causes immediate stop of motion. However, the feed hold button input would have to be wired in series with the fault signal.

Safety Door does not stop motion, but interrupts the current program and moves to the parking position. Probably not what we want, but could be suitable for faults that cause the VFD to stop the spindle. Using this input would be simpler than Feed Hold unless we also want to implement the door interlock.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion electrical issues related to mains voltage circuitry electronics issues relating to low voltage circuits
Projects
None yet
Development

No branches or pull requests

1 participant