esrf

Beamline Instrument Software Support
SPEC Macro documentation: [ Macro Index | BCU Home ]

disable.mac
See other macros in category: Positioning Counting Tools
Description:
    Deactivate selected counters or motors
Documentation:
    DESCRIPTION
    Use these macro to speed up scans.
    By default, SPEC reads all counter for a scan point, whether it is plotted or not. By skipping the readout of uninteresting counters, the duration scans can be reduced considerately. Also "pseudo" motors can cause a substantial software overhead. These macros allow you to optimize SPEC for a certain subset of motors and counters "on the fly" without making modifications in the configuration editor.

    INTERNALS
    Information whether a specific motor or counter should be enabled or disable after "reconfig" is stored in the ESRF data base under "ID9/motor/spec_mot1", if it is a motor is called "mot1" and "ID9" the beamline name. If you have different SPEC configurations "spec" is replaced by the configuration name.

Macros:
    disable
    Usage: disable mnemonic [mnemonic ...]
    This macro can be used for counters and motors.
    It is usefull for speeding up scans by disabling the readout of counters which are currently not used.
    As arguments you may use motor or counter mnemonics in any order, as well as the key word "all", "all motors", "all counters", "except","only" "but not" and "and". For example, you can specify "disable all except ywire posmon and posy" or "disable all counters but not pd3".
    Use "?" to get list of enable counters/motors

    enable
    Usage: enable mnemonic [mnemonic ...]
    Undo "disable".
    The same key words as for "disable" are allowed, e.g. "enable only ywire posmon and posy".

    disable_setup
    Usage: disable_setup
    Normally "config" or "reconfig" would re-enable all counters and motors which were disabled. Include this macro into your "setup" file if you do not want this to happen.
    Make sure that the line "disable_setup" is at the end of the "setup" file because some macros as "adcsetup" or "elmetersetup" will re-enable counters as well.


    disable_undo
    Usage: disable_undo
    restores the motors/counters state just before last called of enable/disable macros.

Internal Macros:
    _disable
    Usage: _disable %MDESC%


    _enable
    Usage: _enable %MDESC%


    disable_save
    Usage: disable_save()
    Save into a global variable the current disable status of motors/counters. It is called from the disable and enable macros,

    disable_counter
    Usage: disable_counter ("cnt",1|0)
    sets or clears the the "disable" flag for the counter "cnt". If the second parameter is 1 the counter is disabled if it is 0 the counter is enabled.
    Also, the current state of the counter is saved in the ESRF data base.

    disable_motor
    Usage: disable_motor ("mot",0|1)
    sets or clears the the "disable" flag for the motor "mot". If the second parameter is 1 the motor is disabled if it is 0 it is enabled.
    Also, the current state of the motor is saved in the ESRF data base.

Filename: disable.mac
Author: Friedrich Schotte, ID9, 27 Oct 2000
Last mod.: 27/02/2008 18:14 by rey