|
entity CandidateBucketMini-Lifo to hold muon candidates of one energy. |
The CandidateBucket acts like a Lifo (last in first out). Its functionality is determined by the status of the read_write line. If it is '0' data can be written into the Lifo at the next clock. If it is '1' they can be read. Input and Ouput of the Lifo are separated. Two flags indicate when the Lifo is full or when data have been lost due to writing into a full Lifo. Write and Read actions are possible only if the enable line is activated.
The CandidateBucket is used in the CandidateSelector.
Generics:
| WIDTH | determines the data word width. MUST be at least 2. |
| DEPTH | determines the depth of the Lifo in words. |
Ports:
| sclr | clears the whole Lifo and resets the flags. It is the only possibility to reset the data_loss flag. |
| read_write | determines the functionality: '1' means reading enabled, '0' means writing enabled. |
| input | is the data input. |
| not_empty | is a flag indicating the presence of data in the Lifo. |
| full | indicates that the Lifo is full. |
| data_loss | indicates that the Lifo has been written although it was already full. The oldest dataword got lost. The only way to clear this flag is applying sclr. |
| q | is the data output. |
See also: CandidateSorter