MVD GUIs


In order to improve comunication with the MVD slow controls, a set of GUI's were written to duplicate the functions now accessible only by logging in to iocondev8, the MVD MVME162 crate controller. These GUI's run on phoncs0.

     


Typing   /home/phoncs/mvd/vme/mon_gui.pl

Brings up this top-level gui: ---->

From here, there are 3 choices: LV, RELAY and COOLSTAT, and clicking on them will expand the little window.



This comes up when you click on LV: ---->

The layout represents a view of the MVD from above, with the bottom folded out. Clicking on any of the colored buttons will toggle the power to that power/comm board. As shown, they are in the state needed for run-4 - the motherboards and the pads are on, and IT (=group 1) also must be on.
Clicking on the 'close LV panel' button will collapse the gui back to the small start-up gui. Communication with iocondev8 is with rsh (remote shell) commands. The gui sends a command to iocondev8, where program lv_mon.c runs and writes results to STDOUT. This output is captured by the gui and displayed in the white bottom frame. It is also parsed and turned into button colors.

Sources:
mon_gui.pl
lv_mon.c



Collapsing the LV panel and clicking on RELAY brings up this: --->

The buttons are clickable. As shown, all components are in 'AUTO', as they should be.

Sources:
mon_gui.pl
relay_mon.c



Closing RELAY and clicking on COOLSTAT produces this: ---->

For now it echos the output of the existing COOLSTAT program, and by following the logic of the relay board, indicates if part of the MVD has been shut down. A shutdown will affect those components that are in 'AUTO' state on the RELAY display above.

Sources:
mon_gui.pl
temps_mon.c




The source codes are phoncs0:/home/phoncs/mvd/vme/mon_gui.pl, written in Perl/Tk. It calls these programs in iocondev8.phenix.bnl.gov:
lv_mon.c
relay_mon.c
coolstat.c


 


A separate gui, is /home/phoncs/mvd/vme/pcf_manipulator.pl
It parses the mvd PCF file and shows which packets are on or off in the readout. The output table is also written to disk in file pcf_manipulator.tmp.

Here is the source code for pcf_manipulator.pl



 


 
Script /home/phoncs/mvd/vme/temps_mon_nogui.pl (source) reads the temperatures and voltages from the MVD once a minute by activating program temps_mon on iocondev8. (Here is the source code of temps_mon.c). Check that the script is running: On phoncs0:
       ps -A | grep temps     
should show one process.

The script writes the values into mvd_tempslog.dat. This file gets closed and renamed at midnight (to mvd_tempslog_14feb03.dat for example) and a fresh file is started. The running history can be seen in mvd_temps_errorlog.dat.

Program read_temps.c is a plain c program that can unpack the data from these files.  




FEED_MVD.PL: ARCNET DOWNLOADS
Arcnet downloads are usually done by running feed.pl on phoncsb. This allows a 'full feed', and a 'quick feed'. A 'full feed' performs the functions that are listed at the top of the gui shown here. A 'quick feed' does only the TCIM and the MCM serial load and readback. These two functions can be executed in this detailed gui with the two buttons on the bottom right (independent of the button settings on the top).

More detailed downloads can be done by using the buttons on the top. Select the functions you want to perform, and then click on the MCM-group you want to talk to. For example, in the image on the right only the serial download and readback are selected, and if I now click on the 'SW OB' button, this function will be performed on only those 6 MCMs. [Right now, I talk to all 6 MCMs in a group. I can add code to talk to an individual MCM if you want].

The top 3 functions are global. When they are selected and you click on a MCM group button, they talk to the GTM, DCMs or TCIMs for the whole system.

How to use:
Log in on phoncsb as phnxrc, and go to /home/phnxrc/mvd/vme. Type feed_mvd.pl. Feed uses command lines in *.acf files. The standard files contain command lines for all MCMs. In order to do the detailed commands, I split the acf files into 4x5 pieces. This is done in directory /home/mvd/vme/acf by running script ./split.pl there. Note that after a change is made in the original big acf file (say after a cable swap or connector change), you must re-run ./split.pl to propagate the change into the split acf files.

Here is the source code of feed_mvd.pl and split.pl.

 




DDUMP_PARSER: looking at prdf files
This gui parses the output from a ddump command and reformats the output in compact form.

How to use:
Log in on phoncsc as phoncs, and go to /home/phnxrc/mvd/vme. Type ddump_parser.pl. Fill in the file name, and press ddump. The open button checks for the existence of file(s) requested. Using the * as in the picture gets you the files from both partitions, as shown.

Here is the source code of ddump_parser.pl


Last update 30 Jan 04 HvH
back