-
Notifications
You must be signed in to change notification settings - Fork 5
Setup
x44203 edited this page Dec 20, 2021
·
2 revisions
The setup consists of one ECP5 Versa evaluation board plugged into the PCIe slot of a ROCKPro64.
A second computer to program on and conduct the tests is required.
- Set SW4 to 1: Down, 2: Up, 3: Down, 4: Down
- Connect pins 2-4 and 5-6 on J50
- Run
openocd -f ispCLOCK/ispCLOCK-200MHz.cfg
- Connect pins 1-2 and 3-5 on J50
- Connect 2-4 and 3-5 on J4 (Connects the
PRSNT
signals on the PCIe connector and sets the ispCLOCK to PCIe clock input)
- Get an SD card and connect it to your computer
- Download this and this
- Execute
dd if=mmc_idbloader.img of=/dev/your_sd_card seek=64 status=progress
- Execute
dd if=mmc_u-boot.itb of=/dev/your_sd_card seek=16384 status=progress
- Execute
sync
- Remove the SD card and plug it into the ROCKPro64
- Plug the Versa into the ROCKPro64, connect a 12 V adapter to the ROCKPro64 but not to the Versa and do not power it yet, connect a USB cable from the Versa to your computer
- Connect a UART configured to 3.3 V (for example a CH340) to the ROCKPro64, GND to pin 6 on the PI-2-bus, RX to pin 8, an unconnected cable to pin 10
- Open a serial terminal
- Power the 12 V adapter and watch the terminal
- As soon as you can see it booting on the terminal, connect the unconnected cable from pin 10 to TX on the UART
- As soon as it says that it is going to start the OS, press some key on the terminal to abort it, such that it goes to u-boot
- Now there should be a prompt showing
=>
- Execute
python test_pcie_phy.py run
orpython test_pcie_ltssm.py run
from the Tests folder and wait until it is uploaded (sometimes the timing doesn't pass and you need to repeat it) - Execute
pci enum
on the ROCKPro64. Sometimes it saysLink down
, then you need to repeat and it should sayPCIE-0: Link up (Bus0)
and immediately crash / reboot - Press some key again to abort booting and you can try again
You can re-upload the last compiled gateware by executing
For more information read Physical Tests
On X3:4 is a clock output of the RX clock and on X4:28 for TX.