/////////////////////////////////////////////// *** Scripts to assist in making alhConfig files *** /////////////////////////////////////////////// PLEASE USE VERSIONS OF THESE SCRIPTS IN PRODUCTION IN /home/softegr/jrock/tools/alh/config/sandbox These scripts are useful for constructing alh config trees. They may eventually become part of an actual production process. But for now are not necessarily completely bug-free! Please inspect output to make sure it's what you expect. Help create alhConfigs from PV lists ===================================== makeConfigs.csh --------------- call makeDevGroupConfigs.pl with parameters makeDevGroupConfigs.pl ---------------------- takes a file containing device instances and their PVs of the format CHANNEL groupname pvname flags for example CHANNEL VGCC:IN20:113 VGCC:IN20:113:P ----- CHANNEL VGCC:IN20:113 VGCC:IN20:113:PSTAT ----- CHANNEL VGCC:IN20:113 VGCC:IN20:113:STATUS ----- CHANNEL VGCC:IN20:221 VGCC:IN20:221:P ----- CHANNEL VGCC:IN20:221 VGCC:IN20:221:PSTAT ----- CHANNEL VGCC:IN20:221 VGCC:IN20:221:STATUS ----- This input file can be the product of an IRMIS select statement. Creates a lower level alhConfig file, with a group for each device, and a higher level group above all the devices. Used in the generation of device type vs subsystem/area for the alh tree. e.g. vac_in20_vgcc.alhConfig (for the in20 beam regions, this would need to be further subdivided manually, but it's a good start!) parameters are: -fix: write the file toplevel group name (e.g. VGCC:IN20DL:VA01, or VGCC:xyz:VA01 for further substitution) alias (e.g. VGCC) guidance (e.g. "xyz vacuum cold cathode gauges") input list Add features to existing alhConfigs, create Summary PV and FORCEPV databases and templates ========================================================================================== addForcePVs.pl -fix GROUP|CHANNEL filespec.alhConfig ---------------------------------------------------- Adds $FORCEPV statements to alhConfig files ***use with CHANNEL ONLY - we aren't using these for GROUPs ***RESULTS OVERWRITE ORIGINAL FILES -fix: write the file. if -fix not entered, just outputs to the screen and counts the instances GROUP|CHANNEL: specify one for the GROUP or CHANNEL level. ***use with CHANNEL ONLY - we aren't using these for GROUPs filespec.alhConfig: file or wildcard filespec. makeForcePVdbTemplates.pl -fix filespec.alhConfig ------------------------------------------------- Makes .template files for instantiation of FORCEPVs for booting into AL0D and AL00. Instantiates alhFORCEPV.db Output is a .template file for each alhConfig file named alhFP_configFileName.template -fix: write the file. if -fix not entered, just outputs number of PVs filespec.alhConfig file or wildcard filespec. makeForcePVcw.pl -fix cwfilename filespec.alhConfig --------------------------------------------------- Makes file cwfilename containing FORCEPV names for adding to AL00_SYS0.cwConfig for save/restore -fix: actually write to the file cwfilename: name of file for cw list filespec.alhConfig file or wildcard filespec. makeSummaryPVdbs.pl -fix filespec.alhConfig ------------------------------------------- Makes summary PVs based on alh tree. Output is a .db file for each alhConfig file named alhSP_configFileName.db (this program calls addFPsumys.pl for each .db file to add FP summaries) -fix: write the file. filespec.alhConfig file or wildcard filespec. addGuidance.pl -fix filespec.alhConfig -------------------------------------- Adds Summary PV and Group name to the guidance for each group ***RESULTS OVERWRITE ORIGINAL FILES -fix: write the file. filespec.alhConfig file or wildcard filespec. addPButtonsMgnt.pl -fix filespec.alhConfig addPButtonsVac.pl -fix filespec.alhConfig ------------------------------------------ Adds P buttons for each group. Specific to subsystem... ***RESULTS OVERWRITE ORIGINAL FILES -fix: write the file. filespec.alhConfig file or wildcard filespec. Misc utils ========== changeMasks.pl -go chanSpec newMask filespec.alhConfig ------------------------------------------------------ Changes the mask of matching channels in .alhConfig files ***RESULTS OVERWRITE ORIGINAL FILES -go optional - write the file (otherwise simply outputs lines it would update) chanSpec: matching pattern for channel config line (e.g. "ACT " or VPIO) newMask: new mask value (e.g. --A--) filespec.alhConfig: files to change makecvsadds.sh -------------- creates a script to do cvs add for a list of files make a list of files to be added to cvs: ls -1 filespec > filelist makecvsadds.sh filelist addToCvs.sh