| Data Inputs |
There are 5 separate inputs to the DF module, one from each of the 3 phonon ADC chips and from each of the 2 charge ADC chips. Each ADC input is processed in a separate DF submodule. Each phonon ADC output includes 4 parallel channels, while each charge ADC output includes 2 parallel channels.
|
| Configuration and Control Inputs |
|
| Outputs |
There are 5 separate streaming outputs, which go to the
Synchronizer module. Each DF submodule pushes out the
outputs from the corresponding input channels.
|
| Internal Registers |
This module requires some information to be retained from one time step to the next. It will
be stored in internal registers which are not visible or accessible from outside the module.
They are mentioned and named here in order to simplify the detailed description of the
module's functionality given below.
|
| Tuned parameters |
There are a few parameters which much be specified to define our CIC filters. More detail
about some of the parameter choices can be found below. These
parameters have been chosen in a qualitative, heuristic fashion. They may need to be
re-tuned once early noise and pulse data from SNOLAB is available.
|
| Functionality |
Brief functional description:
The full sampling rate of the phonon channels (625 kHz) and charge channels (2.5 MHz) needs to be reduced in order to maximize the sensitivity of the trigger. This sensitivity optimization involves a tradeoff between a high sampling rate (which allows access to higher-frequency information) and a longer baseline for the Finite Impulse Response (FIR) module (which allows access to lower-frequency information). Downsampling by a larger factor reduces the sampling rate and lengthens the baseline. Downsampling by a smaller factor increases the sampling rate and shortens the baseline. This module downsamples both the phonon and charge channels to 39.0625 kHz. The choice of 39.0625 kHz seems, judging from Soudan detector pulses, to provide a good balance between low-frequency and high-frequency information, leading to a sensitive trigger while conserving FPGA resources. Any downsampling procedure will result in aliasing of high-frequency components down to lower frequencies. Our signals mostly occupy low frequencies, and the higher frequencies are dominated by noise. Therefore we want to filter out the high-frequency components before downsampling so that our signals are not swamped by aliased noise. To do this we have chosen a Cascaded Integrator-Comb (CIC) filter to reduce aliased noise. For more details on how CIC filters work and are implemented, we recommend starting with the wikipedia page. The CIC filter is chosen for certain desirable properties:
A CIC filter is a cascade of moving-average filters (a moving average of a moving average of a moving average) in the time domain. In the case of one of our phonon submodules, we have $R=16$, $N=3$, $M=1$. Thus each value of the output is a triple sum of recent input samples: \[y[n] = \sum_{j=0}^{15} \sum_{k=0}^{15} \sum_{l=0}^{15} x[n - j - k - l] \text{, where}\]
To understand the performance of this cascaded moving average as an anti-aliasing filter, we should look at the frequency response function. The frequency response function tells us whether this filter adequately attenuates noisy high frequencies while transmitting the desired low frequencies. In the frequency domain, each value of the output $\tilde{y}(\omega)$ is derived from multiplying the input $\tilde{x}(\omega)$ by the filter's frequency response function \(H(\omega)\): \[\tilde{y}(\omega) = H(\omega) \tilde{x}(\omega), \text{where}\]
This module is implemented as an Altera CIC IP Core, which requires certain parameters to be set at design time in order to specify the exact functionality that is needed from a fairly general-purpose piece of code. The list of parameters and the values we use are given later in this document (CIC IP Core parameters). Our choice of the parameters \(R\), \(M\), and \(N\) is somewhat qualitative and heuristic, since we do not yet know the exact characteristics of the pulses we will record in the SNOLAB detectors. We anticipate re-visiting these parameter choices once we have early data from SNOLAB. At that point it will be simple to take random-triggered data and pulse data and re-optimize the CIC parameters based on the noise and signal. Currently, we envisision the following values:
The output of a CIC filter necessarily has more bits than the input. The number of additional bits is \(N \log_2 (RM)\) 2. For each phonon channel, this is 12 additional bits for a total of 26 bits. For the charge channels, this is 18 additional bits for a total of 34 bits. More detailed description (including data transfer information):We will instantiate five copies of the CIC IP Core, one for each of the 5 DF submodules: three will handle the three phonon ADC inputs, and the remaining two will handle the two charge ADC inputs. The CIC IP Core handles downsampling of multiple channels simultaneously. It requires that the data from all its input channels is presented simultaneously and in parallel. The samples that compose one ADC input arrive simultaneously and in parallel, which is a perfect match for this requirement. The input to the CIC IP Core is an Avalon-ST stream, but the outputs from the ADC module are not in this format already, so we need to put them into the Avalon-ST format. The CIC IP Core input requires several signals:
To cause the CIC IP Core to process an input, we must wait for the "ready" signal to be asserted, then set (latched in an internal register) the data signals to represent the data we plan to send to CIC IP Core, then assert the "valid", start-of-packet, and end-of-packet signals. Then, after a rising clock edge has passed, the "valid", start-of-packet, and end-of-packet signals should be deasserted. The reason that we assert and deassert the start- and end-of-packet signals together is that all our data will be sent in parallel on a single clock cycle, so our output "packet" is just one datum long, and its start and end occur simultaneously. The following description is at a very high level because we are not implementing the CIC filter ourselves. Instead, we are using the CIC IP Core from Altera. Since it is closed source, we only describe in general terms what is done. Step-by-stepOn each rising clock edge, do the following:
Reset Signal:When the reset signal is asserted,
|
| Notes |
|
| Testing Plan |
| CIC Filter Specification Parameter | Value |
| Filter type | Decimator |
| Number of stages (\(N\)) | 3 |
| Differential delay (\(M\)) | 1 |
| Enable variable rate change factor | Off |
| Rate change factor (\(R\)) | 16 (phonon) or 64 (charge) |
| Number of interfaces | 4 (phonon) or 2 (charge) |
| Number of channels per interface | 1 |
| Input data width | 14 bits (phonon) or 16 bits (charge) |
| Output rounding options | None |
| Output data width | Calculated by CIC IP Core |