mirror of https://github.com/m-labs/artiq.git
ddb_template: mirny_cpld: accept clk_sel as a string
This commit is contained in:
parent
a23645291c
commit
cd2e471b07
|
@ -268,6 +268,9 @@ class PeripheralManager:
|
||||||
name=mirny_name,
|
name=mirny_name,
|
||||||
mchn=i)
|
mchn=i)
|
||||||
|
|
||||||
|
clk_sel = peripheral["clk_sel"]
|
||||||
|
if isinstance(peripheral["clk_sel"], str):
|
||||||
|
clk_sel = '"' + peripheral["clk_sel"] + '"'
|
||||||
self.gen("""
|
self.gen("""
|
||||||
device_db["{name}_cpld"] = {{
|
device_db["{name}_cpld"] = {{
|
||||||
"type": "local",
|
"type": "local",
|
||||||
|
@ -281,7 +284,7 @@ class PeripheralManager:
|
||||||
}}""",
|
}}""",
|
||||||
name=mirny_name,
|
name=mirny_name,
|
||||||
refclk=peripheral["refclk"],
|
refclk=peripheral["refclk"],
|
||||||
clk_sel=peripheral["clk_sel"])
|
clk_sel=clk_sel)
|
||||||
|
|
||||||
return next(channel)
|
return next(channel)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue