loop

Single line loop.
Format:
SPECTRA> loop "command"
Description:
The command is looped until the space bar is pressed.

Loop expects a single parameter. Commands that consist of more than one token have to be enclosed in double quotes.

Command may consist of several commands. These have to be separated by colons ";".

SPECTRA updates the counter lindex which starts at 1.

/startl=ival
Sets the first loop index.

/matching=expr
All SCAN type GQE are tested whether they match expr. If so, they are marked selected. In a next step the loop command is executed for all selected GQEs and the select flag is cleared. The symbol lname contains the current GQE name.
e.g.:
SPECTRA> loop/match=scan_name””$*$ [display/single/auto lname;wait]

/nl$*$oop[=ival]
Looping terminates after ival iterations.

/ti$*$me
The time that is used by the loop is measured. SPECTRA created the symbols loop_ctime and loop_etime which hold the cpu and elapsed time.

/wa$*$it[=xsec]
SPECTRA sleeps xsec seconds before it re-executed the command, the default is 1 second.

e.g.:
SPECTRA> loop/nloop=10/time [move exp_mot01 0; move exp_mot01 0.1]
This command measures the time for moving a motor 10 times forth and back.