M66
18 Jan 2014 02:03 #42931
by billykid
hi
I'm trying to use the M66 for the signal arcok a small plasma that I am building.
I'm using this: net arc_ok motion.digital-in-00 <= parport.0.pin11-in
with the line P0 L4 M66 Q5 is ok but after 5 seconds without signal movement begins the same.
I tried M66 P0 L0 but it never works, maybe you can use only the options L3 or L4?
thanks in advance
Mauro
I'm trying to use the M66 for the signal arcok a small plasma that I am building.
I'm using this: net arc_ok motion.digital-in-00 <= parport.0.pin11-in
with the line P0 L4 M66 Q5 is ok but after 5 seconds without signal movement begins the same.
I tried M66 P0 L0 but it never works, maybe you can use only the options L3 or L4?
thanks in advance
Mauro
Please Log in or Create an account to join the conversation.
18 Jan 2014 05:17 - 18 Jan 2014 05:19 #42936
by Rick G
Hello,
You need to determine what it will do if there is no output, try something like...
Otherwise it waits then after the waits continues the code.
The result of the M66 is the variable #5399.
Rick G
You need to determine what it will do if there is no output, try something like...
M66 P0 L3 Q5 (wait up to 5 seconds for digital input 0 to turn on)
O105 IF [ #5399 ne 1]
M5
(debug, No arc transfer)
o106 return
O105 ENDIF
Otherwise it waits then after the waits continues the code.
The result of the M66 is the variable #5399.
Rick G
Last edit: 18 Jan 2014 05:19 by Rick G.
Please Log in or Create an account to join the conversation.
18 Jan 2014 05:22 #42937
by andypugh
If you want to end the programme if the timeout happens then maybe this will work
P0 L4 M66 Q5
O100 IF [#5399 LT 0]
(MSG, Timeout!)
M2
O100 ENDIF
That is because you have a timeout of 5 seconds.with the line P0 L4 M66 Q5 is ok but after 5 seconds without signal movement begins the same.
If you want to end the programme if the timeout happens then maybe this will work
P0 L4 M66 Q5
O100 IF [#5399 LT 0]
(MSG, Timeout!)
M2
O100 ENDIF
Please Log in or Create an account to join the conversation.
18 Jan 2014 20:57 #42970
by Rick G
Andy,
Example g codes should be consistent with good g code practices.
For example...
linuxcnc.org/docs/html/gcode/m-code.html#sec:M66-Input-Control
Rick G
Example g codes should be consistent with good g code practices.
For example...
linuxcnc.org/docs/html/gcode/m-code.html#sec:M66-Input-Control
Is a proper easy to read example.M66 Example Lines
M66 P0 L3 Q5 (wait up to 5 seconds for digital input 0 to turn on)
Certainly could be considered the slightest bit ambiguous, and possibly confuse the issue.P0 L4 M66 Q5
Rick G
Please Log in or Create an account to join the conversation.
19 Jan 2014 04:03 #42986
by billykid
Thank you, your example works fine.
I just do not get it to work with a separate sub.
for example, "call o100" in the program gcode
then in the sub:
o100 sub
M66 P0 L3 Q5
if [# 5399 LT 0]
(MSG, fail)
endif
o100 EndSub
give error:
parameter name that starts with F unknown
I just do not get it to work with a separate sub.
for example, "call o100" in the program gcode
then in the sub:
o100 sub
M66 P0 L3 Q5
if [# 5399 LT 0]
(MSG, fail)
endif
o100 EndSub
give error:
parameter name that starts with F unknown
Please Log in or Create an account to join the conversation.
Time to create page: 0.119 seconds