Was messing with something else for myself and thought about this post. The macro I posted earlier wouldnt work properly, code wouldnt wait until it was finished but this should work, the trigger for the macro doing what you want would be the Cycle Start Led, also the sleep dropped my CPU % from 40% down to 0-1%. (I thought the sleeps were automatic now but not in the version I am using iot would seem)
If GetOemLED(804) Then
Do
ActivateSignal (OutPut1)
If IsActive (Input1) Then Exit Do
Sleep 10
Loop
DeActivateSignal(OutPut1)
Code "G91G0A60"
While IsMoving()
Wend
Code"G90"
End If
Hood
Hood, is this the only code/macro I need to run for the following process?
1. Axis A at 0, robot starts to lase part 1.
2. Robot finishes lasing part 1, moves to Clear Position, send input to Mach3 to move axis A 60 degrees.
3. When at 60 degrees, Mach3 sends input to robot Move Complete
4. Robot starts to lase part 2.
5. Robot finishes lasing part 2, moves to Clear Position, send input to Mach3 to move axis A 60 degrees (now 120 degrees from 0) to position3.
Steps 3, 4 and 5 are repeated 3 more times to Part 4 (180 degrees from 0), Part 5 (240 degrees), part 6 (300 degrees).
The robot will stop at the end of part 6, and the A axis will be returned to 0 for the next batch.
Ideally all I want the Mach3 to do is move to a position and sit idol waiting for the input to go to the next position. I dont mind writing a small macro to wait for the input, and then use code to send it to the next position.
Barry.