This test aims at providing a minimal DDR design. The design is tested with a python script that provides memory control signals to the DDR controller using an UART bridge.
The script performs the calbiration process, therfore it looks for the bitslip as well as the delay values.
The litex module used is LiteDRAM, which should be checked-out at the correct commit:
| Repo URL | SHA | | --- | --- | | <https://github.com/antmicro/litex> | 3350d33 | | <https://github.com/enjoy-digital/litedram> | d8f3feb | | <https://github.com/m-labs/migen> | d11565a |
There are two different ways to test this design:
cd src.vivado make
cd src.yosys make
To test the implemented design, load the bitstream produced in the previous step, and do the following:
lxserver --uart --uart-port=/dev/ttyUSBX
cd scripts make test_sdram
Depending on the clock frequency selected during the gateware generation, different outputs are generated:
50 MHz sysytem clock:
Minimal Arty DDR3 Design for tests with Project X-Ray 2020-02-03 11:30:24 Release reset Bring CKE high Load Mode Register 2, CWL=5 Load Mode Register 3 Load Mode Register 1 Load Mode Register 0, CL=6, BL=8 ZQ Calibration bitslip 0: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|31| bitslip 1: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 2: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 3: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 4: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 5: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 6: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 7: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|
100 MHz system clock:
Minimal Arty DDR3 Design for tests with Project X-Ray 2020-01-31 15:41:14 Release reset Bring CKE high Load Mode Register 2, CWL=5 Load Mode Register 3 Load Mode Register 1 Load Mode Register 0, CL=6, BL=8 ZQ Calibration bitslip 0: |00|01|02|03|04|05|06|07|08|09|10|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 1: |..|..|..|..|..|..|..|..|..|..|..|..|..|13|14|15|16|17|18|19|20|21|22|23|24|25|..|..|..|..|..|..| bitslip 2: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|29|30|31| bitslip 3: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 4: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 5: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 6: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..| bitslip 7: |..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|..|