Aux. Spindle button linked to axis spindle
11 Mar 2013 22:58 #31237
by creed
Aux. Spindle button linked to axis spindle was created by creed
I have linked spindle-on to parport pin 9. When machine/drives under power spindle works correct (F9, pointer, M3/M4/M5). Power off and/or E-stop stops spindle as it should.
The problem is, this is a B'port knee mill & occasionally it needs to be used as a manual mill for certain machine operation. I need to turn spindle on while machine is in an off state & I can manual move the axis of the machine manually.
My thought were VCP
So far I have a VCP file that work in axis (both powered & un-powered) & have been able to linked it to parport pin 8. I get error when trying to assign it to same pin as spindle-on (parport pin 9). In the end I need this to be linked to parport pin 9.
Any suggestions or sample VCP and Hal file would be appreciated.
The problem is, this is a B'port knee mill & occasionally it needs to be used as a manual mill for certain machine operation. I need to turn spindle on while machine is in an off state & I can manual move the axis of the machine manually.
My thought were VCP
So far I have a VCP file that work in axis (both powered & un-powered) & have been able to linked it to parport pin 8. I get error when trying to assign it to same pin as spindle-on (parport pin 9). In the end I need this to be linked to parport pin 9.
Any suggestions or sample VCP and Hal file would be appreciated.
Please Log in or Create an account to join the conversation.
11 Mar 2013 23:32 #31238
by ArcEye
Replied by ArcEye on topic Aux. Spindle button linked to axis spindle
Hi
One of those questions, with about as many answers as there are people to reply.
Basically you need to unlink your parport pin to use it with something else.
linuxcnc.org/docs/2.5/html/hal/basic_hal.html#_unlinkp
Exactly how you do it is another matter.
Dead easy, you could just start a different config when using the mill manually.
You could have a button that switches to 'Manual mode' by calling a script which unlinks and nets to the correct signal.
When released it could revert the connections.
Probably best to find how to do what you want using halcmd and unlinking / linking manually, then decide what is best for you in automating it
regards
One of those questions, with about as many answers as there are people to reply.
Basically you need to unlink your parport pin to use it with something else.
linuxcnc.org/docs/2.5/html/hal/basic_hal.html#_unlinkp
Exactly how you do it is another matter.
Dead easy, you could just start a different config when using the mill manually.
You could have a button that switches to 'Manual mode' by calling a script which unlinks and nets to the correct signal.
When released it could revert the connections.
Probably best to find how to do what you want using halcmd and unlinking / linking manually, then decide what is best for you in automating it
regards
Please Log in or Create an account to join the conversation.
11 Mar 2013 23:34 #31239
by BigJohnT
Replied by BigJohnT on topic Aux. Spindle button linked to axis spindle
Please Log in or Create an account to join the conversation.
14 Mar 2013 18:38 #31398
by creed
Replied by creed on topic Aux. Spindle button linked to axis spindle
I would like to explore the calling a script thought. Is this done in
postgui ?
postgui ?
Please Log in or Create an account to join the conversation.
14 Mar 2013 19:49 #31402
by ArcEye
Only partly.
You need to write a script that will do what you want and test it from the MDI line in Axis
linuxcnc.org/docs/2.5/html/gcode/m-code.html#sec:M100-to-M199
Then call that script via halui in your ini file
linuxcnc.org/docs/2.5/html/config/ini_co..._sub_halui_section_a
Then link your pyVCP button to the halui.mdi-command in the post_gui.hal file
linuxcnc.org/docs/2.5/html/hal/pyvcp.html
regards
Replied by ArcEye on topic Aux. Spindle button linked to axis spindle
I would like to explore the calling a script thought. Is this done in
postgui ?
Only partly.
You need to write a script that will do what you want and test it from the MDI line in Axis
linuxcnc.org/docs/2.5/html/gcode/m-code.html#sec:M100-to-M199
Then call that script via halui in your ini file
linuxcnc.org/docs/2.5/html/config/ini_co..._sub_halui_section_a
Then link your pyVCP button to the halui.mdi-command in the post_gui.hal file
linuxcnc.org/docs/2.5/html/hal/pyvcp.html
regards
Please Log in or Create an account to join the conversation.
15 Mar 2013 00:18 #31417
by andypugh
Is the issue that you want to be able to turn on the parallel port pin without starting up LinuxCNC, or that you want to be able to spindle-on without powering up the steppers/servos?
The first option is easy from the command line:
halrun
loadrt hal_parport (your usual confg string here)
setp parport.0.pin-09-out 1
You could wrap this up in a bash script and make an icon if you want.
If you want to be able to run the spindle with linuxcnc loaded but off, you need to use an "OR2" hal component, and link one input to the spindle-on, the output to the parport, and then link a button to the other input of the OR2.
However, I can't help thinking that a physical button might be the way to go. Then you don't even need to boot the PC. Or is the idea to use LinuxCNC as a DRO?
Replied by andypugh on topic Aux. Spindle button linked to axis spindle
I have linked spindle-on to parport pin 9.
I need to turn spindle on while machine is in an off state
Is the issue that you want to be able to turn on the parallel port pin without starting up LinuxCNC, or that you want to be able to spindle-on without powering up the steppers/servos?
The first option is easy from the command line:
halrun
loadrt hal_parport (your usual confg string here)
setp parport.0.pin-09-out 1
You could wrap this up in a bash script and make an icon if you want.
If you want to be able to run the spindle with linuxcnc loaded but off, you need to use an "OR2" hal component, and link one input to the spindle-on, the output to the parport, and then link a button to the other input of the OR2.
However, I can't help thinking that a physical button might be the way to go. Then you don't even need to boot the PC. Or is the idea to use LinuxCNC as a DRO?
Please Log in or Create an account to join the conversation.
15 Mar 2013 00:52 #31423
by creed
Replied by creed on topic Aux. Spindle button linked to axis spindle
andypugh,
goal is able to run the spindle with linuxcnc loaded but steppers off. The option i know i can do is second set of config files (have to remeber to ubdate both sets of files when mofified) & the physical pin.
The gaol is to jog mahine near work piece then power off (into manaual mode) & turn spindle on to cut a sinple key vs. righting G code or use jog at a ? feed rate (one day i will for get to adjust feed overire & crash part).
Most of my work is repairing customers parts. crashing is not good when it not my materail.
thanks
goal is able to run the spindle with linuxcnc loaded but steppers off. The option i know i can do is second set of config files (have to remeber to ubdate both sets of files when mofified) & the physical pin.
The gaol is to jog mahine near work piece then power off (into manaual mode) & turn spindle on to cut a sinple key vs. righting G code or use jog at a ? feed rate (one day i will for get to adjust feed overire & crash part).
Most of my work is repairing customers parts. crashing is not good when it not my materail.
thanks
Please Log in or Create an account to join the conversation.
15 Mar 2013 02:23 #31429
by andypugh
I do that sort of thing in MDI mode. Have you tried that?
Instead of twirling a handle, open the MDI tab and type G1 F10 X-100 to cut your keyway. You even get to make a cup of tea that way.
Replied by andypugh on topic Aux. Spindle button linked to axis spindle
The gaol is to jog mahine near work piece then power off (into manaual mode) & turn spindle on to cut a sinple key vs. righting G code or use jog at a ? feed rate (one day i will for get to adjust feed overire & crash part).
I do that sort of thing in MDI mode. Have you tried that?
Instead of twirling a handle, open the MDI tab and type G1 F10 X-100 to cut your keyway. You even get to make a cup of tea that way.
Please Log in or Create an account to join the conversation.
Time to create page: 0.085 seconds