# Presentation: 549007

## SNS Standard Power Supply Interface*

- S. Peng, R. Lambiase, B. Oerter and J. D. Smith
-  Brookhaven National Laboratory, Upton, NY, USA

_***Abstract***_*** ****The SNS has developed a standard power supply interface for the approximately 350 magnet power supplies in the SNS accumulator ring, Linac and transport lines. Power supply manufacturers are providing supplies compatible with the standard interface.  The SNS standard consists of a VME based power supply controller module (PSC) and a power supply interface unit (PSI) that mounts on the power supply. Communication between the two is via a pair of multimode fibers. This PSI/PSC system supports one 16-bit analog reference, four 16-bit analog readbacks, fifteen digital commands and sixteen digital status bits in a single fiber-isolated module. The system can send commands to the supplies and read data from them synchronized to an external signal at up to a 10KHz rate. The PSC time stamps and stores this data in a circular buffer so historical data leading up to a fault event can be analyzed. The PSC contains a serial port so that local testing of hardware can be accomplished with a laptop. This paper describes the software and hardware being provided to control the power supply. It includes the EPICS driver and serial port software to test hardware and power supplies. *

**Stand alone PSC with Serial Port Interface**

- PSI

**Four PSCs in VME Crate**

- Laptop, Standalone PSC, PSI

_***PSI***_ The PSI is directly connected to the power supply with a pair of short cables and to the PSI with a pair of fibers.  The PSI has four 16-bit ADCs, one 16-bit DAC output, 15 command output bits and accepts 16 status bits.
- The PSI is controlled by commands coming from the PSC over fiber cables.  PSC commands are used to send new DAC values, send commands (on/off), read the analog input signals and status bits, read the last command or setpoint.
- The SNS power supplies require pulses for On, Off and Standby commands. For versatility the PSI has a jumper to give the option of having pulsed or static commands on some command lines. The PSI checks the message received for the correct checksum. If the checksum is wrong, the message is returned to the PSC.
- The ADC’s in the PSI are issued a calibrate command when powered on. There is a delay of 60 seconds to ensure that all voltages have settled.  A recalibrate command can be issued at any time from the PSC.

_**PSC**_ The PSC is a VME board that communicates with up to 6 PSIs controllers via fibers. The PSC and PSI can be separated by up to 4000 meters. The PSC is designed to operate with software initiated or external triggers.  If setup for external triggers, each time a pulse is received a command is sent to the PSI. The time from trigger start until command received at the PSI is fixed, less than 100 microseconds. There are separate triggers for read and write commands. By adjusting the external trigger timing the user can decide exactly what time the ADCs are read or the DAC is written. Timed reads are useful in those applications where it is necessary to sample data at a particular time. As an example in the SNS we want to know if the kicker magnets are fully charged just before injection starts. With hardware-triggered reads, data can be read at a high rate and the data saved in PSC memory. This is done without any CPU overhead.  By reading at a high rate the software can optionally average data to get more accurate readings. When the status and ADC data is read from the PSI the data is stored in a circular buffer. Each channel has a separate buffer. The buffer size allows saving 5458 frames of data. A frame contains four 16-bit analog input values plus 16bits of status data along with header and other information. A pointer is available to indicate the location of the last frame received. When last setpoint and command data is read, the data is stored in separate registers.  The SNS will operate at 60 Hz. If data is read on each pulse, then the memory will hold the last 90 seconds of data. When a beam dump occurs memory updating can be inhibited which preserves a data history up to 90 seconds prior to the event.
- The PSC keeps track of link errors. For each channel there are bits for link error, checksum error or communication timeout. When these errors are received they are latched until cleared by the operator. There are commands to disable or enable any channel.
- The PSC supports burst mode that causes the PSC to poll the PSI at a fixed rate for a number of cycles with the data being stored in the circular buffer. The maximum rate is 10,000 Hz. This can be used to look for unusual conditions or measure the power supply response time.

- LabView Screen

_***Summary***_*** ****The standard power supply interface is expected to greatly simplify the installation of power supplies at ORNL. The power supply vendors will test the power supplies at the factory with PSC/PSI hardware. LabView software is provided that allows complete power supply testing.   When the power supplies arrive at the site they will already have been tested with control system hardware. At the site it will only be necessary to connect a pair of fiber cables between the control system and PSI to have an operational system.*

_***Status***_*** ****The PSC/PSI combination will also be used by the BAF project at BNL and there are plans to use it in future additions or upgrades in the CA department.  BNL, ORNL and LANL will be buying power supplies compatible with this interface. Several manufacturers will be providing supplies to BNL, LANL and ORNL compatible with this interface. *