Virtual Machine Macros

Macros provide the developer with a means of customizing the actions of the model. They can be used to simulate tool change devices and other mechanical features of the machine that are not controlled by GENER or CERUN built-in functionality. Macros are programmed in an easy-to-use APT-like language and input via the questionnaire using the macro editor.

  • The Macro Language” describes the macro language syntax used by Virtual Machine. This is the same programming facility used with GENER and CERUN.

  • String Formatting” describes how to convert data to and from character string format using macro formatting instructions.

Syntax Format Conventions

Syntax Format Conventions

The syntax for macro commands is listed using the following format conventions:

  • Square brackets \big[ \; \big] encase syntax that is optional. The 0:n symbol preceding the bracketed item, as in \icamrange{0.8}{0}\,\big[,a\,\big] indicates that the bracketed item a can be repeated zero or more times.

  • Parentheses \big( \; \big) encase syntax that lists a number of choices, one of which is required. The parentheses are omitted when the syntax is a simple choice among a number of keywords. The 1:n symbol preceding the parenthesized item, as in \icamrange{0.8}{1}\,\big(,a\,\big) indicates that the item a can be repeated one or more times.

  • Any value not contained in square brackets or parentheses must be programmed each time the macro command is used.

  • Formal keywords are shown in bold upper case, as in ON and WHILE.

  • Lower case words within angled brackets identify common syntax, as in <axis>. The syntax of axis is then defined separately. This makes complex syntax more readable.

  • Italicized lower case words identify variable parameters supplied in the syntax, such as offset or 'name'.