-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DDR3 Test doesn't do anything #127
Comments
Hi, If it hangs forever, something is wrong. That being said, I never actually finished this test. Looking at the test, it does seem to be more complicated than it needs to be. Let's see what I can do. Also, the modules and interfaces used in the test are documented here: http://www.connectal.org/doc/current/ref/bsv/memreadengine.html |
heh, now I understand what some of that code was for. |
Pushed a simpler version of the test. Building it for vc707 now. (vc707g2) |
I had to add some more cross clock domain constraints to pcie-clocks.xdc. After running the example, I discovered it did not read from system memory, which it should have done. I used pcieflat to look at PCIE transactions. So then I looked at the Makefile, which had the read client commented out. Fixed that and rebuilding... |
I've built the previous commit on nfsume and got some timing violation errors. I include the log here in case you're interested.
|
I pushed a change to pcie-clocks.xdc to fix those timing violation. After building c60f0d5 it ran to completion but the data read back from DRAM did not match what I thought I wrote. Please give it a try -- I may not have time to look at it again until tomorrow. |
The timing issue has gone. I got the following output when run the program.
The writing task may be blocked. |
Please run pcieflat to see if it is doing any DMA. |
I guess it does. Here are the first few lines of the output of running
|
That is good -- at least it did some reads. Usually it's the end of the trace that is more interesting. |
Have you used Vivado Integrated Logic Analyzer? This might be a good time for it. If you add mkProbe in your BSV code, its signals will have (* mark_debug="true" *) so that they show up in the netlist after synthesis. I am interested in how many times rl_req_aw and rl_wdata fire. I would reduce 1024 in Ddr3Test.bsv to 256 or 128. |
This is the end of the trace
|
Hi Jamey, I'm working on Tu's DDR3 project, in order to add DDR3 capability to our Paxos implementation. Can you please answer the following questions?
Thanks |
Hi Pietro, I have not used DDR3 on the SUME board. All the projects using connectal that use DDR3 use the Xilinx MIG. Some of these projects use the DDR3 code in the Bluespec distribution, which was generated by Xilinx MIG. For example: bluespec/lib/board_support/bluenoc/xilinx/VC709/verilog/ddr3_v2_1/ddr3_v2_1 Because connectal is open source, I cannot really check in the output of the MIG, so my approach is to generate the cores as needed. This test application has never been fully debugged, but I think we're close to having it working now. I will spend some more time on it today. |
Thank Jamey, As soon as you update the test, I could run it on the NetFPGA SUME. |
Hi Jamey, While building the DDR3 test application with "make build.nfsume" command, the following error message is generated: Verilog file created: /home/netfpga/github/connectal/tests/ddr3/nfsume/verilog/mkPcieTop.v Do you know how can I solve this issue? Thanks |
make ip.nfsume |
there is a way to make that dependence automatic, so I will fix the makefile. |
Thank you! |
Commit 9b40d04 generates IP cores if the project has synth-ip.tcl. Commit f2717e9 fixes the problem where transferLen was set to zero because I divided by the wrong number. But it turns out the address may be a byte address, so b0bcc05 removes the division and makes transferLen a parameter set by software. Building and testing that one now. |
That version runs but there is still a problem -- it looks to me like the sync fifos are not behaving properly. Either the constraints in pcie-clocks.xdc are not correct or Vivado still does not like either the sync FIFO or the gearbox. When I look a the probes with Integrated Logic Analyzer, the sequence of addresses and data are not what they should be. |
I saw the same behaviour for NetFPGA SUME. Another cause could be the addresses are not parsed correctly. |
I'm tracing the addresses and the output of awfifo is skipping addresses I expect to see. |
Hi, I would like to debug the project with ILA core, as you suggested to Tu. The BSV code of the project already includes "mkprobe", but no ILA probe is included into the generated bitfile. How can I generate the probes? Thank you! |
I tried to have a fully script solution to incorporate the ILA but so far have not succeeded. Here is the process for nfsume: When it has written top-post-link.dcp I start vivado from another shell: From vivado, I manually instantiate the ILA. The problem that prevents scripting is any constant values attached to the probes because Vivado cannot figure out the clock. I either remove these nets or attach the same clock as used by the other signals of a bus. After the ILA is instantiated:
Now open the hardware manager and program the board. I usually do this from a machine separate from the test machine, especially on a test like this that has a chance of locking up the machine. Once you have the trigger set up and you're ready to capture data, on the test machine:
If you do not define NOPROGRAM, it will reprogram the FPGA. |
In commit c30c882 I replaced mkSyncFIFO with mkDualClockFifo, my own import BVI wrapper for Xilinx's FIFO18. That improved the situation. I reconfigured the gearboxes so both ends were on the same clock domain and introduced mkDualClockFifo to cross the clock domain. Now the test is reading back from DRAM the same values it wrote to DRAM. I updated the test to count and display mismatches in commit 84d0e03 Please give the new version a try. |
The new version seems to work fine. Now we can add DDR3 capability to our project. Thanks! |
Hi, I would like to re-build the DDR3 example in order to make some changes into the provided *.cpp code. I have attached here only a small subset of the warnings: Warning: "/home/netfpga/gitHub/connectal/bsv/PcieTop.bsv", line 76, column 8: (G0036) Pietro |
The error that causes the build to stop is below. The other issues are warnings. I'm not sure if they can be safely ignored. Warning: "/home/netfpga/gitHub/connectal/bsv/PcieTop.bsv", line 76, column 8: (G0117) |
There is another issue. The BOARD variable in the makefile doesn't seem to get set correctly. You can see in the first invocation that the grep is looking for "".json. $ make clean |
instead of doing make clean, you can just delete the nfsume directory. |
This error: XCI file /home/netfpga/gitHub/connectal/out/nfsume/axiddr3/axiddr3.xci not found make ip.nfsume |
@hanw, the issue is not that the clean target doesn't exist. It is that for any makefile target, the BOARD variable isn't getting set correctly. So, replace 'make clean' with 'make build' or any other command, and you'll get the same error related to grep. |
@hanw @jameyhicks : we tried to run make ip.nfsume, but the target is not in the Makefile. Perhaps it was removed when the Makefile was refactored a few days ago? |
can you try make build.nfsume ? BOARD is set by the suffix. |
@hanw, sorry, you're right. Perhaps the reason we didn't see BOARD set is because we didn't have a target for ip.nfsume. So, the two issues are from the same problem. |
I removed ip.nfsume in a recent refactor. Unfortunately, I attached the command to build the XCI files to the wrong rule. Commit c7d5b82 fixes that problem. |
Hi Jamey,
I'm able to build the tests/ddr3 but I observe that the test doesn't do anything. The test is wrapped in an IF statement which never fires.
https://github.com/cambridgehackers/connectal/blob/master/tests/ddr3/testddr3.cpp#L56
I've removed the ``if'' to see how it works. The program just hangs forever.
I would like to read and write to DDR3 but it's difficult to follow the test. It's great if you could help me to rewrite the test or an example to use DDR3 with Connectal.
The text was updated successfully, but these errors were encountered: