Forum Discussion
Altera_Forum
Honored Contributor
19 years ago --- Quote Start --- originally posted by queisser@Oct 13 2006, 05:00 AM hi all,
i'm interfacing a ftdi 245 to a cyclone. i have an avalon slave that kind of works but it's very picky and i have to set wait states and hold times just right to make it work.
i'm rewriting the component with flow control (dataavailable and readyfordata) right now but i'm running into a problem with dataavailable. my plan is to raise dataavailable when the chip says it has data and then lower dataavailable at the end of the read. then, when the chip has toggled it's flag i raise dataavailable again. my question:
- when exactly should i lower dataavailable? if i do it too fast (e.g. one clock after the rising edge of read) the bus never reads anything. if i do it too late the bus keeps issuing read cycles too fast and i read the same data over and over. the manual says that dataavailable can only be deasserted at the "end of a cycle" but when is that?
now i'm starting to wonder if the better thing to do would be to use dataavailable only to get the transfer started and then use waitrequest to hold off the bus until the chip is done with a transfer. that raises another question:
- how do i avoid indefinitely stalling the bus if a transfer gets cancelled on the sending side (pc)? should i add a control signal to reset my component or is there something in the avalon bus i can use (e.g. somehow send a reset to the slave device).
thanks,
andrew
<div align='right'><{post_snapback}> (index.php?act=findpost&pid=18663)
--- quote end ---
--- Quote End --- Hi Andrew, I am beginner with NIOS.. I have to use the old code provided by our customer for the new project. There i am seeing 'wait_writerequest' output port in port map of block-ram module. Actually nios core will update the ram and FPGA has to read the ram when required. I am a bit confused with 'wait_writerequest' o/p port.. Usually block-ram wont provide this kind of ports.. Since you are talking on flow-control component.. i am wondering this particular block-ram access might be related flow controlled ram access.. Can you please give some details on flow control component.. and its manual.. I couldn't locate it SOPC component list. Thanks, Siva