Hello Guest it is April 25, 2024, 08:08:26 AM

Author Topic: More Noob Questions- output control & Homing  (Read 4530 times)

0 Members and 1 Guest are viewing this topic.

More Noob Questions- output control & Homing
« on: May 16, 2008, 11:42:22 AM »
1. I want to control my spindle and dust collector with relays. The spindle I've got figured out but the other outputs I have a question about. Will Mach control the collector (coolant) automatically or will I have to edit the code each time I load a new part with the M8 line? I found the tick box for stopping all outputs but couldn't figure out how to get auto start of coolant. I did notice when watching the diagnostics screen that if I used an M7 command there was quite a delay before the led started flashing. If I used M8 the led flashed instantly at that line of code (both are set with zero delay).

2. Can mach be configured to ref. all home at the end of the code? I've tried editting the code but can't seen to get it to work. I would like for this function to be automated if possible as well.

Thanks for the input

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: More Noob Questions- output control & Homing
« Reply #1 on: May 16, 2008, 02:25:37 PM »
That depends: Do you want coolent to start with the start of your Spindle, and it stays on as long as the spindle stays on, or, do you want G-code control like using the M7 or M8. If you want it to start with the spindle, then Use a brain, that if eighther the Spindle cw or ccw LED is on, then it will output to what ever output you want to turn on your outputs.

Yes, you can ref at the end of your G code run, Make a custom Macro that the Reference axis (x, y, z, etc.), is in the Macro.

scott
fun times
Re: More Noob Questions- output control & Homing
« Reply #2 on: May 16, 2008, 03:18:25 PM »
Thanks Pappabear.
I figured it could be done just didn't know how. Electrical power in my garage is marginal at best, so I would like there to be a delay between the spindle starting and the vac. starting to reduce the start up load on my weak electrical supply. (but yes, vac on whenever spindle is running). This is the reason for not running both from one relay. In the portion of my knowledge of brains, macro's, VB etc. there exists a vast and baron space ( I don't know diddly about em) ???

I haven't messed with brains or macro's any but I'll try to research them.

Thanks again!
Re: More Noob Questions- output control & Homing
« Reply #3 on: May 16, 2008, 03:51:35 PM »
I just watched the first training vid on brains and wrote a brain to control my chip vac. ,delay and all! Tested it in the diagnostic screen and it even works! Mach 3 ROCKS!

The Macro wasn't so easy ;D Still lost on that one.
« Last Edit: May 16, 2008, 04:12:30 PM by lowslo »

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
    • View Profile
Re: More Noob Questions- output control & Homing
« Reply #4 on: May 16, 2008, 04:44:55 PM »
I am not so good on VB but this might work if you put it in a macro and call the macro from your code. Obviously you will need to change the Output to the number you wil be using. Also you can increase or decrease the dwell by putting a different number after the P.
Hood

If GetOemLED (11)Then
Code "G4 P5"
While IsMoving
Wend
Activatesignal (OutPut2)
Else
DeActivateSignal (OutPut2)
End If

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
    • View Profile
Re: More Noob Questions- output control & Homing
« Reply #5 on: May 16, 2008, 04:59:55 PM »
Just thinking, if you were wanting to run it from code with a macro you wouldnt be caring if the spindle is on or not and probably wouldnt want a dwell, so what you would want to do is have it look at your OutPut LED for your Vac, so it would be like this.

If GetOemLED (853)Then
DeActivateSignal (OutPut2)
Else
Activatesignal (OutPut2)
End If


That is for OutPut2, you would need to change  the LED number for whichever output you are using

Hood

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
    • View Profile
Re: More Noob Questions- output control & Homing
« Reply #6 on: May 16, 2008, 05:26:21 PM »
Just been thinking again LOL
 If you use something to Generate code for you then you will probably have  M8 and M9 entered in the code automatically so all you would need to do is make a M8 macro and put

ActivateSignal (OutPut2)

and make a M9 Macro with

DeactivateSignal(OutPut2)

Then when M8 was called the vac would start, M9 it would stop.

Hood