Macro parameters not initialized
- Raban
- Offline
- Junior Member
-
Less
More
- Posts: 24
- Thank you received: 1
12 Nov 2021 10:11 #226208
by Raban
Macro parameters not initialized was created by Raban
This is my macro
O<tasca_tonda> sub
G17
G21
G54
G61
G40
G49
G80
G90
;#1 = <X-pos>
;#2 = <Y-pos>
;#3 = <Z-pos>
(X = #1 Y = #2 Z = #3)
G0 Z #3
G0 X #1 Y #2
O<tasca_tonda> endsub
M2
I have a button on gmoccapy interface and the button work , but the macro move to G0 x=0 y=0 z=0 .
Gmoccapy not ask me X-Pos Y-Pos and Z-pos
O<tasca_tonda> sub
G17
G21
G54
G61
G40
G49
G80
G90
;#1 = <X-pos>
;#2 = <Y-pos>
;#3 = <Z-pos>
(X = #1 Y = #2 Z = #3)
G0 Z #3
G0 X #1 Y #2
O<tasca_tonda> endsub
M2
I have a button on gmoccapy interface and the button work , but the macro move to G0 x=0 y=0 z=0 .
Gmoccapy not ask me X-Pos Y-Pos and Z-pos
Please Log in or Create an account to join the conversation.
- MaHa
- Offline
- Platinum Member
-
Less
More
- Posts: 415
- Thank you received: 172
12 Nov 2021 10:22 #226210
by MaHa
Replied by MaHa on topic Macro parameters not initialized
A named parameter looks like that: #<X-pos> , or global #<_X-pos>
After using G61 in your macro, you need to set G64 P Q again, in case you want to machine a contour. Maybe for a straight move don't even need G61.
After using G61 in your macro, you need to set G64 P Q again, in case you want to machine a contour. Maybe for a straight move don't even need G61.
Please Log in or Create an account to join the conversation.
- Raban
- Offline
- Junior Member
-
Less
More
- Posts: 24
- Thank you received: 1
12 Nov 2021 10:37 #226211
by Raban
Replied by Raban on topic Macro parameters not initialized
with or without g61 nothing change , gmocappy do not ask me variables value
Please Log in or Create an account to join the conversation.
- Raban
- Offline
- Junior Member
-
Less
More
- Posts: 24
- Thank you received: 1
12 Nov 2021 10:46 #226212
by Raban
Replied by Raban on topic Macro parameters not initialized
Solved , in ini files macro must be declared with variables also
The following user(s) said Thank You: tommylight
Please Log in or Create an account to join the conversation.
Moderators: newbynobi, HansU
Time to create page: 0.106 seconds