esrf

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

MUSST.MAC
See other macros in category: Detection Other hardware Isg
Description:
    Macros for operating and testing the MUSST module
Documentation:
    OVERVIEW
    This macro set allows to set MUSST isgdevices in spec, configure their signal inputs as pseudocounters, edit and download programs, and provide simple macros for basic operation.
    An interactive macro musst can be used for device configuration and monitoring.
    More than one MUSST module can be operated through this macro set.

    EXAMPLE
    musstsetup mainsync 2
    Configures a MUSST unit connected to the serial line #2 and assigns the name \"mainsync\" to it.
    musstsetup pitch id33/serlin/11
    Configures a MUSST unit associated to the TACO device \"id33/serlin/11\"
    musst
    Starts the interactive test program with the default unit.


    DEPENDENCIES
    These macros make use of the following macro sets:
    • stlist.mac
    • isgdevice.mac
    • isg.mac


    SETUP
    A musstsetup macro must be included in the setup file for every MUSST unit configured. Each unit is identified by its name that must be a unique isgdevice identifier.

Macros:
    musstsetup
    Usage: musstsetup <musst_name> <comdev> [<parameter>=<value> ...]
    Configures a MUSST unit connected to <comdev> with the name <musst_name>. The following optional parameters can be also set.
    • Valid parameters:
      address=<addr>
      This parameter allows to address a particular unit when the serial line is shared by several isgdevices in dasychain. If <addr> is a non-numerical value, it is treated as the isgdevice address set by the ADDR command and stored internally in the unit. On the other hand if <addr> is a numerical value it indicates the relative position of the module in the serial line chain starting from 0. If this parameter is not specified, spec looks for the first MUSST unit in the chain.
      ch<n>=<cnt_mne>
      If <cnt_mne> is a valid counter mnemonic, it gets configured as a pseudocounter that uses the nth channel in MUSST (n = 1 to 6). The \"Scale Factor\" value in the spec config file applies.
      update=<update_time>
      Sets the update time in seconds for the interactive macro (musst). The default is 1 second.


    musststate
    Usage: musststate [<musst_name>]
    Prints the current state (Sends the request ?STATE to MUSST).

    musstrun
    Usage: musstrun [<musst_name>]
    Starts program execution (Sends the command RUN to MUSST).

    musststop
    Usage: musststop [<musst_name>]
    Stops program execution (Sends the command STOP to MUSST).

    musst
    Usage: musst [<device_name>]
    Macro that runs the interactive loop. musst refresh certain information on the screen and at the same time accepts commands from the standard input.


Internal Macros:
    _musstsetup
    Usage: _musstsetup(args)


    musstunsetup
    Usage: musstunsetup


    musst_setdefault
    Usage: musst_setdefault(isgname)


    musst_comm
    Usage: musst_comm(comm, isgname)


    musst_get_timer_scale
    Usage: musst_get_timer_scale(isgname)


    musstcomm
    Usage: musstcomm


    musst_getstate
    Usage: musst_getstate(isgname)


    musst_getcounts
    Usage: musst_getcounts(isgname, _timer, _ch1, _ch2, _ch3, _ch4, _ch5, _ch6)


    musst_getdata
    Usage: musst_getdata(isgname, nlines, npts, mdat, buffer)


    musst_update
    Usage: musst_update


    musst_prompt
    Usage: musst_prompt
    Displays the prompt on the screen. If the "update" flag is set also displays the board state.

    musst_show_comm
    Usage: musst_show_comm


    musst_process_comm
    Usage: musst_process_comm


    musst_cfg_show_cnt
    Usage: musst_cfg_show_cnt(isgname, chname)


    musst_list_files
    Usage: musst_list_files(path, lastfilepath)


    musst_choose_file
    Usage: musst_choose_file(isgname)


    musst_slow_upload_program
    Usage: musst_slow_upload_program(musst_name, filepath, clear)


    musst_upload_program
    Usage: musst_upload_program(musst_name, filepath, clear)


    musst_trace_program
    Usage: musst_trace_program(isgname, step)


    musst_config
    Usage: musst_config(cnum, type, unit, module, chan)


    musst_cmd
    Usage: musst_cmd(cnum, key, p1, p2)


Filename: musst.mac
Author: P.Fajardo, (Original 2/04). $Revision: 1.12 $ / $Date: 2023/03/28 09:08:35 $
Last mod.: 28/03/2023 11:08 by claustre