Heading3 - aempty_offset, Heading2 - status flags, Heading3 - empty flag – Achronix Speedster22i User Macro Guide User Manual

Page 182: Heading3 - almost empty flag, Heading3 - full flag, Heading3 - almost full flag, Status flags

Advertising
background image

Memories

LRAMFIFO

Speedster22i Macro Cell Library

Achronix Semiconductor Proprietary

PAGE 165

Table 6-56: Condition to Assert almost_full Flag based on afull_offset Parameter Assignment

Condition when

almost_full flag is asserted

Condition when almost_full flag is

deasserted

afull_offset or fewer empty loca-
tions remain in the FIFO.

There are at least (afull_offset +1) empty
locations remaining in the FIFO.

aempty_offset

The  aempty_offset  parameter  defines  the  word  depth  at  which  the  FIFO  almost_empty 
changes. The almost_empty flag may be used to determine the number of blind reads from the 
FIFO  that  can  be  performed  without  monitoring  the  empty  flag.    For  example,  if  the 
aempty_offset  parameter  is  set  to  7’h04  and  the  almost_empty  flag  is  deasseted,  the  user  is 
guaranteed that  there  are at least five words in the FIFO.  The user may  read  all five  words 
without monitoring the empty flag and be guaranteed that these words will be read from the 
FIFO  and  the  read_err  flag  will  not  be  asserted.  The  default  value  of  the  aempty_offset 
parameter is 7’h04, corresponding to four or fewer words remaining in the FIFO.

Table 6-57: Condition to Assert almost_empty Flag based on aempty_offset Parameter Assignment

Condition when

almost_empty flag is

asserted

Condition when almost_empty flag is

deasserted

aempty_offset or fewer
words remain in the FIFO.

There are at least (aempty_offset +1) words in
the FIFO.

Status Flags

Empty Flag

The Empty (empty) flag is asserted after the FIFO is reset or when all of the data has been read 
from the FIFO.  The Empty flag is synchronous to the rdclk clock domain.  Further attempts to 
read the FIFO when the Empty flag is asserted will be blocked, the Read Error (read_err) flag 
will be set in the following rdclk clock cycle, and the Read Pointer will remain unchanged. 

Almost Empty Flag

The  Almost  Empty  (almost_empty)  flag  is  asserted  when  there  are  aempty_offset  or  fewer 
words remaining in the FIFO (See 

Table 6‐57:  Condition to Assert almost_empty Flag based 

on aempty_offset Parameter Assignment

).  The almost_empty flag may be used to determine 

the number of blind reads from the FIFO that can be performed without monitoring the empty 
flag.  For example, if the aempty_offset parameter is set to 7’h04 and the almost_empty flag is 
deasserted, the user is guaranteed that there are at least five words in the FIFO. The user may 
read all  five words without monitoring the  empty flag  and be  guaranteed that  these  words 
will be read from the FIFO and the read_err flag will not be asserted. The Almost Empty flag 
is synchronous with the rdclk clock input.

Full Flag

The Full (full) flag is asserted when all of the available locations of the FIFO have been written. 
It is synchronous to the wrclk clock domain.  Further attempts to write the FIFO when the Full 
flag  is  asserted  will  be  blocked,  the  Write  Error  (write_err)  flag  will  be  set  in  the  following 
wrclk clock cycle, and the Write Pointer will remain unchanged.

Almost Full Flag

The  Almost  Full  (almost_full)  flag  is  asserted  when  there  are  afull_offset  or  fewer  available 
locations remaining in the FIFO.  The almost_full flag may be used to determine the number 

Advertising