Beispiel #1
0
 def WriteIOPorts(self, hdlwriter):
     Dev.Debug(Dev.Info, "ConstantConnector.WriteIOPorts(self,hdlwriter)")
     # I may want to support a direction flag for these connectors
     if self.Width is None:
         Dev.Debug(
             Dev.Stop, "Fatal Error: ConstantConnector " + self.Name +
             " was never configured with a Width.")
Beispiel #2
0
 def ConfigureEachOther(self, prj, v):
     if not (v.Width is None):
         if self.Width is None:
             self.Width = v.Width
             prj.AddChangedConnector(self)
         elif (self.Width != v.Width):
             Dev.Debug(
                 Dev.Error, "Error: ConstantConnector " + self.Name +
                 " found an inconsistancy with Local Connector named " +
                 v.Name + " in the configuration.")
Beispiel #3
0
 def __init__(self, name, comp, value):
     Dev.Debug(Dev.Info,
               "ConstantConnector.__init__(self,supername,name,start,end)")
     self.Comp = comp
     self.Conn = None
     self.LocalConn = None
     self.IOType = HDLIOType.Wire
     self.Type = HDLNetType.Wire
     self.Value = value
     self.Width = None
     self.Name = name
     self.IsUsed = 1
     self.Anonymous = 0
     if not (comp is None):
         comp.AddConnector(self)
Beispiel #4
0
 def Duplicate(self):
     Dev.Debug(Dev.Info, "ConstantConnector.Duplicate(self)")
     Dev.Debug(
         Dev.Warning,
         "Error: ConstantConnector does not know how to duplicate itself.")
     return dup
Beispiel #5
0
 def WriteIOPortBindingName(self):
     Dev.Debug(Dev.Info,
               "ConstantConnector.WriteIOPortBindingName(self,hdlwriter)")
     return Util.VerilogBinary(self.Value, self.Width)
Beispiel #6
0
 def WriteIOPortLogic(self, hdlwriter):
     Dev.Debug(Dev.Info,
               "ConstantConnector.WriteIOPortLogic(self,hdlwriter)")
Beispiel #7
0
 def WriteIOPortBindings(self, hdlwriter):
     Dev.Debug(Dev.Info,
               "ConstantConnector.WriteIOPortBindings(self,hdlwriter)")
     hdlwriter.Write("\t." + self.Name + "(" + self.Conn.LocalName + ")")
Beispiel #8
0
 def WriteIOPortNames(self, hdlwriter):
     Dev.Debug(Dev.Info,
               "ConstantConnector.WriteIOPortNames(self,hdlwriter)")
     Dev.Debug(
         Dev.Warning,
         "Error: ConstantConnector cannot be used as an input/output.")
Beispiel #9
0
 def ParameterizationCheck(self, prj):
     Dev.Debug(Dev.Info, "ConstantConnector.ParameterizationCheck(self)")
     if self.Width is None:
         Dev.Debug(
             Dev.Error, "Error: ConstantConnector " + self.Name +
             " failed to configure the width parameter.")