Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: fixittt on September 13, 2021, 11:03:03 AM

Title: Mach3 outputs and inputs for loader robot
Post by: fixittt on September 13, 2021, 11:03:03 AM
I have a guy asking me how a parts loading robot could be used with Mach3.
The idea is that an output is triggered when the part it done to trigger the robots routine.  When it is done unloading a loading a new part, they need an input trigger to have mach3 rerun the Gcode.

Does anybody have an idea how to make this happen?  This is outside of my wheelhouse.  So I am looking for suggestions.
Title: Re: Mach3 outputs and inputs for loader robot
Post by: Graham Waterworth on September 13, 2021, 05:11:42 PM
You can create some M codes to turn on and output and then wait for the input etc.

Title: Re: Mach3 outputs and inputs for loader robot
Post by: fixittt on September 22, 2021, 12:26:20 PM
lets pretend that I am an idiot.   What would an example of something like this look like?
Title: Re: Mach3 outputs and inputs for loader robot
Post by: Graham Waterworth on September 23, 2021, 08:05:02 AM
This could be the end of your main program:-

G00 X250. Z250.
M1025 (call robot)
M1026 (do op2)
M1027 (do op3)
Etc
M30

The macro could look like this and be stored in the macro folder for the profile in use.

M1025.m1s
Activatesignal(OUTPUT1)
' Wait for ack
While (Not IsActive(INPUT1))
  Sleep(15)
Wend
end

You then set up more macros to do the operation.

Title: Re: Mach3 outputs and inputs for loader robot
Post by: fixittt on September 24, 2021, 10:36:53 AM
Graham,

Thank you sir for your time and knowledge.

I am going to see if I can get something mocked up and trigger outputs.

Again, thank you.  This is for a client of mine and I have never had to do something like this before.