- Posts: 27
- Thank you received: 114
M66
- Rick G
- Offline
- Junior Member
-
Less
More
12 years 9 months ago #42970
by Rick G
Replied by Rick G on topic M66
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.
- billykid
- Offline
- Platinum Member
-
Less
More
- Posts: 488
- Thank you received: 83
12 years 9 months ago #42986
by billykid
Replied by billykid on topic M66
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.
- andypugh
- Offline
- Moderator
-
Less
More
- Posts: 19899
- Thank you received: 4655
12 years 9 months ago #42987
by andypugh
Replied by andypugh on topic M66
You need O-numbers for the IF too.
Code:
o100 sub
M66 P0 L3 Q5
O20 if [# 5399 LT 0]
(MSG, fail)
O20 endif
o100 EndSub
The following user(s) said Thank You: billykid
Please Log in or Create an account to join the conversation.
- billykid
- Offline
- Platinum Member
-
Less
More
- Posts: 488
- Thank you received: 83
12 years 9 months ago #42991
by billykid
Replied by billykid on topic M66
All ok thanks !!
Please Log in or Create an account to join the conversation.
Time to create page: 0.646 seconds