Hurco TC Brains

All things related to Centroid Oak, Allin1DC, MPU11 and Legacy products

Moderator: cnckeith

please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Hurco TC Brains

Post by please no smoke »

Scott/ All. My machine has a tool changer that I am not using but this also means that It has a motorized draw bar. I need to write a brain to control this. I am attaching roughly what I think I need but am not sure how to start (how to read an M6 for example). Can you let me know if this is close, and help fill in the blanks?

Thanks

Matt
Attachments
Picture Brain.tif
diycncscott

Re: Hurco TC Brains

Post by diycncscott »

Hi Matt,

Please post images in .gif, .jpg or .pdf format -otherwise the thumbnails don't display in the post (just a red x)

It looks pretty good. A couple of things:

1. You will want to interlock the unclamp operation with the spindle to prevent unclamping while the spindle is running
2. You probably want the manual tool release (Input #11 unclamp) to be 'OR'd' not 'AND'd' with the Auto release
3. You can probably save yourself an input or two and get rid of Input #9 (& Input #7?). Just command a Z move(s) at the start of the M6 and wait for it to complete. A commanded move (G53) to an absolute position will be far faster more accurate then "hunting" for a switch(es)
4. I assume the clutch relay (Out#16) engages the drawbar. What keeps the spindle stationary while the Drawbar is engaged?

Scott
please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Re: Hurco TC Brains

Post by please no smoke »

The motor runs then the clutch engages. There is a spindle brake that I was thinking this morning needs to be in there. Commanding the Z is a good idea, it would save me an input. How do I do it?

How do I say on M6, I mean I don't see that as an option in brains?? I am also not sure about the inputs. Is IN #1 the same as IN #1 on the board? It seems like when I go to ports and pins It tells me that I have to use IN 1-6 for some things, and I can only choose a couple on the next page say 13-15. I am a little confused on this. What is and how do I call a modbus input?? Do I need to. I have read the manual but I am only 50% there.
please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Re: Hurco TC Brains

Post by please no smoke »

If you have time tomorrow I bet it wouldn't take long 530-864-6093
please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Re: Hurco TC Brains

Post by please no smoke »

I am figuring the brains thing out a little but you should write a brain manual. There is a bit of info out there but it is spread around and more is needed.

I am finally seeing that brains run the show for the mach based kit and that the ports and pins screens are only partially used. I figured out the M6 call. I just used led 806=1 to initiate my brain on toll change. You suggested that I send the z to a position instead of tying up and input with a x home switch. Any idea how i do this from brains cause I can' t figure it out.????

Thanks
ajaxaaron
Posts: 5
Joined: Mon May 03, 2010 1:39 pm

Re: Hurco TC Brains

Post by ajaxaaron »

Hi Matt,

To command a Z movement on M6, you should probably edit the macros (rather than the brains). Go to Operator --> VB Script Editor, then File --> Open File, then select M6Start.m1s or M6End.m1s (which are located within the Mach3/macros/Mach3Mill directory). You'll probably want to edit both...

Adding a Code() command will allow you to execute G code from within the macro. The below examples may work for you, but they probably have problems (unit conversions, offsets, feedrate, etc). They are intended to help you get started, not as a definitive solution.

Be careful!Image

M6Start.m1s...

Code: Select all

zmachinedesired = 15
zdro = GetParam("ZDRO")
zmachine = GetParam("ZMachine")
zdrodesired = (zmachinedesired - zmachine) + zdro
Code("G1 F20 Z" & zdrodesired)
tool = GetSelectedTool()
SetCurrentTool( tool )  
M6End.m1s...

Code: Select all

x = GetToolChangeStart(0)
y = GetToolChangeStart(1)
z = GetToolChangeStart(2)
Code("G0 X" & x & " Y" & y)
Code("G0 Z" & z)

Good luck,
-Aaron
please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Re: Hurco TC Brains

Post by please no smoke »

Thanks

I will try and take a better look at these. My other thought was, since I have a z-home switch. I think I can home z thru mach????
Centroid_Tech
Posts: 286
Joined: Thu Mar 18, 2010 2:24 pm

Re: Hurco TC Brains

Post by Centroid_Tech »

Please no smoke,

That is correct. You can home the machine using the Mach software by issuing an M92 command.

M92 Pxy Quv Rst
x, u, and s states the direction you will be homing - 0 for positive, 1 for negative.
y, v, and t states which axis you will be homing.

Examples:
M92 P1
Moves the 1st axis in the positive direction until the 1st_axis_+_limit is tripped and then it backs up until it sees the encoder's index pulse.
M92 P13
Moves the 3rd axis in the negative direction until the 3rd_axis_-_limit is tripped and then it backs up until it sees the encoder's index pulse.
M92 P1 Q2 R3
Moves all three axes simultaneously until the 1st_axis_+_limit is tripped, then the 2nd_axis_+_limit is tripped, then the 3rd_axis_+_limit is tripped. Then it backs up the 1st axis until its encoder's index pulse, then the same thing for the 2nd and 3rd axes.
When requesting support, please ALWAYS post a current report. Find out how to take a report from your Acorn, CNC11 or CNC10 system here: https://www.youtube.com/watch?v=Ecvg0VJp1oQ.

If your question is PLC, Macro or program related, please also post a copy of the program or macro as well.

Without the above information we may not be able to help and/or reply until the required information is posted..
please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Re: Hurco TC Brains

Post by please no smoke »

Is that a "Send String" or "Modbus" output??????????

Thanks
please no smoke
Posts: 103
Joined: Mon Mar 29, 2010 10:17 pm

Re: Hurco TC Brains

Post by please no smoke »

I used the mach command for the M92. Does this brain look like it will work?

On the TC led the z is sent to zero.
If spindle is on, tc motor can't run FWD
If spindle is on, tc motor can't run REV
On tc wait led and z homed DRO (will this work?) and clamp input motor will run FWD
On tc wait led and z homed DRO (will this work?) and unclamp input motor will run REV
If motor runs in either direction clutch will engage
If input 12 PROX goes high clutch will disengage
Attachments
Tool Change.JPG
Post Reply