Welcome, Guest. Please login or register.
Did you miss your activation email?
May 28, 2012, 11:26:47 AM

Login with username, password and session length
Search:     Advanced search
* Home Help Search Calendar Links Login Register
+  Machsupport Forum
|-+  Mach Discussion
| |-+  Brains Development
| | |-+  Brain and G code?
Pages: 1   Go Down
Print
Author Topic: Brain and G code?  (Read 1773 times)
0 Members and 1 Guest are viewing this topic.
DennisCNC
Active Member

Offline Offline

Posts: 200


View Profile
« on: January 25, 2008, 10:10:57 PM »

I need to put the Z axis at "g53 g0 z0"  How is that done with a brain?  Do I need to make a button and attach a VB script saying:  code "g53g0z0" and have the brain activate the button?


Thanks
Logged
poppabear
S S SYSTEMS, LLC
Global Moderator
*
Offline Offline

Posts: 1,707


Briceville, TN, USA


View Profile WWW
« Reply #1 on: January 26, 2008, 11:09:16 PM »

Take what ever trigger input your using to trigger the G53 event in the Brain. Like an input or what ever.
do a no-op lobe. Send the termination to UserLED1500 (or what ever).
Then in the Macro Pump Put a If then statement. And make a custom Macro called M53
I.e.

'MacroPump

i=GetOEMDRO(2000) 'interlock counter


If GetUserLED(1500) and i=0 then 'interlock statement
Code "M53"
SetUserLED(1500,0) 'this will turn off the Brain LED even if the trigger is still on.
End If

******************************************************************
******************************************************************

'M53.m1s  this is the G53 macro
Code "G53 g0 z0"
While IsMoving
Wend
SetUserDRO(2000,0) 'Resets the interlock DRO in the macro pump

'Scott
Logged

Commercial Mach3: Screens (regular and flash), Wizards, Plug-ins, Brains, PLCs, Macros, ATC's, machine build, retrofit and Prototyping
http://sites.google.com/site/volunteerfablab/
Pages: 1   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!