--- Quote Start ---
Hi, I haven't look at the schematic of the board neither functionnal chronogram nor truth table. So I may be wrong.
But it sounds quite trivial : read data from one component and write data to an other component. Even if we talk about one component : codec but it can be considered as 2 independant components : coder and decoder.
In your code above, you wrote process(
clock_50) but clock_50 is not used in the process.
First draw a very simple schema with D flip flops and translate it to VHDL. VHDL is a hardware
description language.
You spent too much time by trying to make it work by "trial and error".
I hope the board is functionnal ;-)
--- Quote End ---
I agree that it sounds trivial, and when written trivially it works. Yet as soon as I check read_ready or write_ready, it fails.
The board is working fine, it is a new DE2-115 board. Without checking read_ready and write_ready the code echoes audio in to out as expected. Clear and at full volume.
Referencing process(Clock_50) makes no difference, I can ignore it or not, the code works or doesn't work only based on read_ready or write_ready. I just put that Clock_50 in so I could add a "process" statement (and in turn an 'if' statement to check read_ready) and not get a compile error. I've tried making the process dependent on other signals. It works or doesn't only based on read/write_ready.
I've tried code similar to what you've got above, two separate processes, one reading and one writing. I added an extra variable so that the reading process could pull the data in when it was available and the write process had somewhere to write it out from. It made sense, but I was using read_ready and write_ready, so none of it worked. As soon as make my code dependent on read_ready and write_ready, it fails.
It would be nice if someone with a DE2-115 board and more experience than I've got could run a real test, or else message me the official solution so I could try that and see what I'm missing. I would really love to see a verified working solution that references read_ready/write_ready, as the lab requires.