def parse_oct_pins(cls, e): pins = parse_list(e, "oct_pins") for p in pins: if (not Tinker.is_valid_verilog_name(p)): Tinker.value_error_xml("oct_pins", p, "Valid Verilog Names", ET.tostring(e)) return pins
def parse_grouping(cls, e): ids = parse_list(e, "grouping") for i in ids: if (not Tinker.is_id(i)): Tinker.value_error_xml("grouping", i, "Alphabetic Characters", ET.tostring(e)) return ids
def parse_grouping(cls, e): ids = parse_list(e, "grouping") for i in ids: if(not Tinker.is_id(i)): Tinker.value_error_xml("grouping", i, "Alphabetic Characters", ET.tostring(e)) return ids
def parse_oct_pins(cls, e): pins = parse_list(e, "oct_pins") for p in pins: if(not Tinker.is_valid_verilog_name(p)): Tinker.value_error_xml("oct_pins", p, "Valid Verilog Names", ET.tostring(e)) return pins
def __parse_ip(self, e): d = dict() d["types"] = parse_list(e, "types") for t in d["types"]: se = findsingle(e, t) if (t == "memory"): d[t] = MemoryType.MemoryType(se) return d
def __parse_ip(self, e): d = dict() d["types"] = parse_list(e, "types") for t in d["types"]: se = findsingle(e, t) if(t == "memory"): d[t] = MemoryType.MemoryType(se) return d
def __parse_type(self, t, e): d = dict() d["interfaces"] = parse_list(e, "interfaces") d["default"] = parse_string(e, "default") for i in d["interfaces"]: ie = findsingle(e, "./phy/[@id='%s']" % str(i)) m = self.__construct(t, ie) d[i] = m return d
def __parse(self, e): d = dict() d["type"] = "memory" d["types"] = parse_list(e, "types") for t in d["types"]: te = findsingle(e, "./%s" % t) if (t not in self._C_KNOWN_TYPES): Tinker.value_error_xml("types", t, str(list(self._C_KNOWN_TYPES)), ET.tostring(e)) d[t] = self.__parse_type(t, te) return d
def parse_roles(cls, e): roles = parse_list(e, "roles") for mr in roles: if(mr not in cls._C_ROLES): Tinker.value_error_xml("roles", mr, str(roles), ET.tostring(e)) return roles
def parse_ratios(cls, e): mem_ratios = parse_list(e, "ratios") for mr in mem_ratios: if(mr not in cls._C_RATIOS): Tinker.value_error_xml("ratios", mr, str(ratios), ET.tostring(e)) return mem_ratios
def parse_ports(cls, e): mem_ports = parse_list(e,"ports") for mp in mem_ports: if(mp not in cls._C_PORT_TYPES): Tinker.value_error_xml("ports", mp, str(ports), ET.tostring(e)) return mem_ports