488 CONTROLLER
54
MACROENDM Command
The MACRO command allows the user to build a file of sequential commands and execute them with a
single DOMACRO command. The 488 Controller is capable of storing up to 100 different macros.
Defining a macro is initiated by issuing the MACRO command. Each subsequent character following this
command, including terminators and intervening spaces, is saved in a buffer up to, and including, the
ENDM. After the ENDM, the 488 Controller appends the macro number to the macro buffer as a two-digit
decimal number. The macro can then be executed by issuing a DOMACRO command. Any syntax errors
that are included within the macro are not checked until the macro is executed.
If a macro has not been defined, it does not consume any memory from the USER heap. If a macro has been
defined, any macro buffer previously allocated is returned to the USER heap prior to requesting memory to
redefine the macro. The initial size of an allocated macro buffer is 127 character locations (bytes). If more
than 127 bytes are required to store the macro, additional memory is allocated in 127-byte increments. If
there is no available memory in the USER heap, an “OUT OF MEMORY” error occurs and any memory
allocated to that macro is returned to the heap.
Other useful commands with macros follow. You should refer to the command description for complete
information.
COMMENT
The COMMENT command allows the user to send a predefined ASCII string to the
serial host when the macro is executed.
COUNT
The COUNT command returns the macro loop count of the last executed macro. This
command is only valid during macro execution.
DOMACRO
The DOMACRO command executes a macro. An optionally specified loop count can
be included with this command to execute the macro multiple times. This loop count
is the value returned with the COUNT command.
ERASE
The ERASE command is used to delete a macro and return its memory to the USER
heap. A specific macro can be deleted or all can be ERASEd.
ONDOMACRO
The ON <event> DOMACRO command enables macro execution upon detection of
an event, such as SRQ being asserted by a bus device. This feature is mutually exclusive
with the ARM command.
READ
The READ command allows the macro buffer to be transmitted back to the serial host.
It is sent exactly as it was built with the exception of the macro number appended to
the ENDM portion. This command requires making a copy of the specified macro
buffer. If there is no available memory in the USER heap for this copy, an “OUT OF
MEMORY” error occurs.
TRACE
The TRACE ON command allows the embedded macro commands within the macro
buffer to be echoed out the serial port to the host computer as the macro is executed.
This allows trace debugging during macro execution. This feature is disabled with the
TRACE OFF command.
Содержание 488 Controller
Страница 94: ...488 CONTROLLER 92 9 2 Board Layout Figure 9 1 The 488 Controller s motherboard...
Страница 95: ...93 CHAPTER 9 Theory of Operation Board Layout Figure 9 2 The interface converter s serial I O board...
Страница 102: ...488 CONTROLLER 100 How To Read the Chart Hexadecimal Decimal Equivalent Equivalent ASCII Character Address or Command...