EPICS: HV : ADDING CRATES
- ssh clonioc1
- //no needed source ~sytnik/.cshrc_hallb_install
To generate database
- cd0
- edit gen6val.cpp if necessary
- g++ -o gen6val gen6val.cpp
- ./gen6val macros
To add crate to epics db
- //not needed, will restart later cioc_cron 0 // to kill ioc
OLD SCHEME
- cd0 (for old CAEN it will be cd0o, for mpod cd0m)
- edit in db_generator.cpp
- change: NCRATES, slot_mask, slot_types in the following piece:
///----------------- CRATES/SLOTS CONFIGURATION FOR IOC ----------------------------
#define NCRATES 1 #define NSLOTS 16 enum {A1535, A1520}; int NCHANNELS[2] = {24, 12};
int slot_mask[NCRATES][NSLOTS]= { {1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1} };//, // crate 0 //{1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1} }; // crate 1
int slot_types[NCRATES][NSLOTS]={
{A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535 }//, // crate 0 //{A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535, A1535 }//, // crate 1
};
///-------------------------------------------------------------------------
- g++ -o hv_gen db_generator.cpp
- ./hv_gen // produce hvprod.db
- add new crate to startup.all
- cioc_cron 2 // to restart ioc
NEW SCHEME
- source ~sytnik/c
- cd0
- hv.substitutions and hv.substitutions_smi were generated by epics_generator as part of CLAS12 procedures
- to start new caen hv demo ioc to FSM, do 'cd0' and 'mye_n'
MPOD - old GUI version here with wrong status handling, new version of GUI is in SVT state-machine scheme
- cd0m
- ../../bin/linux-x86/mpodCrates st_mpod.cmd
To add crate to the Qt GUI
- qtcreator &
OLD
- file >> Open File or Project >> /usr/clas12/epics/qt/epicsqt_v1/hv_control/hv_control.pro
- click "Configure Project" (next times: file >> Recent Projects >> /usr/clas12/epics/qt/epicsqt_v1/hv_control/hv_control.pro)
- expand "+sources"
- double click mainwindow.cpp to display the file
- In the following piece change: NCRATES, 'board_names_by_crate, board_types_by_crate, hv_crate_names, hv_crate_types'
Comment: B_HV001_5_P0 stands for - Hall B - Crate 1 - slot 5 - all channels (P0) //------------------- CRATES/SLOTS CONFIGURATION FOR GUI----------------------------
//==================CONFIGURATION PIECE==============================================================
char *board_names_by_crate[3][16]={
{"B_HV000_0_P0","B_HV000_2_P0","B_HV000_4_P0", "B_HV000_6_P0","B_HV000_7_P0","B_HV000_8_P0", "B_HV000_9_P0","B_HV000_10_P0","B_HV000_11_P0","B_HV000_12_P0","B_HV000_13_P0","B_HV000_14_P0", "B_HV000_15_P0" ,"","",""} ,
{"B_HV001_0_P0","B_HV001_1_P0","B_HV001_2_P0","B_HV001_3_P0","B_HV001_4_P0","B_HV001_5_P0", "B_HV001_6_P0","B_HV001_7_P0" ,"B_HV001_8_P0","B_HV001_9_P0","B_HV001_10_P0","B_HV001_11_P0","B_HV001_12_P0","B_HV001_13_P0","B_HV001_14_P0","B_HV001_15_P0"}
/// {"B_DCRB_HV000_0_P0","B_DCRB_HV000_1_P0","B_DCRB_HV000_2_P0","B_DCRB_HV000_3_P0","B_DCRB_HV000_4_P0","B_DCRB_HV000_5_P0","B_DCRB_HV000_6_P0", /// "B_DCRB_HV000_7_P0","B_DCRB_HV000_8_P0", "B_DCRB_HV000_9_P0","","","" ,"","",""},
/// {"b_wmpod_hv000_0_P0","b_wmpod_hv000_1_P0","b_wmpod_hv000_2_P0","","","","","","","","","","" ,"","",""} };
int board_types_by_crate[3][16]={
{HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535,0,0,0} ,
{HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535, HvCrate::CAEN_A1535}
/// {HvCrate::CAEN_A944, HvCrate::CAEN_A944, HvCrate::CAEN_A944, HvCrate::CAEN_A944, HvCrate::CAEN_A944, HvCrate::CAEN_A944, /// HvCrate::CAEN_A944, HvCrate::CAEN_A944, HvCrate::CAEN_A944, HvCrate::CAEN_A944, 0,0,0, 0,0,0},
/// {HvCrate::WMPOD_HV,HvCrate::WMPOD_HV,HvCrate::WMPOD_HV,0, 0,0,0,0, 0,0,0,0, 0, 0,0,0} };
char *hv_crate_names[]={"crate #1 \n CAEN 1527","crate #2 \n CAEN 1527", "crate \n CAEN 527", "crate \n Wiener MPOD"};
char hv_crate_types[]={CrateButton::CAEN_1527, CrateButton::CAEN_1527, CrateButton::CAEN_527, CrateButton::WMPOD };
//--------------------------------------------------------------------------------------------------------------
- cdhv
- cp hv_control $CLAS/epics/bin/$EPICS_HOST_ARCH/
!!! above 2 lines wrong, do following: cd $CLAS/epics/qt/epicsqt-1.1.2-src/hv_control_3crates cp hv_control $CLAS/epics/bin/$EPICS_HOST_ARCH/hv_control_exec
- hv_control // to start GUI
- NEW
- file >> Open File or Project >> /usr/clas12/release/0.1/epics/qt/epicsqt_v1/hv_control/hv_control.pro
- click "Configure Project" (next times: file >> Recent Projects >> /usr/clas12/release/0.1/epics/qt/epicsqt_v1/hv_control/hv_control.pro)
check 2 up boxers and unckech 2 bottom (debug) boxes
- expand "+sources"
- double click mainwindow.cpp to display the file, look for configuration piece; new caen confifuration is different from old caen and mpod,
those two will be modified later
- click hammer sign (left-bottom corner) to build the project
- source ~sytnik/c
- gui_hv