URL
https://opencores.org/ocsvn/nocmodel/nocmodel/trunk
Subversion Repositories nocmodel
[/] [nocmodel/] [trunk/] [doc/] [nocmodel.basicmodels.basic_ipcore.html] - Rev 2
Compare with Previous | Blame | View Log
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><title>Python: module nocmodel.basicmodels.basic_ipcore</title>
</head><body bgcolor="#f0f0f8">
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
<tr bgcolor="#7799ee">
<td valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong><a href="nocmodel.html"><font color="#ffffff">nocmodel</font></a>.<a href="nocmodel.basicmodels.html"><font color="#ffffff">basicmodels</font></a>.basic_ipcore</strong></big></big></font></td
><td align=right valign=bottom
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/oscard/Documentos/proyectos/nocmodel-0.1/nocmodel/basicmodels/basic_ipcore.py">/home/oscard/Documentos/proyectos/nocmodel-0.1/nocmodel/basicmodels/basic_ipcore.py</a></font></td></tr></table>
<p><tt>Basic ipcore TLM model</tt></p>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#aa55cc">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="logging.html">logging</a><br>
</td><td width="25%" valign=top><a href="myhdl.html">myhdl</a><br>
</td><td width="25%" valign=top><a href="networkx.html">networkx</a><br>
</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ee77aa">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
<td width="100%"><dl>
<dt><font face="helvetica, arial"><a href="nocmodel.noc_tlm_base.html#noc_tlm_base">nocmodel.noc_tlm_base.noc_tlm_base</a>
</font></dt><dd>
<dl>
<dt><font face="helvetica, arial"><a href="nocmodel.basicmodels.basic_ipcore.html#basic_ipcore_tlm">basic_ipcore_tlm</a>
</font></dt></dl>
</dd>
</dl>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom> <br>
<font color="#000000" face="helvetica, arial"><a name="basic_ipcore_tlm">class <strong>basic_ipcore_tlm</strong></a>(<a href="nocmodel.noc_tlm_base.html#noc_tlm_base">nocmodel.noc_tlm_base.noc_tlm_base</a>)</font></td></tr>
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
<td colspan=2><tt>TLM model of a NoC ipcore. Its based on sending and receiving packets<br>
to a custom-based MyHDL generators. This class does not define any<br>
functionality.<br>
<br>
Attributes:<br>
* ipcore_ref: reference to ipcore base object<br>
<br>
Notes:<br>
* This model is completely behavioral.<br>
* See code comments to better understanding.<br> </tt></td></tr>
<tr><td> </td>
<td width="100%">Methods defined here:<br>
<dl><dt><a name="basic_ipcore_tlm-__init__"><strong>__init__</strong></a>(self, ipcore_ref)</dt></dl>
<dl><dt><a name="basic_ipcore_tlm-recv"><strong>recv</strong></a>(self, src, dest, packet, addattrs<font color="#909090">=None</font>)</dt><dd><tt>Assumptions: <br>
* Safely ignore src and dest arguments, because this method <br>
is called only by local channel object.<br>
* In theory src should be self.<strong>localch</strong>, and dest should be <br>
self.<strong>ipcore_ref</strong> . This may be checked for errors.</tt></dd></dl>
<dl><dt><a name="basic_ipcore_tlm-register_generator"><strong>register_generator</strong></a>(self, genfunction, **kwargs)</dt><dd><tt>Register a new generator for this ipcore. <br>
<br>
Arguments:<br>
* genfunction: function that returns a MyHDL generator<br>
* kwargs: optional keyed arguments to pass to genfunction call<br>
<br>
Notes:<br>
* This method requires that genfunction has the following prototype:<br>
* my_function(din, dout, tlm_ref, <other_arguments>)<br>
* din is a MyHDL Signal of type packet, and is the input signal <br>
to the ipcore. Use this signal to react to input events and <br>
receive input packets.<br>
* dout is a MyHDL Signal of type packet, and is the output <br>
signal to the ipcore. Use this signal to send out packets to<br>
local channel (and then insert into the NoC).<br>
* tlm_ref is a reference to this object. Normal use is to access<br>
logging methods (e.g. tlm_ref.<a href="#basic_ipcore_tlm-info">info</a>("message") ).<br>
* <other_arguments> may be defined, this method use kwargs <br>
argument to pass them.</tt></dd></dl>
<dl><dt><a name="basic_ipcore_tlm-send"><strong>send</strong></a>(self, src, dest, packet, addattrs<font color="#909090">=None</font>)</dt><dd><tt>Assumptions: <br>
* Safely ignore src and dest arguments, because this method <br>
is called only by this object generators, therefore it always send <br>
packets to the ipcore related channel.<br>
* In theory src should be self.<strong>ipcore_ref</strong>, and dest should be <br>
self.<strong>localch</strong> . This may be checked for errors.</tt></dd></dl>
<hr>
Methods inherited from <a href="nocmodel.noc_tlm_base.html#noc_tlm_base">nocmodel.noc_tlm_base.noc_tlm_base</a>:<br>
<dl><dt><a name="basic_ipcore_tlm-debug"><strong>debug</strong></a>(self, msg, *args, **kwargs)</dt><dd><tt># logging methods (only use 4 levels)</tt></dd></dl>
<dl><dt><a name="basic_ipcore_tlm-debugstate"><strong>debugstate</strong></a>(self)</dt><dd><tt># special log</tt></dd></dl>
<dl><dt><a name="basic_ipcore_tlm-error"><strong>error</strong></a>(self, msg, *args, **kwargs)</dt></dl>
<dl><dt><a name="basic_ipcore_tlm-get_generators"><strong>get_generators</strong></a>(self)</dt></dl>
<dl><dt><a name="basic_ipcore_tlm-info"><strong>info</strong></a>(self, msg, *args, **kwargs)</dt></dl>
<dl><dt><a name="basic_ipcore_tlm-warning"><strong>warning</strong></a>(self, msg, *args, **kwargs)</dt></dl>
</td></tr></table></td></tr></table>
</body></html> 