Waterjet panel buttons

More
21 May 2014 14:49 #47141 by jtc
Waterjet panel buttons was created by jtc
Hi.

we are currently doing a retrofit on a waterjet system.






the user can turn on and off the 2 nozzles and the 2 abrasive senders by the buttons on this panel. This buttons are connected to a toggle component, and in each state of the toggle it sends a M code. Its like press one time, turn on nozzle1, press another time and turn off the nozzle1. But currently we have a problem. If the machine is running a program, in auto mode, it just ignores the inputs of the buttons. For example if is wanted to disconnect the abrasive sender, it can't be done.


Is some way to have control all the time by the panel buttons?


João
Attachments:

Please Log in or Create an account to join the conversation.

More
21 May 2014 17:45 #47151 by ArcEye
Replied by ArcEye on topic Waterjet panel buttons
Hi

There are shortfalls as you have discovered, to doing everything via HAL and M codes, which essentially are MDI, that is Auto will not allow external input when running.

The solution that immediately comes to mind, is to have the buttons control an electro-mechanical interlock, which in turn indirectly allows a signal to HAL.
That way you would retain the ability to cut off the signal, which presumably is initiated by an M code in the program and then enable that signal again.
The equivilent of having the signal connected via contacts of a relay, but you control whether HAL can energise the relay windings.

However this provides a mechanical override and if you want to set the signal on and off manually as well, you might end up with another button.
Depends exactly how you are set up and how you need to use the machine and what type of physical buttons you have.

regards

Please Log in or Create an account to join the conversation.

More
21 May 2014 19:34 #47153 by andypugh
Replied by andypugh on topic Waterjet panel buttons

This buttons are connected to a toggle component, and in each state of the toggle it sends a M code.


What does the M-code do?

I have a suspicion that you are going to say that the M-code operates an IO pin. If that is the case, then just skip the whole M-code phase, connect the toggle to the IO pin.

Please Log in or Create an account to join the conversation.

More
21 May 2014 20:04 #47156 by jtc
Replied by jtc on topic Waterjet panel buttons

This buttons are connected to a toggle component, and in each state of the toggle it sends a M code.


What does the M-code do?

I have a suspicion that you are going to say that the M-code operates an IO pin. If that is the case, then just skip the whole M-code phase, connect the toggle to the IO pin.


I have to be able to do that in both ways, with the m codes used in the Gcode files, and trough the buttons. the mcodes now use a "sets" halcommand to enable/disable the outputs.


so my idea at the moment, is to use a custom C component, with will connect the Mcodes outputs and the Buttons outputs, and after the desired "logic" it will enable/disable the electrical outputs...

Please Log in or Create an account to join the conversation.

More
21 May 2014 20:38 #47160 by andypugh
Replied by andypugh on topic Waterjet panel buttons

I have to be able to do that in both ways, with the m codes used in the Gcode files, and trough the buttons.
...
so my idea at the moment, is to use a custom C component, with will connect the Mcodes outputs and the Buttons outputs, and after the desired "logic" it will enable/disable the electrical outputs...


toggle2nist of flipflop might already do what you want
www.linuxcnc.org/docs/html/man/man9/toggle2nist.9.html
www.linuxcnc.org/docs/html/man/man9/flipflop.9.html

Your M-codes can set the inputs of a hal component directly, so it then becomes a question of finding the right HAL components.

Have you considered using the coolant M-codes to control the jets? (M7, M8, M9)
M62 / M63 are also worth a look for this kind of thing. Calling a shell script always seems a bit crude to me.

If we assume that you are using M7/8/9 for thsake of description then I guess you want:
M7 always turns on jet1 regardless of button
M8 always turns on jet2 regardless of button
M9 always turns off both regardless of buttons

button 1 turns on jet1 if it is off, and turns it off if it is on?

Flipflop is probably right for this. I have just noticed that the output pin is an IO type, which is annoying, though.
The ideas is to use the G-code outputs to drive the flipflop set and reset, to have overall authority, and then use a momentary switch for manual over-ride connected to the "clock" input.
The data input is an inverted version of the output. Then a rising edge on the clock pin swithces the state of the output.
For clarity i would use an illuminated button with the LED driven by the same IO pin as the jet.
loadrt flipflop count=2
loadrt not count=4
...
addf not.0 servo-thread
addf not.1 servo-thread
addf flipflop.0 servo thread
...
net set1 iocontrol.0.coolant-flood flipflop.0.set not.0.in
net res1 not.0.out flipflop.0.reset
net out1 flipflop.0.out not.1.in parport.0.pin-00-out (or similar)
net not-out1 not.1.out flipflop.0.data
net button1 parport.0.pin-01-in flipflop.0.clk

In practice you will almost certainly want a debounce component on the button/clk pin. Toggle has one built-in, but not flipflop
The following user(s) said Thank You: jtc

Please Log in or Create an account to join the conversation.

More
22 May 2014 03:53 #47178 by jtc
Replied by jtc on topic Waterjet panel buttons
Thank you. I will see it in detail.

João

Please Log in or Create an account to join the conversation.

More
06 Oct 2017 09:13 #99981 by neodym
Replied by neodym on topic Waterjet panel buttons
Hello João

I am interested in the keyboard which you have installed. Do you have information about the manufacturer?

Micha

Please Log in or Create an account to join the conversation.

More
06 Oct 2017 09:23 #99982 by jtc
Replied by jtc on topic Waterjet panel buttons
NGS ivory I believe. It should be hard to find in theses days.

João

Please Log in or Create an account to join the conversation.

Time to create page: 0.185 seconds
Powered by Kunena Forum