litex/misoc/com/uart/phy/__init__.py

9 lines
318 B
Python
Raw Normal View History

2015-03-06 04:19:29 -05:00
def UARTPHY(pads, *args, **kwargs):
# Autodetect PHY
if hasattr(pads, "source_stb"):
2015-09-22 12:35:02 -04:00
from misoc.com.uart.phy.sim import UARTPHYSim
return UARTPHYSim(pads, *args, **kwargs)
else:
2015-09-22 12:35:02 -04:00
from misoc.com.uart.phy.serial import UARTPHYSerial
return UARTPHYSerial(pads, *args, **kwargs)