There are two consumers of the MuID raw data - the LVL1 trigger and the DCMs. Both of these consumers need the bit pattern of struck tubes out of the MuID. (Zero-suppresion may happen at a later stage). Both of these consumers use a 20-bit G-link communication protocal to communicate with the FEMs. But the LVL1 G-link runs at 6 * Beam Clock and has one clock cycle to pass all of its data, while the DCM G-link runs at 2 * Beam Clock, and gets 256 clock ticks to pass all of its data. Since the MuID passes exactly the same information to the DCM and LVL1, its communication with LVL1 must run in parallel. In fact, there is one LVL1 G-link per Readout Card (ROC) and there are 20 ROCs per DCM. (There are 4 DCMs and 80 LVL1 G-links total).
The MuID ROCs have 6 16-channel inputs. Since we are not pressed for bit space the simplest approach to data formatting is to pack each 16-bit input into one 20-bit word. This is illustrated in figure 1 below.
Figure 1. Mapping of ROC inputs into data words for communication to LVL1 and DCM.
The six words per ROC are transmitted to the LVL1 via one 6 * Beam Clock LVL1 G-link. These six words from each of the 20 ROCs in a FEM crate are also communicated via the backplane to the Heap Manager where they are collected and sent to the DCM for that FEM crate.
Both LVL1 and DCM (or wherever zero-suppression occurs) also need to know the cable/ROC/slot mapping. This is somewhat arbitrary, and a proposed scheme is shown in figure 2 below:
Figure 2.MuID channel/ROC mapping. The cables from each gap fill 4 ROCs (per orientation) The 4 ROCs for each gap have an identical mapping that is arbitrarily chosen. The 4 ROCs for each gaps are arbitrarily chosen to begin in the lowest numbered slot. Horizontal and vertical FEMs have slightly different mappings because there are fewer vertical input cables.
To summarize, figure 3 shows the data portion of the event data passed to the DCM. The words sent to each LVL1 G-link are shown on the right.
Figure 3.Summary of data portion of event data sent to a MuID DCM. There are four DCMs total (North-Horizontal, North-Vertical, and repeated for South). Words 11 and 23 are different depending on whether the DCM is for horizontal or vertical tubes. There are a total of 120 20-bit words per DCM. There is a one-to-one correspondence between DCM words and LVL1 words.