Changeset 10155 for firmware/FAD/doc
- Timestamp:
- 02/15/11 12:07:05 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
firmware/FAD/doc/memory_manager.tex
r10150 r10155 194 194 0x200A & trg pos 3 & trg pos 2 & trg pos 1 & trg pos 0 \\ 195 195 0x200B & ROI 3 & ROI 2 & ROI 1 & ROI 0 \\ 196 0x200C & data adc3 & data adc2 & data adc1 & data adc0 \\ 196 0x200C & -fill- & -fill- & -fill- & -fill- \\ 197 0x200D & data adc3 & data adc2 & data adc1 & data adc0 \\ 197 198 0x20.. &&&& ... \\ 198 0x20 6F& data adc3 & data adc2 & data adc1 & data adc0 \\199 0x2070 & data adc3 & data adc2 & data adc1 & data adc0 \\ 199 200 \hline 200 201 0x20.. &&&& ... \\ … … 203 204 0x23?? & trg pos 3 & trg pos 2 & trg pos 1 & trg pos 0 \\ 204 205 0x23?? & ROI 3 & ROI 2 & ROI 1 & ROI 0 \\ 206 0x23?? & -fill- & -fill- & -fill- & -fill- \\ 205 207 0x23?? & data adc3 & data adc2 & data adc1 & data adc0 \\ 206 208 0x23.. &&&& ... \\ … … 318 320 unsigned short start_cell; 319 321 unsigned short roi; 322 unsigned short filling; 320 323 unsigned short adc_data[]; 321 324 } __attribute__((__packed__)) PCHANNEL; … … 327 330 \end{verbatim} 328 331 332 \subsection{mem manager calculations} 333 334 Memory manager knows the size of FADs internal data RAM. This is implemented as VHDL-Generics called {\tt RAM_ADD_WIDTH_64B} 335 and {\tt RAM_ADD_WIDTH_16B}. Since word width is 64bit on the input side and 16bit on the outpt two generics are used. 336 Currently the values are: 337 \begin{table}[htbp] 338 \begin{tabular}{ll} 339 RAM_ADD_WIDTH_64B & 12 \\ 340 RAM_ADD_WIDTH_16B & 14 \\ 341 \end {tabular} 342 \caption{values of RAM width} 343 \label{RAM_GENERICS} 344 \end{table} 345 346 Which results in 347 \begin{equation} 348 \mathtt{RAM size} = 2^{12} \cdot 8 byte= 2^14 * 2 byte = 32768 byte . 349 \end{equation} 350 351 Now the memory manager is able to calculate the number of Events, fitting into this RAM. 352 353 The number of samples of each channel beeing digitized is called region of interest(ROI). Since the ROI of each of the 36 input channel may be defined independently, but the RAM is organized in 64bit words on the input side, the memory manager needs to calculate the effective ROI of each channel first. The DRS Chips are digitized in a parallel manner, but their 9 channels are digitized serially. So first each DRS is ordered to output its channel 0 data, until as many samples are digitized as the maximum of all channel 0 ROIs is. 354 355 In the states called MAX_ROI0..2 the array containing the maxima of each group of channels is calculated. 356 In addition the so called channel size array is calculated. This is the number of 16bit words which is needed to store a group of 357 channels in the W5300 FIFO. The header is included into the group of channels 0, while the package footer is included into group of channels 9. 358 359 In the next state called FIFO CALC. Here 360 361 329 362 330 363 \end{document}
Note:
See TracChangeset
for help on using the changeset viewer.