Hello Guest it is March 29, 2024, 04:50:49 AM

Author Topic: M06 not working  (Read 11472 times)

0 Members and 1 Guest are viewing this topic.

Offline dude1

*
  •  1,253 1,253
    • View Profile
Re: M06 not working
« Reply #20 on: January 21, 2016, 04:31:53 PM »
C:\Mach4Hobby\Profiles\Mach4Mill\Macros
Re: M06 not working
« Reply #21 on: January 21, 2016, 08:38:08 PM »
I need to provide more information, I noted you referenced  C:\Mach4Hobby\Profiles\Mach4Mill\Macros     if I use MACH4MILL profile on a DEMO of MACH4 the M06 sinipit works as it should.
 I am using a PMDX-410  and the setup files for the profile VER. 0.33.159  running on the latest version of MACH4    when I run code containing  M06 it continues over the code and does not pause for the tool change. I am going to post on  PMDX  or maybe Steve Stallings will see this here. I will give things a chance to shake out an answer.  I also used profile  MACH4_6axis the code worked with it also.

G0G90G54G17G40G49G80
G0X4.0Y0.0Z1.0T1
M6
G0X10.0Y-5.0Z1.0
T2M6
M30

Thanks    AA1PI
Re: M06 not working
« Reply #22 on: January 22, 2016, 12:05:19 AM »
If you are using a profile based on the PMDX-Sample profile that is (optionally) installed with the PMDX-SmartBOB plug-in, then the M6 macro is not there (an oversight on my part).  You can copy the m6.mcs file from:

     C:\Mach4Hobby\Profiles\Mach4Mill\Macros\m6.mcs

into the "Macros" sub-directory in your current profile.  For example, if you are using the PMDX-Sample, copy it to:

     C:\Mach4Hobby\Profiles\PMDX-Sample\Macros\m6.mcs

You may optionally also copy the "m6.mcc" file.  But if you don't, Mach4 will create it the next time it runs.  The "mcc" file is the compiled version of the "mcs" file.

CAUTION: **IF** you are using the PMDX-Sample profile, please copy it to a new profile name.  A future version of our installer *MAY* overwrite that directory (though we will always give you a warning before we do it).  To copy the profile, start the Mach4 loader, click once on the PMDX-Sample then click on the "Copy Profile" button.  Give it a new name.  You can leave the "Screen Set" field blank and it will keep the existing screen set.
Re: M06 not working
« Reply #23 on: January 22, 2016, 10:16:13 AM »
Thanks Bob,
   I had a renamed copy already so I did a copy and paste of the M6 files to the macro dir,
and tested it, works as it should.
    I hope this thread will help others.      M06 success    PMDX- 410   a few words for the search engine

     Many thanks to all      Bob,     AA1PI
Re: M06 not working
« Reply #24 on: January 30, 2016, 08:13:13 PM »
Note that the official Lua Scripting manual does contains errors related to the name of the M6() function. In the manual, section 5.4 (page 22-23) , its shown that the tool change Macro can be customized using the m6() function. This is INCORRECT because Lua is has case sensitive functions. You need to use the M6 function name (uppercase).

It's really unfortunate that the official manuals still contains errors.
Re: M06 not working
« Reply #25 on: January 30, 2016, 09:21:24 PM »
Note that the official Lua Scripting manual does contains errors related to the name of the M6() function. In the manual, section 5.4 (page 22-23) , its shown that the tool change Macro can be customized using the m6() function. This is INCORRECT because Lua is has case sensitive functions. You need to use the M6 function name (uppercase).

It's really unfortunate that the official manuals still contains errors.
I know that others have had issues with upper/lower case.  However, when I copy the stock m6.mcs file from the Mach4Mill profile, which has both the file name and the macro function name defined in lower case "m6", into my SmartBOB test profile, it works.  At least with MDI code.  With either "m6" or "M6" in the MDI window.

Perhaps I've got to go back and find/read the thread that talked about case sensitivity.

Bob
Re: M06 not working
« Reply #26 on: December 07, 2021, 08:21:13 AM »
Note that the official Lua Scripting manual does contains errors related to the name of the M6() function. In the manual, section 5.4 (page 22-23) , its shown that the tool change Macro can be customized using the m6() function. This is INCORRECT because Lua is has case sensitive functions. You need to use the M6 function name (uppercase).

It's really unfortunate that the official manuals still contains errors.
I know that others have had issues with upper/lower case.  However, when I copy the stock m6.mcs file from the Mach4Mill profile, which has both the file name and the macro function name defined in lower case "m6", into my SmartBOB test profile, it works.  At least with MDI code.  With either "m6" or "M6" in the MDI window.

Perhaps I've got to go back and find/read the thread that talked about case sensitivity.

Bob
I had this error C:\Mach4Hobby\Profiles\Mach4Lathe\Macros\m6.mcc could not be found , after i changed from m6 to M6 the error disappeared