summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a9b7651)
raw | patch | inline | side by side (parent: a9b7651)
author | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Tue, 3 Nov 2015 10:48:03 +0000 (16:18 +0530) | ||
committer | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Tue, 3 Nov 2015 11:20:32 +0000 (16:50 +0530) |
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
iodelay-autogen.py | patch | blob | history |
diff --git a/iodelay-autogen.py b/iodelay-autogen.py
index 4123d12331c531174bbdd3935ba12f76da592c5b..a79dfd5694d1e1ae839f447203fa6996aa00d708 100755 (executable)
--- a/iodelay-autogen.py
+++ b/iodelay-autogen.py
help='select the output format to be used')
parser.add_argument('-r', '--revision', dest='revision',
- action='store', type=str, choices=["1.1", "2.0"], default="1.1",
+ action='store', type=str, choices=["1.0", "1.1", "2.0"], default="1.1",
help='select the silicon revision')
+parser.add_argument('-p', '--part', dest='part',
+ action='store', type=str, choices=["dra74x", "dra75x", "dra72x"], default="dra74x",
+ help='select the device part')
+
parser.add_argument('-m', '--module', dest='module',
action='store', type=str, default="",
help='generate only for this module')
args = parser.parse_args()
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
-VERSION = "2.3"
-PCT_VERSION = "v1.0.9"
-pad_data_xml = "XMLFiles/CTRL_MODULE_CORE.xml"
-iod_data_xml = "XMLFiles/IODELAYCONFIG.xml"
-model_data_xml = "XMLFiles/model_DRA75x_DRA74x_SR" + args.revision + "_" + PCT_VERSION + ".xml"
+VERSION = "2.4"
+
+if (args.part == "dra74x" or args.part == "dra75x"):
+ XML_PATH = "XMLFiles/DRA75x_DRA74x"
+ PART = "DRA75x_DRA74x"
+ PCT_VERSION = "v1.0.9"
+elif (args.part == "dra72x"):
+ XML_PATH = "XMLFiles/DRA72x"
+ PART = "DRA72x"
+ PCT_VERSION = "v1.0.5"
+
+pad_data_xml = XML_PATH + "/CTRL_MODULE_CORE.xml"
+iod_data_xml = XML_PATH + "/IODELAYCONFIG.xml"
+model_data_xml = XML_PATH + "/model_" + PART + "_SR" + args.revision + "_" + PCT_VERSION + ".xml"
modehelp_file = "guidelines.txt"
pad_file = "ctrl-core.dump"
sel_file = "selected-modes.txt"
+print "iodelay-autogen.py - Python script to generate the IOdelay data."
+print "v" + VERSION + " using PCT version " + PCT_VERSION
+print ""
+
# Read the XML file database for pad and delay registers
+if (args.debug >= 1):
+ print ("Parsing PCT data from " + model_data_xml)
pad_xml = ET.parse(pad_data_xml).getroot()
iod_xml = ET.parse(iod_data_xml).getroot()
model_xml = ET.parse(model_data_xml).getroot()
xml_check_correctness(modehelp)
-print "iodelay-autogen.py - Python script to generate the IOdelay data."
-print "v" + VERSION + " using PCT version " + PCT_VERSION
-print ""
# Start iterating over each pad
for i in range(0, 260):
# Find out the muxmode and pad direction, etc