Electronic – How to make an external PCI adapter that runs on USB3.0

adapterdesignpcieusb device

Motivated by old PCI (NOT PCIe) cards, and laptops without expansion slots, I want to try making a PCI-over-USB 3.0 solution. This is about 70% experimentation, and 30% actual use.

Is this viable? I was thinking of buying something like this Cypress USB controller, in conjunction with a PCI bus master board, and (I'm guessing) a microcontroller to interface the two.

I'm not experienced in this, which is why I want to learn… I am an EE, but not this advanced.

Is this doable? Would it be possible as a long term learn-and-do project?

Best Answer

There are two challenges:

  1. Latency

    USB has two orders of magnitude higher latency than PCI. Many PCI drivers assume memory mapped access to registers on the PCI card with the CPU blocking on the bus transaction. Unmodified PCI drivers over a PCI-over-USB bridge are likely to fail because of wrong latency assumptions.

    Check this study on PCI latency: PCI mean latency is in the order of 400ns, PCIe mean latency is in the order of 2000ns. USB 3.0 latency according to the article you linked is in the order of 30us.

  2. Bus vs. Packet Network

    While PCI is a bus, PCIe and USB are packet based networks. The PCIe root bridge hides the complexity of a packet network and presents the CPU with something that looks like a bus. Doing the same thing over USB is certainly possible, but if you want binary compatible drivers your hardware interface towards the CPU has to look more or less like PCI and you will end up with something like a PCIe root bridge. This is probably not something that can be achieved by common USB chipsets with *HCI interfaces.