Forum Discussion
Altera_Forum
Honored Contributor
10 years agoFIFO with different widths
I need to read a inputs which is 128 bits wide, but my output is only 16 bits wide. I need to read all the 128 bits. So, having a FIFO would solve my issue.
But now, the thing is that FIFO is generally of a particular width and depth. Having the width same as input will not solve my issue as I will still be reading 128 bits of data. So, I will have to have width of 16 bits. My question here is that how do I write 128 bits of data into this FIFO, as each memory location would have space to store only 16 bits. Please help me with this design issue. Thanks in advance!3 Replies
- Altera_Forum
Honored Contributor
I would just make the fifo 128bits, but just run a counter to mux the output into the appropriate 16 bits. Fairly simple and straight forward logic.
- Altera_Forum
Honored Contributor
You could do a dual width fifo, 128bit input with a 16bit output.
- Altera_Forum
Honored Contributor
I aggree to Tricky and bran. The Megalibrary-function is called mixed-width-fifo.
For reference, please use [1] [1] https://www.altera.com/content/dam/altera-www/global/en_us/pdfs/literature/ug/ug_fifo.pdf