SUB-SAMPLE TIME-BASE RESOLUTION IN A HETEROGENEOUS DISTRIBUTED DATA ACQUISITION ENVIRONMENT J. Stillerman*, W. Burke, B. LaBombard, MIT Plasma Science and Fusion Center, Cambridge, MA 02139 Abstract We have developed a reference timing system to verify and correct the time-bases for acquired time series data. This system allows for sub-sample time registration of data acquired from separate diagnostics using heterogeneous data acquisition hardware. The system was designed to recognize and repair several types of timing discrepancies including trigger recognition and configuration differences, clock rate slew, and data acquisition errors such as lost or mislabeled samples. When used as a dedicated time-reference standard, the system relaxes the requirements for cross-diagnostic data acquisition synchronization; time-bases can be unambiguously resolved from hardware that uses asynchronous clocks and triggers. This paper describes an automated system for generating sub-sample accurate time-bases across multiple diagnostic systems on the Alcator C-Mod device, a magnetic-confinement fusion experiment. The system has been demonstrated to accurately determine the times of measured phenomena in order to track point of origin and propagation around the experiment. In addition, timing errors in signals can be easily flagged and corrected. The initial installation has been applied to a variety of diagnostics, including fast, optically-based fluctuation diagnostics and plasma-sampling probes. These diagnostics are physically distributed around the experiment cell, have disparate digitization rates (0.1 MHz to 10 MHz) and operate with both synchronous and asynchronous clocks and triggers. INTRODUCTION Alcator C-Mod is a high magnetic field tokamak research facility located at the MIT Plasma Science and Fusion Center in Cambridge MA [1], producing high- density, high-temperature plasmas under conditions approaching that needed for thermonuclear fusion. An extensive array of diagnostic systems is employed in this research, spanning time scales of several minutes and resolving transient events to the sub-microsecond level. The typical experiment shot cycle takes about 20 minutes with about two minutes of hardware setup, 4 seconds of pre-plasma activities, and 2 seconds of plasma. Data is collected over the next seven minutes with the bulk of the 4 to 5 GB of data available within the first four minutes. We employ a distributed high-speed timing system [2], which in theory provides microsecond accuracy for clocks and triggers in the diagnostic racks. The diagnostic data are acquired by heterogeneous devices tailored to the needs of the specific measurements and distributed around the experiment cell. Many diagnostics are on their own electrical grounds. While this timing system has served us well, uncertainty arises on occasion as to the precise times of measured samples. In addition, there are cases where we would like to correlate measurements from independent diagnostics to a time accuracy at least equal to the sampling interval. MOTIVATION Timing uncertainty arises from a number of disparate sources. In a perfect world, all hardware would behave flawlessly as documented, and its operation would be perfectly understood by software developers and users; it would be configured correctly, both in terms of physical connections and software configuration. Different data acquisition equipment often have particular triggering and clocking behavior. Some digitizers clock and/or trigger on rising edges others on falling edges. Some digitizers trigger on the first or second rising edge after a falling edge etc. These behaviors are not always well documented by the manufacturers, and it is relatively expensive to categorize them exactly for every digitizer model. In addition, things do not always work as documented. Various hardware limitations sometimes necessitate the use of independent clocks for sampling, and these clocks are not tied to the central timing system. In these cases, not only the precise frequency but also the phases of these clocks are unknown. Another source of timing uncertainty lies in the hardware and software configuration. It may be known that a digitizer triggers on a falling edge, but the user can mistakenly describe the trigger as the time of rising edge. Finally, there are cases where we would like to correlate the times of measurements taken by heterogeneous equipment at varied locations around the torus hall, to sub-sample accuracy. SOLUTION We have developed and optically distributed timing signature signal [3], which can be digitized by any diagnostic that requires verification of its sample timestamps. The signal, shown in figure 1, has 19 bit encoded values on a 1 kHz waveform. Analysis of this waveform provides accurate timestamps for all measurements, independent of the classes of errors as outlined in the motivation section. WEB004 Proceedings of ICALEPCS2009, Kobe, Japan Hardware Technology 382