Hello Guest it is April 16, 2024, 04:43:27 AM

Author Topic: help for a small macro  (Read 2583 times)

0 Members and 1 Guest are viewing this topic.

Offline v tec

*
  •  31 31
    • View Profile
help for a small macro
« on: February 24, 2013, 04:35:19 AM »
hi, i m very bad for programm a macro

but i would like write a small code simple for you, hard for me...



the gcode will look at that:

m3s1000
m70
m47
m30



m70 is


wait the input1, when input1 is "on"(not stay "on", but just pulse), start m98


how i can do that?


thanks

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: help for a small macro
« Reply #1 on: February 24, 2013, 12:52:27 PM »
It is NOT a good idea to try and run a SUB from inside a MACRO  from Gcode. It could get VERY unpredictable.

Just a thought, (;-) TP

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: help for a small macro
« Reply #2 on: February 24, 2013, 02:55:07 PM »
That being said you may want to try it this way. The testsub .txt must reside in the Subroutines directory and it must contain the M99(return)

m3s1000
m70
m47
m30


'M70
Do while Not IsActive(input1)
Message"Waiting on Input"
Loop
Message""
Code" M98(testsub.txt)"
End

(;-) TP