scriptrock - a command line script launcher
scriptrock with tcl scripts can be used instead of compiled C commands
for most of the basic operations, like reseting the ROCK,
testing the FIFOs and so on.
In this page, you can find the syntax of the command and
a short script writing guide.
scriptrock syntax
The syntax of the command is very simple:
scriptrock chain_nr crate_nr scriptname
The actual script name is:
$ROCKTCL/scripts/scriptname.rock.tcl
Script description
A script should contain only two variable definitions:
- rock_user_description
- This variable should contain a detailed description of the script.
- rock_user_command
-
This variable should contain the script commands.
The following commands are defined:
- showinternal
- under tclrock displays the internal page window
under scriptrock does nothing
- showinfo
- under tclrock displays the info page window
under scriptrock does nothing
- showdump
- under tclrock displays the dump window
under scriptrock does nothing
- showstatus
- under tclrock displays the error status window
under scriptrock does nothing
The following variables are defined:
- rock_user_args
- command line parameters
- chain_nr , crate_nr
- chain and crate number
- rockcid
- ROCK id
- rockdfifocid , rockefifocid
- FIFO id for the two FIFOs
An example:
set rock_user_description {\
This command do:
- reset all pulse
- set cintf on
- set diag off
- set efmode 0
- set inttrg off
- set boe off
- set watchdog 0(disabled)
- set boe on
- set diag on}
set rock_user_command {
rock raw write reset $rockcid 0
after 500
rock raw write reset $rockcid 0xff
rock set cintf $rockcid 0
rock set diag $rockcid 1
rock set efmode $rockcid 0
rock set inttrg $rockcid 1
rock set boe $rockcid 1
rock set watchdog $rockcid 0
rock set boe $rockcid 0
rock set diag $rockcid 0
}
Created | : | 21.3.1997 |
Last modified | : | 19.8.1997 |