开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

Macros


John Prentice
 

Hi All

I am trying to improve the macro section in the Manual and must share a bug in the manual and a feature in Mach2 with you.

My "bug" is in the definition of the Param3() function in Appendix 5. Param3() actually gets the value of the S word in a macro call e.g. if macro M55 contains a VB Script line "valu = Param3()" and the macro is called in a part program by "M55 S3000" then variable "valu"will be set to 3000. The manual (Rev A1) says it is the L word that corresponds to Param3.

The "feature" is that the S word is checked against the current pulley setting by Mach2 before it is passed to the macro. If it is too high or too low then it is not passed. You need to beware and only use this word to pass a valid spindle speed to a macro. P & Q will pass any value.

I hope the next version of the manual will have some helpful macro examples in it.

Best wishes

John Prentice

Join [email protected] to automatically receive all group messages.