Remap M61 doesnt work

  • zz912
  • zz912's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
More
03 Sep 2024 15:12 #309294 by zz912
Remap M61 doesnt work was created by zz912
Hello,

I work on AUTOMATIC_G43 by remap. I use master branche (2.10) RIP instalation.

I added in INI file:
# Task controller section -----------------------------------------------------
[RS274NGC]
...............
SUBROUTINE_PATH = ./macros
REMAP=M6  modalgroup=6 prolog=change_prolog ngc=change_g43 epilog=change_epilog
REMAP=M61  modalgroup=6 prolog=settool_prolog ngc=settool_g43 epilog=settool_epilog

# the Python plugins serves interpreter and task
[PYTHON]
PATH_PREPEND = ./python
TOPLEVEL = ./python/toplevel.py
LOG_LEVEL = 8
 

File Attachment:

File Name: python_2024-09-03.zip
File Size:10 KB

 

File Attachment:

File Name: macros_2024-09-03.zip
File Size:1 KB

o<change_g43> sub
;(debug, in change tool_in_spindle=#<tool_in_spindle> current_pocket=#<current_pocket>;)
;(debug, selected_tool=#<selected_tool> selected_pocket=#<selected_pocket>;)

; we must execute this only in the milltask interpreter
; or preview will break, so test for '#<_task>' which is 1 for
; the milltask interpreter and 0 in the UI's
O100 if [#<_task> EQ 0]
        (debug, Task ist Null)
O100     return [999]
O100 endif

; using the code being remapped here means 'use builtin behaviour'
M6

; set tool offset
G43

; signal success be returning a value > 0:
o<change_g43> endsub [1]
M2

o<settool_g43> sub
;(debug, tool=#<tool> pocket=#<pocket>;)

; we must execute this only in the milltask interpreter
; or preview will break, so test for '#<_task>' which is 1 for
; the milltask interpreter and 0 in the UI's
O100 if [#<_task> EQ 0]
        (debug, Task ist Null)
O100     return [999]
O100 endif

; using the code being remapped here means 'use builtin behaviour'
M61

; set tool offset
G43

; signal success be returning a value > 0:
o<settool_g43> endsub [1]
M2

Remaps M6 works as I need but remap M61 doesnt.
 
I tested it in Gmoccapy and in AXIS.

Can anyone guess where the error might be?
Attachments:

Please Log in or Create an account to join the conversation.

More
03 Sep 2024 15:50 #309295 by Aciera
Replied by Aciera on topic Remap M61 doesnt work
in your 'settool_G43' sub you have this:
; using the code being remapped here means 'use builtin behaviour'
M61
Seems to me that you are missing the required 'Q' word here.
The following user(s) said Thank You: zz912

Please Log in or Create an account to join the conversation.

  • zz912
  • zz912's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
More
03 Sep 2024 16:09 #309296 by zz912
Replied by zz912 on topic Remap M61 doesnt work
I did not find example of right use M61.

I use remap with M6 and I dont need 'T' word.

Here is definition for minimal M6/M61/T/S/F
linuxcnc.org/docs/devel/html/remap/remap...cluding_code_m6_code

Please Log in or Create an account to join the conversation.

  • zz912
  • zz912's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
More
03 Sep 2024 16:13 #309297 by zz912

Please Log in or Create an account to join the conversation.

Time to create page: 0.062 seconds
Powered by Kunena Forum