The Timing System of the IHEP Accelerator Complex
V.V. Komarov, I.V. Lobov, A.V. Popov, Yu.S. Tchernoousko
1.

INTRODUCTION

The main purpose of the timing system is generation of timing information, its transmission to technical systems andits reception and transformation into a form convenient for users. The timing information includes a 1-ms clock, main
events corresponding to special points in the magnetic cycle, PLS-telegrams, values defining types and numbers of magneticcycles, astronomical time and data carrying the current parameters of the accelerator (beam intensity and magnetic field).
The main parts of this system are (Fig. 1):- the Timing Message Generator (TMG),- the Repeaters (REP),- the Timing Message Receivers (TMR),- the Multichannel Timers (MT).

2.

DISTRIBUTION.

Timing information is transferred as two-word messages through a network which has a multistar ring topology. The
transfer standard is MIL1553. The nodes of the timing network are repeaters. They are placed in every technical building anddivide the transmission line into more than 20 segments, including beam transfer lines, of 1.6 km each. Vitality of thesystem depends on the quality of a transmission medium, which is based on 9 mm 75 Ohm coaxial cables and methods oftheir connection with the repeaters in each segment.
Three versions of segment organization were studied, Fig.2:- a single cable,- two cables in parallel,- two cables combined by a transformer in a special way.

Probabilities of the faults for each scheme in the case of cable damage correspond to
P1 = 1-(1-p)n , P2= [1-(1-p)n]2 , P3 = 1-(1-p2)n ,where:

n - the number of segments,
p - the probability of one cable damage in any segment.
For p<<1 these equations become:P 1 = np, P2 = n2 p 2 , P3 = np2

The third scheme of communication was chosen because its probability of failure is lower than in the other two cases
by factors of p and 1/n respectively. Multidrop buses corresponding to MIL 1553 standards are used in buildings.

3.

SYNCHROTRAIN

The stream of timing messages forms the UNK Global Synchrotrain (GST), that has a periodic character. The basic
time unit of this train is a frame of 1 ms duration. Each frame is divided into 10 time slots which are spaces for messages,Fig. 3. The message in slot number 0 is available to all users (broadcast mode of transmission) Messages in the slots
numbered 1 - 9 belong to individual users or fulfill specific functions (address mode of transmission).

These timing messages follow the MIL 1553 standard and consist of two words - a command word and a data word in MIL
1553 terminology. The first byte of a message is for control; it defines addresses of accelerating stages to which thetransferred information belongs and the type of information to follow. The next three bytes contain data itself. The entire
data format is spelled out in Table 1.

4.

COMPONENTS.

Most of timing modules were designed to the MULTIBUS-1 standard.
4.1 Timing Message Receiver.
The TMR (serial number ED00050) is a part of all equipment controllers. It receives messages and processes them in
two ways:-hardware decoding of the 1-ms clock and up to 8 events, output to users being via external connectors,-data storage of "beam intensity", "magnetic field", "astronomical time" and "events" in special registers, readable
via the bus.
Two levels of interrupts initialize crate controller programs. The first level informs the processor of an absence of theGST, the second one combines the signals of decoded events, astronomical time and faults in the received information.
A built-in message generator permits checking of the functioning of all the nodes of the receiver.
Output-event pulses are synchronized by the 1-ms clock. The set of selected events is held in PROM (PAL16L8).
4.2 Multichannel Timer (MT)This module (serial number ED00110) is used in equipment controllers to form additional pulses delayed from start
event pulses and/or resynchronized by other clocks. It consists of 6 independent preloaded timer channels; each of them has a
16 bit capacity and is able to count up to a 2 MHz clock rate. It is possible to use any of the 7 clocks: three of them areproduced by a generator (1MHz, 100 kHz and 10kHz), the other four are external. Cross connection of the timers' inputs andoutputs in the connector in a special way allows the formation of any of the three orders of pulse generation (Fig. 4). The
pulse signals produced are used to start controlled equipment via external connectors and/or to initialize crate controller
programs via the interrupt mechanism. A built-in diagnostic scheme allows the testing of any timer channel of the module.

The serial number of the REP is ED00140. This is a part of a UNK retransmission station and it works under the control ofa crate controller. The main function of the module is shape restoration and distribution of the GST signal to users.
Another is to supervise the availability of the signal in both the cables of the transmission line and to receive test messages.
The crate controller changes the addresses of the MIL 1553 decoder and checks a predefined sequence of test messages. Themodule also receives astronomical time messages and registers hardware faults. The crate controller programs are initiated
via two levels of interrupts.
4.4 Timing Message Generator (TMG)
This device consists of four types of module:- crate controller (PC-16, based on the Int8086),- 0.5 Mbyte RAM (DM-16),- multiplexer (ED00150) and- timing message transmitter (ED00100).
The DM-16 keeps the working table of events for the UNK supercycle. The timing message transmitter coordinates therunning of the crate controller program via four interrupt levels, receives table data and data from the two multiplexers (4channels, 16 bit words), forms timing messages according to defined requirements and transmits them. The multiplexers taketechnical data (beam intensity, magnetic field, astronomical time) from the corresponding measuring systems in parallel.

5.

DIAGNOSTICS.

An important requirement in the design of the UNK timing is the ability to find out when and where something goes
wrong within the system. Special devices and built-in means allow one to inspect streams of data in the timing network andto check the functioning of the timing modules.
There are three levels of timing message control:On the global level a special device (Checker) compares the messages at the input with the same messages at the outputof the ring transmission line.
At the level of the repeaters, the availability of the GST signal in both the cables is monitored and special test messages
are checked.
At the level of the timing message receivers, checks are made of the availability of the GST signal in the multidroplines and the correctness of the message decoding. In addition the operation of the timing modules is reflected in status
registers that can be read, and most of their working functions can be simulated.

6.

DELAYS.

The time delay of the GST signal along the ring transmission line depends on the length of the cable and number ofrepeaters used:
Tdel = tcabl * L + trep * n,where: tcabl = 5 ms per km,
trep = 0.25 ms per unit, defined by the process of GST signal shape restoration.
For the whole of the ring transmission
Tdel = 5 * 20 + 0.25 * 16 = 104 (ms).
The influence of the seasonal change of temperature on the cable is the major cause of time delay instability. Given this it
will be 1.2 ms, if the changes of temperature are no larger than 60 C.
The process of GST signal decoding in the TMRs causes a time jitter of both the 1-mS clock- and the event-pulses relative
to the corresponding frames. This jitter can amount to 80 nS.