This shows you the differences between two versions of the page.
— |
s800_version_0x0005 [2013/12/12 11:17] (current) pereira created |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ===== Top level packet tags ===== | ||
+ | |||
+ | The top level packet tags are defined as (c code): | ||
+ | |||
+ | < | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | </ | ||
+ | |||
+ | |||
+ | ====== Detailed description of each packet tag ====== | ||
+ | |||
+ | This section gives details on how to unpack the data associated with each packet tag. The format of the data for each packet tag is frozen as of version 4 of the S800 data format. Further modifications to data associated with a particular detector will result in a new packet tag being defined. Please see the [[S800 data format# | ||
+ | |||
+ | ===== S800_PACKET ===== | ||
+ | |||
+ | This is the outermost packet tag that wraps the entire physics event. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | There are two subpackets that are guaranteed to exist in the data stream. The first subpacket will always be the S800_TIMESTAMP_PACKET. This will be followed by the S800_EVENT_NUMBER_PACKET. Following packets will only be present if there is data to fill them. | ||
+ | |||
+ | ===== S800_TIMESTAMP_PACKET ===== | ||
+ | |||
+ | A 64 bit timestamp read from a Jtec XLM74 universal logic module. Written as four consecutive words. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where a are bits 15-0, b are bits 31-16, c are bits 47-32 and d are bits 63-48 of the 64 bit timestamp word. | ||
+ | |||
+ | The clock is 10MHz, which means that it will wrap around after approximately 800 years. | ||
+ | |||
+ | |||
+ | ===== S800_EVENT_NUMBER_PACKET ===== | ||
+ | |||
+ | A 48 bit trigger/ | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where a are bits 15-0, b are bits 31-16 and c are bits 47-32 of the 48 bit trigger/ | ||
+ | |||
+ | |||
+ | ===== S800_TRIGGER_PACKET ===== | ||
+ | |||
+ | Data read from the Lecroy 2367 ULM module and a Phillips 7186H TDC. One trigger pattern followed by up to four times. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where p is the trigger pattern, c is the channel within the TDC and t the data. | ||
+ | |||
+ | ^ Time data^ TDC Channel| | ||
+ | |S800 source|8| | ||
+ | |External1 source|9| | ||
+ | |External2 source|10| | ||
+ | |Secondary source|11| | ||
+ | |||
+ | ===== S800_TOF_PACKET ===== | ||
+ | |||
+ | Times read from both a Phillips 7186H TDC and an Ortec 566 TAC digitized by a Phillips 7164 ADC. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | ^Time data^TDC channel^TAC channel| | ||
+ | |RF|12| | | ||
+ | |Object Scintillator|13|5| | ||
+ | |XFP Scintillator|14|4| | ||
+ | |Si|15| | | ||
+ | |||
+ | ===== S800_SCINT_PACKET ===== | ||
+ | |||
+ | Energies and times of the focal plane scintillator, | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | ^Detector signal^Channel| | ||
+ | |E1 Up|0| | ||
+ | |E1 Down|1| | ||
+ | |E2 Up|2| | ||
+ | |E2 Down|3| | ||
+ | |E3 Up|4| | ||
+ | |E3 Down|5| | ||
+ | |||
+ | |||
+ | ===== S800_FP_IC_PACKET ===== | ||
+ | |||
+ | Zero suppressed energies from the ionization chamber, read from a Phillips 7164 ADC. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | ===== S800_FP_CRDC_PACKET ===== | ||
+ | |||
+ | Data from the two S800 CRDCs in the form of digitized waveform samples read from the Jtec XLM72V ULM, and anode energies and times read from a Phillips 7164 ADC. These packet data contain sub packets. The S800_FP_CRDC_RAW_PACKET contains the waveform samples and the S800_FP_CRDC_ANODE_PACKET contains the energies and times. Each CRDC is read out sequentially and it's data preceded by an id word. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where i is the id number (0 or 1). | ||
+ | |||
+ | |||
+ | ==== S800_FP_CRDC_RAW_PACKET ==== | ||
+ | |||
+ | Sub packet of [[S800 version 0x0005# | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where t is the threshold. The waveform data is written using two consecutive words per sample, to be upacked from the following format (binary representation): | ||
+ | |||
+ | < | ||
+ | word 1: hsss ssss sscc cccc | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | word 2: 0000 nndd dddd dddd | ||
+ | </ | ||
+ | |||
+ | where h is the header bit, which should always be 1 for valid CRDC data; | ||
+ | |||
+ | s are the 9 bits of the sample number (maximum number of samples is 512); | ||
+ | |||
+ | c are the 6 bits of the channel number; | ||
+ | |||
+ | n are the 2 bits of the connector number; | ||
+ | |||
+ | d are the 10 bits of data. | ||
+ | |||
+ | ==== S800_FP_CRDC_ANODE_PACKET ==== | ||
+ | |||
+ | Sub packet of [[S800 version 0x0005# | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | ===== S800_FP_HODO_PACKET ===== | ||
+ | |||
+ | Up to 32 Hodoscope energies read from Phillips 7164 ADCs, read in sparse mode, hit patterns read from a LeCroy 4448 Coincidence register, and a time value read from an Ortec 566 TAC via a Phillips 7164 ADC. The type of data to extract is determined from the first word of the packet, the id word. The first 16 energies are associated with id = 0, the second 16 with id = 1 and the hit patterns and time with id = 2. Format: | ||
+ | |||
+ | < | ||
+ | (id = 0,1) 0x000i 0xceee ... | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | (id = 2) 0x000i 0xaaaa 0xbbbb 0xtttt | ||
+ | </ | ||
+ | |||
+ | where i is the id, a is the coincidence register A for the first 16 channels, b the register for the second 16 channels and t the TAC time. | ||
+ | |||
+ | ===== S800_II_TRACK_PACKET ===== | ||
+ | |||
+ | Data from the intermediate image tracking PPAC read from a Jtec XLM72V universal logic module in the form of waveform samples. The S800_II_TRACK_PACKET contains no data and is solely a wrapper for the S800_II_TRACK_RAW_PACKET sub packet. | ||
+ | |||
+ | ==== S800_II_TRACK_RAW_PACKET ==== | ||
+ | |||
+ | Sub packet of [[S800 version 0x0005# | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where t is the threshold. The waveform data is written using two consecutive words per sample, to be upacked from the following format (binary representation): | ||
+ | |||
+ | < | ||
+ | word 1: hsss ssss sscc cccc | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | word 2: 0000 nndd dddd dddd | ||
+ | </ | ||
+ | |||
+ | where h is the header bit, which should always be 1 for valid PPAC data; | ||
+ | |||
+ | s are the 9 bits of the sample number (maximum number of samples is 512); | ||
+ | |||
+ | c are the 6 bits of the channel number; | ||
+ | |||
+ | n are the 2 bits of the connector number; | ||
+ | |||
+ | d are the 10 bits of data. | ||
+ | |||
+ | |||
+ | ===== S800_OB_PIN_PACKET ===== | ||
+ | |||
+ | Energy from the object box PIN detector, read out from a Phillips 7164 ADC. Format: | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | |||
+ | ===== S800_VME_ADC_PACKET ===== | ||
+ | |||
+ | Mesytec 32 channel ADC installed in the main VME crate. Conversion is up to 13 bits. | ||
+ | |||
+ | < | ||
+ | | ||
+ | </ | ||
+ | |||
+ | where i is the id, and four id groups are in the data stream. Information from channels 0-7 is in id 0, 8-15 in id 1, 16-23 in id 2 and 24-32 in id 3. Not all channels may be present. By checking the length word before each packet tag, and unpacking the data word, the non-zero channels can be extracted. The data word format: | ||
+ | |||
+ | < | ||
+ | ccce eeee eeee eeee | ||
+ | </ | ||
+ | |||
+ | where c is the channel within this id (referred to as read_channel). The true adc channel number can be obtained by calculating (id * 8)+read_channel. e is the energy (11-13 bits dependent upon adc setting). | ||