eFEX firmware  1.7.3
ATLAS l1-calo - electron and tau feature extraction firmware for eFEX boards

Back to eFEX documentation
Entities
TOBs_rdout.vhd File Reference

Merged Sorted TOB and Local XTOB Readout Logic for process FPGA. More...

Go to the source code of this file.

Entities

TOBs_rdout  entity
 Merged Sorted TOB and Local XTOB Readout Logic for process FPGA. More...
 
RTL  architecture
 Merged Sorted TOB and Local XTOB Readout Logic for process FPGA. More...
 

Detailed Description

Merged Sorted TOB and Local XTOB Readout Logic for process FPGA.

This module received Merged Sorted TOB and Local XTOB data and produces events of 32b words for transmission to control FPGA

Global Sorted TOBs and Local XTOB Readout Logic Block Diagram

This module is only instanstiated for Process FPGA 1 and 2, and is disabled for Process FPGA 3 and 4.

Different TOB/XTOB data event are generated depending on FPGA Number, buffer levels and control settings.

The Merging FPGAs generate TOB/XTOB data events which consist of maximum 20 tau XTOBs, 20 e/g XTOBs and up to 6 TOBs.

The Non-Merging FPGAs generate XTOB data events which consist of maximum 20 tau XTOBs, 20 e/g XTOBs and do not include Merged TOBs.

  1. Readout operation for Process FPGAs 1 & 2, create Events which consists of only Valid XTOB/TOBs.
    • TOB & XTOB Event in Normal Operation:
      • Read 1 Slice - Takes 179 ticks of 280MHz clock to create one TOB & XTOB Event with 1 Slice Readout.
    • TOB & XTOB Event in Normal Operation:
      • Read 2 Slice - Takes 352 ticks of 280MHz clock to create one TOB & XTOB Event with 2 Slice Readout.
    • TOB & XTOB Event in Normal Operation:
      • Read 3 Slice - Takes 524 ticks of 280MHz clock to create one TOB & XTOB Event with 3 Slice Readout.
    • TOB & XTOB Event in Normal Operation:
      • Read 4 Slice - Takes 697 ticks of 280MHz clock to create one TOB & XTOB Event with 4 Slice Readout.
    • TOB & XTOB Event in SAFE Mode Operation:
      • Read 0 Slices - Takes 8 ticks of 280MHz clock to create one SAFE Mode TOB & XTOB Event.
  2. Readout operation for Process FPGAs 3 & 4, create Events which consists of only Valid e/g and tau XTOBs..
    • XTOB Event in Normal Operation: Read 1 Slice - Takes 171 ticks of 280MHz clock to create one XTOB Event with 1 Slice Readout.
    • XTOB Event in Normal Operation: Read 2 Slice - Takes 344 ticks of 280MHz clock to create one XTOB Event with 2 Slice Readout.
    • XTOB Event in Normal Operation: Read 3 Slice - Takes 516 ticks of 280MHz clock to create one XTOB Event with 3 Slice Readout.
    • XTOB Event in Normal Operation: Read 4 Slice - Takes 691 ticks of 280MHz clock to create one XTOB Event with 4 Slice Readout.
    • XTOB Event in SAFE Mode Operation: Read 0 Slice - Takes 8 ticks of 280MHz clock to create one SAFE Mode XTOB Event.

Sequence of Buffers occupancy levels:

  1. When the Ready signal from Control FPGA is removed, complete TOB/XTOB Events are stored in TOB/XTOB Link Output FIFO.
    • When the occupancy of TOB Link Output FIFO reaches its prog FULL occupancy level, then the construction of TOB/XTOB Events are paused.
    • Enough headroom must be assigned in Link Output FIFO to be able to store TOB/XTOB Events under Safe Mode operation.
  2. At this point, TOB/XTOB data are still transferred from Circular DPRAM into de-randomisation TOB/XTOB Data FIFO.
    • When the occupancy of de-randomisation TOB/XTOB Data FIFO or TTC FIFO reaches its prog FULL occupancy level,
    • A Safe Mode Flag is set which is used to create Safe Mode TOB/XTOB events and empty the TOB/XTOB Data FIFO & TTC FIFO.
    • These Safe Mode events consists of 2 Header words, and one Trailer word.
    • The payload consists of two words, a ZERO word together with a sub-trailer word for the slice.
    • Multi-slice readout contains a number of these double words, equal to the number of slices to be readout.
    • A BUSY request must be sent to HUB/ROD to reduce L1A rates at this time.
    • In Safe Mode, all buffers, except TOB/XTOB Link Output FIFO, are flushed, and very small TOB/XTOB Events are generated and stored in Link Output FIFO.

Under Safe Mode operation if the occupancy of TTC FIFO or TOB/XTOB Data FIFO, reaches its FULL occupancy level, then the system synchronisation is lost.

The output of TOB Readout is:

Header Word 1:

Header Word 2:

Trailer Word 1: Slice Trailer

Trailer Word 2: Event Trailer

CHAR constants are defined in data_type_pkg.vhd

TRIGGER SLICE:

07/03/2024 Due to intermitent read error of L1_ID, and further investigations, we found that the input to L1_ID & BNCN FIFO has crossed clock domain from 40MHz to 280MHz. To rule out this may be the cause of error, it was decided to remove read_on_err_in signal from the slice trailer and set it to ZERO.

Author
Saeed Taghavi

Definition in file TOBs_rdout.vhd.