1.2.4. FIFO Signals
For the SCFIFO block, the read and write signals are synchronized to the same clock; for the DCFIFO block, the read and write signals are synchronized to the rdclk and wrclk clocks respectively. The prefixes wr and rd represent the signals that are synchronized by the wrclk and rdclk clocks respectively.
Port | Type | Required | Description |
---|---|---|---|
clock 2 | Input | Yes | Positive-edge-triggered clock. |
wrclk 3 | Input | Yes | Positive-edge-triggered clock. Use to synchronize the following ports:
|
rdclk 3 | Input | Yes | Positive-edge-triggered clock. Use to synchronize the following ports:
|
data 4 | Input | Yes | Holds the data to be written in the FIFO Intel® FPGA IP core when the wrreq signal is asserted. If you manually instantiate the FIFO Intel® FPGA IP core, ensure the port width is equal to the lpm_width parameter. |
wrreq 4 | Input | Yes | Assert this signal to request for a write operation. Ensure that the following conditions are met:
|
rdreq 4 | Input | Yes | Assert this signal to request for a read operation. The rdreq signal acts differently in normal mode and show-ahead mode. Ensure that the following conditions are met:
|
sclr 2 aclr 4 |
Input | No | Assert this signal to clear all the output status ports, but the effect on the q output may vary for different FIFO configurations. There are no minimum number of clock cycles for aclr signals that must remain active. By default, the aclr port is enabled. Make sure either aclr or sclr port is enabled and included in the design to ensure the correct functionality of the FIFO. |
q 4 | Output | Yes | Shows the data read from the read request operation. For the SCFIFO function and DCFIFO function, the width of the q port must be equal to the width of the data port. If you manually instantiate the FIFO functions, ensure that the port width is equal to the lpm_width parameter. For the DCFIFO_MIXED_WIDTHS function, the width of the q port can be different from the width of the data port. If you manually instantiate the FIFO function, ensure that the width of the q port is equal to the lpm_width_r parameter. The FIFO function supports a wide write port with a narrow read port, and vice versa. However, the width ratio is restricted by the type of RAM block, and in general, are in the power of 2. |
full 2 wrfull 3 rdfull 3 |
Output | No | When asserted, the FIFO Intel® FPGA IP core is considered full. Do not perform write request operation when the FIFO Intel® FPGA IP core is full. In general, the rdfull signal is a delayed version of the wrfull signal. However, for Stratix® III devices and later, the rdfull signal functions as a combinational output instead of a derived version of the wrfull signal. Therefore, you must always refer to the wrfull port to ensure whether or not a valid write request operation can be performed, regardless of the target device. |
empty 2 wrempty 3 rdempty 3 |
Output | No | When asserted, the FIFO Intel® FPGA IP core is considered empty. Do not perform read request operation when the FIFO Intel® FPGA IP core is empty. In general, the wrempty signal is a delayed version of the rdempty signal. However, for Stratix® III devices and later, t he wrempty signal functions as a combinational output instead of a derived version of the rdempty signal. Therefore, you must always refer to the rdempty port to ensure whether or not a valid read request operation can be performed, regardless of the target device. |
almost_full 2 | Output | No | Asserted when the usedw signal is greater than or equal to the almost_full_value parameter. It is used as an early indication of the full signal. |
almost_empty 2 | Output | No | Asserted when the usedw signal is less than the almost_empty_value parameter. It is used as an early indication of the empty signal. 5 |
usedw 2 wrusedw 3 rdusedw 3 |
Output | No | Show the number of words stored in the FIFO. Ensure that the port width is equal to the lpm_widthu parameter if you manually instantiate the SCFIFO function or the DCFIFO function. For the DCFIFO_MIXED_WIDTH function, the width of the wrusedw and rdusedw ports must be equal to the LPM_WIDTHU and lpm_widthu_r parameters respectively. For Stratix® , Stratix® GX, and Cyclone® devices, t he FIFO Intel® FPGA IP core shows full even before the number of words stored reaches its maximum value. Therefore, you must always refer to the full or wrfull port for valid write request operation, and the empty or rdempty port for valid read request operation regardless of the target device.
Note: Stored data may not be available for reading. Refer to FIFO Output Status Flag and Latency for "wrreq to empty" and "rdreq to empty" latency to ensure that the data is ready before reading the FIFO.
|
eccstatus 6 | Output | No | A 2-bit wide error correction status port. Indicate whether the data that is read from the memory has an error in single-bit with correction, fatal error with no correction, or no error bit occurs.
This port is only available for Arria® 10 devices using M20K memory block type. |
The DCFIFO function rdempty output may momentarily glitch when the aclr input is asserted. To prevent an external register from capturing this glitch incorrectly, ensure that one of the following is true:
- The external register must use the same reset which is connected to the aclr input of the DCFIFO function, or
- The reset connected to the aclr input of the DCFIFO function must be asserted synchronous to the clock which drives the external register.
The output latency information of the FIFO Intel® FPGA IP core is important, especially for the q output port, because there is no output flag to indicate when the output is valid to be sampled.