# Presentation: 581597

## HCAL DCS

**Shuichi Kunori**
**U of Maryland**
**06-Mar-2006**

## HCAL Readout

**Stefan Piperov**

## Configuration setting and read back by DCS

**3 main run modes **
**Source calibration mode (HCAL partitioned, local R/O)**
**Laser-to-HPD calibration mode **
**Normal (beam) mode**
**132 RBX having ~ 100 bytes of settings each**
**TTC Rx**
- <32 bytes of setting, not used now
**4 RMs having**
- 18 FE channels with 3 bit pedestal + 5 bit delay
- HV and BV for HPD (10 bit each)
**This gives 13.2 Kbytes per run mode or**
**In total ~ 3*132*100 < 50 KBytes**

**HCAL FE Parameters**

**Store the setting and read back in Conditions DB per run.**

## HCAL Monitor by DCS

-    During the normal data taking the HCAL DCS will monitor followingvalues   Per each HPDHV, BV, Ihv, Ibv - single precision floats (4 bytes) ,1 byte of status.In total 17 bytes * 108 RBXs * 4 RMs = 7344    Per each group of HF PMTsHV, Ihv - single precision floats (4 bytes) ,1 byte of status.In total 9 bytes * 48 (?) groups = 432 bytes   Per each RBXlow voltage values LV1, LV2 - single precision floats (4 bytes),temperatures T1,T2,T3,T4,T5 - single precision floats (4 bytes),CCM status + error bytes,In total 30 bytes * 132 = 3960   Per each HV module2 HV module status bytes In total 108+48*2= 312 bytes   This gives 12048 bytes per measurement. Measurements could followwith maximum rate 1 Hz.   I think we could suppress this data flow by applying of the "Deadband" filtering for data change (as it is called in PVSS) by sendingonly data having difference from previous measurement more than given"dead band" value. For example if to apply 5% of "dead band" we willreduce data flow more than 10 times.Regards    Sergej

**Information from Segej Sergueev**

**HPD/PMT   HV, LV**
**QIE  LV**
**Temp. etc.**
**~12kbytes/meas @ 1Hz max.**
**~20Mbytes/day @ 1/60 Hz**
**Not much data, but it may pileup...**
**And never look at...**
**Need to store them in different partition for easy archival and removal.**

## Dataflow diagram

- Tasks:
- DB schema (Yuyi, G., Lee, L, Shuichi K.,  G.L.) XML Loader (Yuyi G., G. L.)
- DCS Monitoring (Sergey. S., G.L.)
- C++ to Oracle interface (Fedor R., G.L.)

## HCAL DCS Architecture

**HCAL DCS Architecture**

**FNAL/JINR (Sergueev)**
**Heterogeneous components: drivers, OS, hardware protocols, trigger types are mostly different.**
**Each system has a uniform interface with DCS through a DIM server (except LV)**
**Expert clients for diagnostics, etc. **
**PVSS + JCOP FW as main control toolkit**

**      ****LV         Laser            Source            HV      .....****   **

**DIM client**

**OPC client**

**SOAP?**

**Local **
**Run control**

**Central DCS**
**(PVSS)**

**RCMS**

## Communication Hardware

**Communication Hardware**

** **

** **

** **

** **

** **

**CCM in RBX**

**2 RS/RS custom hubs per HB-,HB+,HE-...**

**RS422**

**RS422**

**Commercial RS422 fan-out**

**Host PC**

**RS422 interface**

## HCAL infrastructure HW

**HCAL infrastructure HW**

**HV power supply monitoring**
**LV power supplies monitoring**
**LV + ****to**** on-board monitoring**
**LED calibration**
**Charge injection calibration**
**Parameter downloading**
**Source calibration**
**Laser calibration**
**HF radiation monitoring**

**HV**

**Laser**

**Source motor **
**drivers**

**RBX **
**parameters**
**DB**

**LV1**

**HV**

**RadMon**

**?**

## CCM structure

**I2C core**

** **

**Channel **

**Address **

**register**

** **

**ADC**

** **

**Multiplexer**

** **

**FPGA**

** **

**Voltage **

**regu**

**lator**

** **

**Command**

** **

**Response**

** **

**Reset**

** **

**Line Power**

** **

** **

**Serial link core**

** **

** **

** **

**Control**

** **

**Input **

**registers**

** **

**Output **

**registers**

** **

** **

** **

** **

** **

** **

**Controls board**

** **

** **

**Analog**
**inputs**

**Internal RBX serial bus**

**Digital**
**inputs**

**Digital**
**outputs**

**Optocouplers**

**To ROBOX **
**power supply**

**CCM**
**Bipolar FPGA**
**Optically insulated interface**
**Up to 16 analog inputs**
**8 bit ADC**
**I****2****C interface**
**Digital I/O**

## Control Clock Monitor

**LV Regulator**
**(7 total)**

**TTCrx**

**MC100VELT22**
**CMOS – diff LVPECL**
**(7 total)**

**OpAmp**
** ****OP184**

**FRAM**
**(Ramtron Tested)**

**ACTEL**
** ****FPGA**
**A54SX32A**

**ACTEL**
** ****FPGA**
**A54SX72A**

**PZT222A**
** ****Transistor**
**(3 total)**

**MC100LVEP111**
**(2 total)**

**Analog MUX**
**ADG 706**

**AD670**
**8-bit A/D**
**(Analog Devices Tested) **

**RS 485**
**DS36276**
**(3 total)**

**Optocoupler**
**6N134**

**Temp Sensor**
**AD570**

**QPLL**
**(2 total)**

## RS/RS Custom Hub

**ACTEL**
** ****FPGA**
**A54SX32A**

**LV Regulator**
**(2 total)**

**LVDS Receiver**
**DS26LS32**
**(3 total)**

**LVDS Driver**
**DS26LS31**
**(5 total)**

**OpAmp**
** ****OP184**

**PZT222A**
** ****Transistor**

**QPLL1**

## Custom Hub

##  RBX parameters

**FNAL/JINR ( Sergueev)**
**Hardware: custom hubs, CCM**
**3 main run modes (source,laser,beam) **
**132 RBX having ~ 100 bytes each (TTC Rx, pedestal, delay, HV, BV**
**This gives 13.2 Kbytes per run mode**
**Server/clients tested at H2/SX5**
**Configuration tool, tester, debugger **

## CCM configuring tool

## Map/Delay editing tool

##   V,I,Temperature monitor

**6 Temp Sensors **
**2 V, 2 I**
**CCM digitizes**
**Read out through RS links**
**Available to expert clients and DCS via DIM for status, trending and alarms**

## Migration to PVSS

**FNAL/JINR ( Sergueev)**
**Define partitions (hierarchy)**
**FSM tools (state definitions/transitions)**
**Start development Jan ‘05**
**HCAL dedicated integration Feb’05**
**Functioning prototype by Jun ‘05 **
**Ready for the slice/magnet test in common mode  **

## Hardware Partitions

**HCAL DCS **
**SV**

**Hardware Partitions**

**HE**

**HB**

**HF**

**HO**

**IS**

**HF-**

**HF+**

**HB-**

**HB+**

**HO2-**

**HO1-**

**HO01**

**HO02**

**HO1+**

**HO2+**

**RoCr1**

**RoCr12**

**RBX1**

**RBX18**

**HV1**

**HV18**

**RM1**

**RM4**

**HV**

**BV**

**t****o**

**Map**

**Core1**

**Core4**

**Map**

**LV1**

**LV2**

**LV1**

**LV2**

**RBX1**

**RBX6**

**CCM**

**Calib**

**By detector**

## Hardware Tree

## Logical & FSM Partitions

**HCAL DCS **
**SV**

**Logical & FSM Partitions**

**HF**

**HO**

**IS**

**HF-**

**HF+**

**RoCr1**

**RoCr12**

**RBX1**

**RBX6**

**HE-**

**HB-**

**HV1**

**HV18**

**HBEa**

**HBEb**

**HBEc**

**HB+**

**HE+**

**RM1**

**RM4**

**HV**

**BV**

**t****o**

**Map**

**Core1**

**Core4**

**Map**

**LV1**

**LV2**

**LV1**

**LV2**

**HV**

**CCM**

**RAS**

**CCM**

**Calib**

**HBEa,b,c – 120 degree trigger sectors**
**IS – InfraStructure (source, laser, cooling..)**

**By trigger sector**

## Logical/FSM

## HV monitoring

**FNAL/JINR ( Sergueev )**
**Custom PS for HV+BV and for HF PMTs (2 types of HV module)**
**HO+HB+HE-108 RBXs, 18 HV PS crates**
**HF – 72 channels,2 HV PS crates**
**RS-485 communication**
**DIM Server/Client tested**
**Monitoring**** **exercised at H2**                                                    **

## HCAL DCS states

**Off**

**FE **
**loading**

**On**

**Standby**

**Error**

- Wait < 10s
- Finished
- Timed-out

- Wait
- Error detected
- Off cmd
- Standby cmd

- Panic Error
- Severe Error
- Error

- Wait
- Standby cmd

- Wait
- Error detected
- Load cmd
- Off cmd

- Signals:
- Commands
- LV status
- HV status
- FE status

## Error states

**Standby**

**off**

**FE error**

**Error states**

**HV error1**

**LV error**

**HV error2**

**Off**

**LV&HV error**

**Panic error**

**Automatic action - Off**

**Error from:**
**On – trip detected**
**Load – time-out or HV trip**
**Standby –LV/HV trip **
**Exit to:**
**Standby – trip & RBX not loaded**
**Off – severe error**
**On – trip & RBX loaded**

- Signals:
- FE error
- LV trip
- HV trip
- Out of tolerance?

**--- without a command.**

**Load**

## Common and partitioned modes

**Common and partitioned modes**

**ECAL**

**Muons**

**Central DCS**

**HCAL**

**HO**

**HF**

**HB**

**HE**

**HE+**

**HE-**

**Wedge1**

**Wedge18**

**RM1**

**RM4**

**CMS run control**

**DAQ**

**Local run control**

**PVSS II + JCOP FW**

**CMS Infrastructure**
**(racks, cooling, etc)**

**?**

**?**

**Status**

**Commands**

**Laser**

**Source**

**HCAL infra-struct.**

**“****supervisor”**

**HV,LV,T,Params**

**Commands,Status**

## Communications & Hardware Status

**Rocket ports:**** All delivered, install as needed.**
**Custom Hubs:**** All delivered, installed at HE-**
**LAN Cables:**** delay of CERN delivery**
**RBX/CCM - done for HE-**
**HV - Install as needed**
**LV - CANbus + Interlock (use LAN cables) done for HE-**
**Other: HE- only**
**Patch panels in development**
**RA source – controller to drives, cables installed. **
**Laser – fibers installed **

## Software Status

** ****Jan 05 – replace C++ emulator with PVSS**
** ****DIM communication with Run Control**
** ****RBX parameters (local config DB)**
** ****RBX T,V**
** ****HV **
** ****Feb 05 – state definitions and dedicated HCAL integration **
** ****Feb 05 – source driver DIM servers in C++**
** ****Dec 04 – laser DIM servers in BC++**
** ****Mar 05 – source control in PVSS ****(July)**
** ****Apr 05 – laser control in PVSS ****(July)**
** ****May 05 – LV control/monitor in PVSS ****(Nov)**
** ****Jun 05 – HCAL DCS Integration with JCOP FW (HV, FE), ****	****    completed**

## Plans/Issues

**Systems need exercising soon.**
**Debugging hardware and/or software?**
**How to run in partitioned mode?**
**Integration of components with *****new***** RC **