Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

async FIFO - almost full/empty

Status
Not open for further replies.

stanford

Full Member level 2
Joined
Feb 16, 2014
Messages
132
Helped
4
Reputation
8
Reaction score
6
Trophy points
1,298
Activity points
2,223
async fifo - almost full/empty

1. Could you please give me verilog code for generating almost full/empty for async fifo?

2. Do async fifos typically use almost full/empty instead of full/empty for write/read?
 

Re: async fifo - almost full/empty

Hi,

A forum is not meant that someone provides code ...

You should provide the code and we will help to debug it.

Additionally you didn't give any informations where exactly you see the problem.

Klaus
 

Re: async fifo - almost full/empty

Hi,

A forum is not meant that someone provides code ...

You should provide the code and we will help to debug it.

Additionally you didn't give any informations where exactly you see the problem.

Klaus

1. Compare the counters with some margin for 'almost' calculations and the msb for full/empty. Does this look ok?

assign almost_empty = (wr_cnt[n-1] - rd_cnt[n-1] < margin) & (wr_cnt[n] & rd_cnt[n]);
assign almost_full = (rd_cnt[n-1] - wr_cnt[n-1] < margin) & (wr_cnt[n] != rd_cnt[n]);

2. what do we use almost full/empty indication for async fifo?
 
Last edited:

Re: async fifo - almost full/empty

Hi,

Lucky you, you may decide it on your own, unless you have other informations.

You may also ask the person who gave you this job.


Klaus
 

Re: async fifo - almost full/empty

Do async fifos typically use almost full/empty instead of full/empty for write/read?
Yes.
what do we use almost full/empty indication for async fifo?
Required for flow control applications with delayed response. Think about it, you'll surely understand the purpose. If not, just take it as a requirement that needs to be implemented.
 

Re: async fifo - almost full/empty

Yes.

Required for flow control applications with delayed response. Think about it, you'll surely understand the purpose. If not, just take it as a requirement that needs to be implemented.

Then how do you make sure you read out everything in the FIFO, if you stop reading when it's almost empty?

could you give pseudo code to help understand?
 

Re: async fifo - almost full/empty

Hi,

Then how do you make sure you read out everything in the FIFO, if you stop reading when it's almost empty?
When there is an "almost empty" signal, this doesn't necessarily mean that there is no "empty" signal.

But some applications don't need to know the true "empty state". Like a FIFO for a data stream.
In a CD player, for example, there is a FIFO.
The outgoing data rate of this FIFO is quartz stable.. 44100Hz. But the incoming datarate depends on CD spinning speed.
Thus the "almost empty" signal might be used to speed up the motor, while the "almost full" signal might be used to slow down the motor.

Klaus
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top