Calling and halui mdi command generates mode error
23 Sep 2024 21:53 #310672
by RyanB
Calling and halui mdi command generates mode error was created by RyanB
Hi, I am trying to change mess around with my machines .hal file so when an M6 tool change request is generated it runs and MDI command. Every time I run it though I get the error "Can't switch mode while mode is AUTO and interpreter is not IDLE"
The net change I am making in hal is fromto
The MDI command in the INI is
My testing ngc file is
I've tried to keep things as simple as possible, but no matter what I try I keep getting this error. Could someone point me towards a solution?
The net change I am making in hal is from
net tool-change-request => hal_manualtoolchange.change
net tool-change-request => halui.mdi-command-00
The MDI command in the INI is
[HALUI]
MDI_COMMAND = G90 G00 Z10
My testing ngc file is
%
G90
T2 M6
%
I've tried to keep things as simple as possible, but no matter what I try I keep getting this error. Could someone point me towards a solution?
Please Log in or Create an account to join the conversation.
24 Sep 2024 00:41 #310675
by Benb
Replied by Benb on topic Calling and halui mdi command generates mode error
According to the manual When a halui MDI pin is set (pulsed) true, halui will send the MDI command defined in the INI. This will not always succeed depending on the current operating mode (e.g., while in AUTO halui can’t successfully send MDI commands).
reference:
linuxcnc.org/docs/stable/html/gui/halui.html#_mdi_2
reference:
linuxcnc.org/docs/stable/html/gui/halui.html#_mdi_2
Please Log in or Create an account to join the conversation.
24 Sep 2024 05:39 #310687
by Aciera
Replied by Aciera on topic Calling and halui mdi command generates mode error
It's not possible to call a [HALUI] MDI_COMMAND from Gcode. If you need to modify M6 then you would need to use a remap instead:
linuxcnc.org/docs/devel/html/remap/remap...g_the_m6_replacement
linuxcnc.org/docs/devel/html/remap/remap...g_the_m6_replacement
Please Log in or Create an account to join the conversation.
Time to create page: 0.067 seconds