options for combining probe, home and/or torch breakaway?

More
06 Nov 2022 14:58 - 06 Nov 2022 14:59 #256075 by dlv
Still searching the forum but thought I'd post this question anyway to see if anyone has some quick pointers.   I'm in the middle of the process of wiring up my machine.

I will have three physical switches on my Z axis & torch holder.  1)  Home is at top of Z axis travel.  (I'll use soft limit for travel max),  2) Probe is a float switch on the torch holder, and 3) the breakaway will be part of the magnetic mount.  I am using NO mechanical switches so they could be paralleled.  

I'm looking to reduce the number of wires I have to run through my gantry to the Z axis location.   Wondering if all/any of these signals can be combined easily. 

I'm assuming this will require some HAL hand editing?  A lot?  Is this a bad idea? I do see options to utilize same input for home and limit switches in pncconf however nothing (that I've noticed) to do what I'm wanting here.

Any advice is much appreciated!   Cheers,

-dave
Last edit: 06 Nov 2022 14:59 by dlv.

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

More
06 Nov 2022 15:09 #256076 by dlv
Update, I did see this thread:  

forum.linuxcnc.org/plasma-laser/44961-thc-out-of-ideas#233435

Where it was mentioned the float switch input (automatically?) acts as a breakaway pausing the program if it trips?   If so, I must have missed that in the manual and I can certainly eliminate one wire by using that feature.   Still wondering if I can get down to one wire by combining all three and what that would involve.

Thanks!

 

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

More
06 Nov 2022 19:19 #256086 by rodw
If your only concern is to simplify wiring (eg. you have the inputs), why don't you use a multicore cable? You can common the field power so you only need 4 core cable.

It would probably be quicker to do that than muck about in hal.

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

More
06 Nov 2022 19:47 #256088 by tommylight
What wires are you using?
If you think you can get away with normal unshielded cables, think again.
It usually ends up badly.
Shielded cables are a MUST for plasma. The only ones you can get away with, maybe, are motor wires, and even those over 1-2 meters in length must be shielded.

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

More
06 Nov 2022 19:56 #256089 by rodw

What wires are you using?
If you think you can get away with normal unshielded cables, think again.
It usually ends up badly.
Shielded cables are a MUST for plasma. The only ones you can get away with, maybe, are motor wires, and even those over 1-2 meters in length must be shielded.

I agree on the shielding, but for a low current signal, you don't need motor wires. There are 4 core shielded microphone cables that can be had ror $1-$2 a metre. I used 9 core shielded on my machine and DB9 breakouts at each end. OF course for an industrial buid, high flex drag chain cable will be required.

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

More
06 Nov 2022 20:16 #256091 by tommylight
I did not say to use motor cables without shielding for signals
for motors only, drive side, never encoder side

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

More
07 Nov 2022 00:25 - 07 Nov 2022 00:36 #256104 by dlv
Tommy I'm using shielded cable for everything.  All cable shields are star terminated to earth ground in the enclosure and do NOT connect at the table end to anything.  Motor drive cables are 18ga shielded 5 core ( one core is a motor ground because I read it's good to ground your stepper motors directly also ).  Limit/Probe etc. switch cables are shielded 2 core and much lighter gauge (24 I think).  All cables are constant flex rated.  (i.e. very expensive!).  Yep, using drag chains where there is motion.

I do feel a bit silly, I found the statement on probe acting like breakaway in the config section of the docs.  Not sure how I missed that, it's pretty obvious.   

Breakaway Switch is not mandatory because Float Switch is treated the same as a breakaway when not probing. If they are two separate switches, and there are not enough inputs on the breakout board, they could be combined and connected as a Float Switch.

Rod I thought about multi pair but had already purchased the single pair stuff.  For now I'm planning to go ahead with running the second cable on the gantry for the Z axis home switch.  Just running a bit tight on cable.  If I've measured correctly I should have enough for two but probably not 3 runs to the Z axis.   That was the main reason for asking about this.  I should be ok though given that statement from the manual.
Last edit: 07 Nov 2022 00:36 by dlv.
The following user(s) said Thank You: tommylight

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

More
07 Nov 2022 00:44 #256105 by tommylight
Nice! :)
From your post i got the impression you are using single wires for sensors.
If you are pressed for wires, check the power supply if it has ground tied to 0V rail, in that case you can use the shield as 0V all over the machine leaving you one more wire for other stuff on every cable.
The following user(s) said Thank You: dlv

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

More
08 Nov 2022 09:58 #256196 by andypugh
Yes, it is perfectly possible to combine torch breakaway with probing.

At the simplest level you could just have one HAL input trigger probe and breakaway and home.
The problem there is that the probe will trigger the breakaway response, which probably isn't ideal. (Triggering home at random times is less of a problem)

One way to do this would be with the "demux" HAL component.

linuxcnc.org/docs/stable/html/man/man9/demux.9.html

That can divert the input pin to the appropriate destination pin.

Select the destination pin with motion.motion-type
linuxcnc.org/docs/stable/html/man/man9/motion.9.html

Two minor complications, the input to demux is unsigned and motion is signed so you need a conv_s32_u32 component too.
Also homing is not a motion-type. I am not sure what motion-type is during homing. If it isn't feed or traverse then there is no problem, if it is something else then you would want to use one of the demux "bit" inputs to "shift" into a different set of output pins based on the joint.NN.homing pin.
You probably also need a set of "or" components so that breakaway works in feed OR traverse and homing works in whatever modes home uses.
The following user(s) said Thank You: tommylight, dlv

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

More
08 Nov 2022 23:22 - 08 Nov 2022 23:27 #256251 by dlv
Great info Andy. I will look into the demux command.   I actually would think the probe getting triggered during a cut and acting as the breakaway would be a good thing?  I.E. if the torch rides up on a cutaway but doesn't break free, you want to stop.   That's how I interpreted the feature anyway.

FWIW I ended up trying it using a classic ladder approach.

I defined a simple N/O input in classicladder and connected it to an output and saved that to MyLadder.clp.  Then I put the following in my custom.hal file:
loadusr -w classicladder --nogui MyLadder.clp
net plasmac:float-switch-out classicladder.0.in-00
net z-home-sw classicladder.0.out-00

And it worked! 

I have no idea if this is a good solution or not.  I wanted to learn classic ladder so this gave me an excuse to poke around.   I'm still very much in the early stages of learning all this.

Thanks again to everyone for your continued advice and support.

-dave
Last edit: 08 Nov 2022 23:27 by dlv.
The following user(s) said Thank You: tommylight

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

Moderators: snowgoer540
Time to create page: 0.103 seconds
Powered by Kunena Forum