Hello Guest it is March 28, 2024, 04:51:24 PM

Author Topic: Spindle clamp unclamp  (Read 7140 times)

0 Members and 1 Guest are viewing this topic.

Offline CJEls

*
  •  69 69
    • View Profile
Spindle clamp unclamp
« on: March 17, 2009, 03:10:04 AM »
Hi All

Is it possible to write a brain that will latch when pressing a button to open the chuck on a lathe and stay open. You will have to interlock it with the spindle so you can not open it while the spindle is turning. When pressing the button again it should close the chuck again.






Thanks
CJ

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Spindle clamp unclamp
« Reply #1 on: March 22, 2009, 11:20:22 AM »
Yes you can, but it is a pain in the butt, the Latching is "Broken" in Brains.........

so you can do that in macro pump instead. User INPUT4 and OUTPUT4 and UserDRO 2000

I.e.

'macropump.m1s

If Not(GetOEMLED(164)) and Not(GetOEMLED(165)) and IsActive(INPUT4) and (GetUserDRO(2000) = 0) then
ActivateSignal(OUTPUT4)
SetUserDRO(2000,1)
end if

If Not(GetOEMLED(164)) and Not(GetOEMLED(165)) and IsActive(INPUT4) and (GetUserDRO(2000) = 1) then
DeActivateSignal(OUTPUT4)
SetUserDRO(2000,0)
end if

'scott


fun times

Offline CJEls

*
  •  69 69
    • View Profile
Re: Spindle clamp unclamp
« Reply #2 on: March 23, 2009, 03:46:36 PM »
Hallo Scott

Thank you for the reply. I do have a question or 2.
What is getoemled(164 ) and 165 ,is it cw and ccw led some were on the screens and is user dro2000 created by you also on a page I do not understand where you got these from because I tried to look with screen 4 but could not fine it on the1024 iset for a lathe or is this on one off your lathe screens

thank you
CJE

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Spindle clamp unclamp
« Reply #3 on: March 23, 2009, 05:49:23 PM »
leds 164 and 165 are the CW and CCW spindle running LEDs, Udro 2000 is just a random dro i picked in a high range to make sure it
does not interfere with any of your wizard ranges....

In mach Even if LEDs and DROs DONT exist on the screen, they are still there, they are there all the time.
So when you go spindle CW LED 164 will Be ON weather it is on your screen or not........

so, tell me how the macro works for you.

scott
fun times

Offline CJEls

*
  •  69 69
    • View Profile
Re: Spindle clamp unclamp
« Reply #4 on: March 24, 2009, 01:05:25 PM »
Hallo Scott

i tried running the Macro but it does not work on my set up.Then openning the macro and stepping into it the output wil only switch on and off.  I did enable the mmacro pump in the gen config and restarted the system. Any other advise.

CJE
« Last Edit: March 24, 2009, 02:36:11 PM by CJEls »

Offline CJEls

*
  •  69 69
    • View Profile
Re: Spindle clamp unclamp
« Reply #5 on: March 24, 2009, 01:21:18 PM »
Hallo Scott

Is There any way off checking the macropump when the machine is on to see if it is running.I did a stupid macropump If input4 is on then switch output 4 on. That works fine as a macropump so I Know it is working.

CJE 
« Last Edit: March 25, 2009, 02:26:37 AM by CJEls »