2015-03-06 04:19:29 -05:00
|
|
|
from misoclib.com.liteeth.common import *
|
|
|
|
from misoclib.com.liteeth.generic import *
|
|
|
|
|
|
|
|
def UARTPHY(pads, *args, **kwargs):
|
|
|
|
# Autodetect PHY
|
|
|
|
if hasattr(pads, "source_stb"):
|
2015-03-12 11:57:38 -04:00
|
|
|
from misoclib.com.uart.phy.sim import UARTPHYSim
|
2015-03-06 04:19:29 -05:00
|
|
|
return UARTPHYSim(pads, *args, **kwargs)
|
|
|
|
else:
|
2015-03-12 11:57:38 -04:00
|
|
|
from misoclib.com.uart.phy.serial import UARTPHYSerial
|
2015-03-06 04:19:29 -05:00
|
|
|
return UARTPHYSerial(pads, *args, **kwargs)
|