UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

AR# 9243

C_IP4 COREGEN: How to use the RD_COUNT and WR_COUNT outputs of the Virtex Asynchronous FIFO

Description

Keywords: async, asynchronous, FIFO, rd_count, wr_count

Urgency: standard

General Description:
The use of the RD_COUNT and WR_COUNT output vectors
for tracking the status of the Asynchronous FIFO v1_0 may not
be clear from the description in the v1_0 datasheet. An example
is included below.

Solution

Say you wish to be able to track 4 different states of a 1023-word
deep FIFO--that is, when the FIFO is less than 1/4 full, 1/4 to less
than 1/2 full, 1/2 to less than 3/4 full, and 3/4 or more full. Then
the WR_COUNT will need to support a width of log2(4) = 2 bits to
encode the 4 possible states as 00, 01, 10, and 11. This
corresponds to data count values as shown below for a 1023 word
deep FIFO:
if depth = 1023, this corresponds to:

00: Less than 1/4 full data count < 256
01: 1/4 to less than 1/2 256 <= data count < 512
10: 1/2 to less than 3/4 513 <= data count < 768
11: 3/4 or more full 768 <= data count < 1024

Note that these flags may be off by one to three counts, depending on
what the most recent operations are; however, this is usually not a
problem for most applications. Also note that the particular count you
use will depend on the clock domain you wish to examine the output in.

The problem has been fixed in the 3.x IP Update #2 version of the datasheet.
AR# 9243
Date Created 05/09/2000
Last Updated 10/28/2001
Status Archive
Type General Article