Hardware Link (caen.hvps)
caen.hvps
High-Voltage Power Supply (HVPS) control and monitoring for CAEN DT5780.
ToolHV
Controller for a single DT5780 High-Voltage Power Supply channel.
Maps physical parameters (voltage, current, ramp rates) to channel-specific
HVPS registers (base offset 0x1220 + ch << 8) using hardware-dependent
scaling factors detected by :class:caen.comm.TheBoard.
Attributes:
| Name | Type | Description |
|---|---|---|
HVPS |
dict[str, dict]
|
Register map with addresses, access flags, units, and limits. |
Floats |
tuple[str, ...]
|
Names of analog HVPS parameters. |
Status |
tuple[str, ...]
|
Bit-ordered labels for the 16-bit HVPS status register. |
doubles |
dict[str, list]
|
Latest |
boolean |
dict[str, bool]
|
Decoded boolean flags from the HVPS status register. |
Source code in caen/hvps.py
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 | |
Status = ('Power', 'Ramp Up', 'Ramp Down', 'Imon > Iset', 'Vmon > Vset', 'Vmon < Vset', 'Vset > Vmax', 'IMon > Imax', 'T > 80℃', 'T > 125℃', 'HV Inhibit', 'Calibration err', 'Alarm reset', 'Shutting Down', 'Power Limit', 'Fan Speed')
class-attribute
instance-attribute
the following is used as prefixes and suffixes for SpinBoxes:
Get_Status()
Poll the 16-bit HVPS status register and update boolean flags.
Source code in caen/hvps.py
89 90 91 92 93 | |
ReadAll()
Read all HVPS registers and update doubles and boolean dictionaries.
Source code in caen/hvps.py
79 80 81 82 83 84 85 86 87 | |
ReadOne(k)
Read a single HVPS parameter and convert it to physical units.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
k |
str
|
Parameter key from |
required |
Returns:
| Type | Description |
|---|---|
float
|
Scaled parameter value in physical units ( |
Source code in caen/hvps.py
95 96 97 98 99 100 101 102 103 104 105 | |
WriteOne(k, v)
Convert a physical value to raw counts and write it to a writable HVPS register.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
k |
str
|
Writable parameter key from |
required |
v |
float
|
Target value in physical units. |
required |
Returns:
| Type | Description |
|---|---|
int
|
Status code returned by |
Raises:
| Type | Description |
|---|---|
SystemExit
|
If the target parameter is read-only. |
Source code in caen/hvps.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 | |
__init__(device, ch, ramp=True, exts=False)
Initialize HVPS scaling factors and control flags for a channel.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
device |
TheBoard
|
Connected digitizer communication instance. |
required |
ch |
int
|
Channel index ( |
required |
ramp |
bool
|
Use controlled ramp-up/ramp-down when switching HV on/off. |
True
|
exts |
bool
|
Measure external analog signals instead of internal V/I monitors. |
False
|
Source code in caen/hvps.py
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 | |