2014-09-22 06:33:23 -04:00
|
|
|
from mibuild.generic_platform import *
|
2015-03-01 05:03:15 -05:00
|
|
|
from mibuild.platforms import kc705
|
2014-09-25 09:37:49 -04:00
|
|
|
|
2015-03-01 05:03:15 -05:00
|
|
|
_sata_io = [
|
2015-05-23 08:08:56 -04:00
|
|
|
("sata_clocks", 0,
|
2015-04-13 08:55:26 -04:00
|
|
|
Subsignal("refclk_p", Pins("HPC:GBTCLK0_M2C_P")),
|
2015-05-23 08:08:56 -04:00
|
|
|
Subsignal("refclk_n", Pins("HPC:GBTCLK0_M2C_N"))
|
|
|
|
),
|
|
|
|
("sata", 0,
|
2015-04-13 08:55:26 -04:00
|
|
|
Subsignal("txp", Pins("HPC:DP0_C2M_P")),
|
|
|
|
Subsignal("txn", Pins("HPC:DP0_C2M_N")),
|
|
|
|
Subsignal("rxp", Pins("HPC:DP0_M2C_P")),
|
2015-05-23 08:08:56 -04:00
|
|
|
Subsignal("rxn", Pins("HPC:DP0_M2C_N"))
|
|
|
|
),
|
|
|
|
("sata", 1,
|
|
|
|
Subsignal("txp", Pins("HPC:DP1_C2M_P")),
|
|
|
|
Subsignal("txn", Pins("HPC:DP1_C2M_N")),
|
|
|
|
Subsignal("rxp", Pins("HPC:DP1_M2C_P")),
|
|
|
|
Subsignal("rxn", Pins("HPC:DP1_M2C_N"))
|
|
|
|
),
|
|
|
|
("sata", 2,
|
|
|
|
Subsignal("txp", Pins("HPC:DP2_C2M_P")),
|
|
|
|
Subsignal("txn", Pins("HPC:DP2_C2M_N")),
|
|
|
|
Subsignal("rxp", Pins("HPC:DP2_M2C_P")),
|
|
|
|
Subsignal("rxn", Pins("HPC:DP2_M2C_N"))
|
|
|
|
),
|
|
|
|
("sata", 3,
|
|
|
|
Subsignal("txp", Pins("HPC:DP3_C2M_P")),
|
|
|
|
Subsignal("txn", Pins("HPC:DP3_C2M_N")),
|
|
|
|
Subsignal("rxp", Pins("HPC:DP3_M2C_P")),
|
|
|
|
Subsignal("rxn", Pins("HPC:DP3_M2C_N"))
|
2015-04-13 08:55:26 -04:00
|
|
|
)
|
2014-09-22 06:33:23 -04:00
|
|
|
]
|
|
|
|
|
2015-04-13 09:12:39 -04:00
|
|
|
|
2015-03-13 20:08:36 -04:00
|
|
|
class Platform(kc705.Platform):
|
2015-04-13 08:55:26 -04:00
|
|
|
def __init__(self, *args, **kwargs):
|
|
|
|
kc705.Platform.__init__(self, *args, **kwargs)
|
|
|
|
self.add_extension(_sata_io)
|
2014-09-22 06:33:23 -04:00
|
|
|
|
2015-04-13 08:55:26 -04:00
|
|
|
def do_finalize(self, fragment):
|
|
|
|
try:
|
|
|
|
self.add_period_constraint(self.lookup_request("clk156").p, 6.4)
|
|
|
|
except ConstraintError:
|
|
|
|
pass
|
|
|
|
try:
|
|
|
|
self.add_period_constraint(self.lookup_request("clk200").p, 5.0)
|
|
|
|
except ConstraintError:
|
|
|
|
pass
|
|
|
|
self.add_platform_command("""
|
2014-12-17 12:03:11 -05:00
|
|
|
set_property CFGBVS VCCO [current_design]
|
|
|
|
set_property CONFIG_VOLTAGE 2.5 [current_design]
|
2014-10-24 13:24:05 -04:00
|
|
|
""")
|