G-Code, CAD, and CAM > G-Code, CAD, and CAM discussions

What is a Macro? and what can it do for me?

(1/5) > >>

Apples:
What is a Macro?  and what can it fo for me?

I'm thinking a macro is a pre saved snipped of code that is entered into the standard g code where ever you need
it so that you only type in the one line instead of heaps of lines of code every time you need to do the same command.

Is this correct?  or am I off with the fairy's?

Peter

Graham Waterworth:
You are sort of there, what you are talking about is a g-code sub program, a macro is a block of visual basic code that is called with an M code and a list of variables that can be changed on the fly. The macro in effect writes the g-code to do the function.  Macros can also be used to configure/drive machine functions, tool changers etc.

Graham

Apples:
Hmm,  okay I'll tell you what I'm thinking of doing and maybe you can point me in the right direction.


So imagine a 3 axis machine.  Then on the bottom/ underside of the z there is another axis a,b or c?  For tangential knife function.
Then under that is another axis a,b or c?  I don't know which axis  is which.  anyway.

The two axis underneath the z will just need to be used as, I think they call it just as "indexers"

1.  So I want to move machine to start position. 
2.  Then move tangential axis (a) (rotate to say 90deg.)
3.. Then move other axis (b) (say 90deg. as well)
  This above part is what I want maybe make into a macro or as you called it a sub program.

4.  Then when the tool is in that position move to next position.
5.  Maybe have to change angles of a and b axis to something else then move on agian etc.

So the part I want to not have to keep punching into g-code will be that a,b axis (index) tool position.
This might be like a tool change macro?

Also those a,b angle adjustments will be different.  There might be 3 or 4 diffent combitnations or,
a,b axis moves to do.

Do you understand?

Peter
Australia

Graham Waterworth:
Yes and no.

What is the difference between typing A90. and M590 ?

You will save nothing.

Graham

machininginc:
Where are the macros on mach 3 software  and can they be changed, I have a demo version so maybe not ? (not sure) I wanna set it up to use H#148 for a tool height & D#148 for the dia

Navigation

[0] Message Index

[#] Next page

Go to full version