C-863.12 Mercury Controller MS249E Version: 1.2.1 101
− If you are working in PIMikroMove on the Controller macros tab: Click the Create
new empty macro icon to create a tab for entering a new macro. Do not enter the
MAC BEG macroname command.
2. Enter the commands to be included in the macro name macro line by line, using the
normal command syntax.
Macros can call up themselves or other macros in several nesting levels.
3. End the macro recording.
− If you are working with PITerminal or in the Command entry window of
PIMikroMove: Send the MAC END command.
− If you are working in PIMikroMove on the Controller macros tab: Do not enter the
MAC END command. Click the Send macro to controller icon and enter the name
of the macro in a separate dialog window.
The macro has been stored in the nonvolatile memory of the C-863.12.
4. If you want to check whether the macro has been correctly recorded:
If you are working with PITerminal or in the Command entry window of PIMikroMove:
− Get which macros are saved in the C-863.12 by sending the MAC? command.
− Get the contents of the macro name macro by sending the MAC? macroname
command.
If you are working in PIMikroMove on the Controller macros tab:
− Click the Read list of macros from controller icon.
− Mark the macro to be checked in the list on the left-hand side and click the Load
selected macro from controller icon.
Example: Moving an axis back and forth
When macros are recorded on the Controller macros tab in PIMikroMove, the MAC BEG and
MAC END commands must be left out.
The axis 1 is to move back and forth. For this purpose, 3 macros are recorded. Macro 1 starts
motion in a positive direction and waits until the axis has reached the target position. Macro 2
does this task for the negative direction of motion. Macro 3 calls up macro 1 and 2.
➢ Record the macros by sending:
MAC BEG macro1
MVR 1 12.5
WAC ONT? 1 = 1
MAC END
MAC BEG macro2
MVR 1 -12.5