2 August 1983 22 July 2008 update by G. Johnson TO: Distribution From: M. Glass Subject: 177 timing channels. This is the description of the new way of using DEC-T/DEC-S 177 type timing channels. We are currently converting all 177 software to the new format. For each timing channel (a single channel on a 177 card) you need two devices in the data base. The first allows you to set the delay counter (and frequency), read it back, enable/disable the channel, and display enabled/ disabled. The second device allows you to set up the list of events that trigger the timer. The first 177 device supports four properties, to wit: reading, setting, basic status, and basic control. All four properties are added to the data base for each device. All use an identical SSDN. The new SSDN for the first device looks like this: +---------------------------------------+ | 00 | 00 | +---------------------------------------+ | 00 | OID = 10 (hex) | +---------------------------------------+ | 'C' crate number | 'N' slot | +---------------------------------------+ | 00 | channel # (0-7) | +---------------------------------------+ The channel number goes from 0 to 7 (decimal) where channel 0 is the one you get by addressing F(0) A(0) on the card. The reading and setting properties both have default lengths of two words. These contain a single number representing the delay time in microseconds. The first word contains the low order 16 bits of the time. This matches fortran integer*4 conventions. The 177 timing channel has a 16 bit delay counter. Thus the front end computer converts the two-word delay time in microseconds to a 16 bit counter value and a timing resolution. You will get the best resolution possible, but note that for longer delays you can't set the 177 to trigger at the nearest microsecond. When you read back the time delay (using either the reading or setting properties) you will get the value actually set into the 177. If you try to set a time delay longer than 65.535 seconds, the maximum the hardware will allow, the front end will set the delay to this maximum value. The basic status property is one word. Only the low order two bits are meaningful. Bit 2**0 contains 1 if the timing channel is enabled, 0 if the channel is disabled. The basic status PDB should be set up so that this bit turns into ON and OFF. Bit 2**1 contains 1 if the 177 card is returning LAM. This is supposed to mean that the clock has gone away. For basic control you send a word containing 3 possible values thusly: 1 - disable the channel (and thus the event). 2 - enable the channel 3 - reset the whole 177 card (all 8 channels) The basic control PDB should be set up so these values are returned for OFF, ON, and RESET respectively. The SSDN for the second device looks like this: +---------------------------------------+ | 00 | 00 | +---------------------------------------+ | 00 | OID = 11 (hex) | +---------------------------------------+ | 'C' crate number | 'N' slot | +---------------------------------------+ | 00 | channel # (0-7) | +---------------------------------------+ Note that this is identical to the SSDN for the first device except for the OID in the second word. This device supports only a setting property. You use this property to both set and read the list of events that can trigger a timing channel. There are a maximum of 15 events per device; they are packed into an eight word array. The first byte contains a count of events to follow; subsequent bytes contain the events themselves; and the array is padded out with 'FF' null events for good measure. The buffer looks like this: +---------------------------------------+ | event 1 | count of events | +---------------------------------------+ ~ ~ ~ ~ +---------------------------------------+ | FF (null event) | event N | +---------------------------------------+ ~ ~ ~ ~ +---------------------------------------+ | FF | FF | +---------------------------------------+ Distribution ------------ A. Frank N. Gelfand R. Gerig G. Johnson F. Sample S. Sommers T. Watts