BLMENU.MAC |
[
source code |
installed at |
configured at
]
|
See other macros in category:
Tools
|
Description:
Macros to easily prepare a menu to access
SPEC subsystems functionalities on a beamline.
|
Documentation:
DESCRIPTION
This macro set allows you:
- To change the state on a subsystem chosen from a list (main menu)
- To call a macro to see definitions, state or other interesting
functionality on a subsystem chosen from a list (extra menu)
To get this functionality the macro has to be adapted to your beamline.
You or your spec administrator must:
- - Write a macro function like for instance mcabody(mode)
that accept a mode (0,1,2). Mode 0 should return a string with
the status of the system that will be shown in blmenu. Mode 1
would do the necessary to change the state of the system. Mode 2
may call any macro to access other functionality in the system
- - A call to blmenuadd will add a line to blmenu. blmenuadd
defines the necessary labels and macro name
The user will have to call a single macro \"blmenu\" and choose the
subsystem from the list to change the state. Or select the option \"e\"
to get a second menu with extra functionality
EXAMPLE
- blmenu
- Starts the program
- blmenuadd("MCA","MCA setup","mcabody","mca")
- Will add a line to blmenu with the string \"MCA\" for main menu
and \"MCA setup\" for extra menu. The macro that will be called in
all cases is \"mcabody\" (with mode = 1 from main menu and mode=2
from extra menu) and the key for handling definitions is \"mca\".
- blmenuadd("Keithley 2001","NONE","k2001body","k2001",0x02)
- Same as before but includes as well the flag \"0x02\". As result the
line will be added if and only if k2001 is defined as a counter in config.
See \"help funcs\" and look in the cdef paragraph for the meaning
of other possible flags.
|
Macros:
blmenuadd
Usage: blmenuadd ( label, extra-label, macro, key [,flag] )
Add lines to blmenu. This macro should be called from a setup
file. Lines will be deleted automatically when taken out from
setup
global BL_PHASE
global BL_MAIN BL_SHOWEX BL_EXTRA
BL_MAIN=0
BL_SHOWEX=1
BL_EXTRA=2
blmenu
Usage: blmenu
Will start the \"blmenu\" program
|
Internal Macros:
|
blmenuunsetup
Usage: blmenuunsetup
blmenuhead
Usage: blmenuhead
This is the title for blmenu. Do not need any change
blmenuoption
Usage: blmenuoption
blmenutail
Usage: blmenutail
prtitle
Usage: prtitle(bl,title)
Prints the title on the menu.
proption
Usage: proption
Prints one option line
|
Filename: | blmenu.mac |
Author: | BLMENU.MAC - ICNTL - V.Rey 15/10/96. |
Last mod.: | 26/06/2007 09:44 by rey |
|