Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
boards: adrv9009_pcbz: integrate the ad9528 parser
Signed-off-by: Liam Beguin <liambeguin@gmail.com>
  • Loading branch information
liambeguin committed Sep 19, 2023
commit eac0bbbcc095e81f735e3ff9b51290da07c52f0d
26 changes: 19 additions & 7 deletions adidt/boards/adrv9009_pcbz.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from .layout import layout
from ..parts.adrv9009 import parse_profile
from ..parts import ad9528, adrv9009
import numpy as np
from pathlib import Path

Expand All @@ -23,13 +23,25 @@ def parse_profile(self, filename: Path):
"""
if not filename.exists():
raise Exception(f"Profile file not found: {filename}")
self.profile = parse_profile(filename)

self.xcvr_profile = adrv9009.parse_profile(filename)

ad9528_file = filename.parent / (filename.stem + '_AD9528.txt')
if not ad9528_file.exists():
raise Exception(f"AD9528 Profile file not found: {ad9528_file}")

self.clock_profile = ad9528.parse_profile(ad9528_file)

def gen_dt_preprocess(self):
return {
"rx": self.profile["rx"],
"tx": self.profile["tx"],
"orx": self.profile["orx"],
"lpbk": self.profile["lpbk"],
"clocks": self.profile["clocks"],
"pll1": self.clock_profile["pll1"],
"pll2": self.clock_profile["pll2"],
"sysref": self.clock_profile["sysref"],
"out": self.clock_profile["out"],

"rx": self.xcvr_profile["rx"],
"tx": self.xcvr_profile["tx"],
"orx": self.xcvr_profile["orx"],
"lpbk": self.xcvr_profile["lpbk"],
"clocks": self.xcvr_profile["clocks"],
}