A
Andi
Guest
Hi all,
What I want to do is the following: I would like to dump the values of
all ports of a given instance into a file (in a certain format). Since
this application should be re-usable, I used the PLI to get access to
all the ports of the instance and their values. This works very well so
far.
Now, for bi-directional ports I do not want to dump the resolved value
of the port, but I want to get access to the "in-portion" and the
"out-portion". In other words, I want to find out if a driver located
in the hierarchy below my given instance or a driver located somewhere
above my instance causes the value on the port. At the moment, I have
the following approach:
hiconnHandle = vpi_handle(vpiHighConn, portHandle);
itrHiDriverHandle = vpi_iterate(vpiDriver, hiconnHandle);
while ( hiDriverHandle = vpi_scan(itrHiDriverHandle) ) {
...
}
This works fine and gives me all drivers, i.e. primitives that drive
that net. However, I do not get continuous assignments that may write
on that net as well. Accordingly, I tried the following:
itrContAssign = vpi_iterate(vpiContAssign, moduleHandle);
while (contAssignHandle = vpi_scan(itrContAssign) ) {
...
}
Unfortunatelly, this does not work and the pointer itrContAssign is
NULL (at least with Questasim).
Does anybody know, if my approach is generally correct? Or is there a
better/easier solution?
Many thanks for your help
Andreas
What I want to do is the following: I would like to dump the values of
all ports of a given instance into a file (in a certain format). Since
this application should be re-usable, I used the PLI to get access to
all the ports of the instance and their values. This works very well so
far.
Now, for bi-directional ports I do not want to dump the resolved value
of the port, but I want to get access to the "in-portion" and the
"out-portion". In other words, I want to find out if a driver located
in the hierarchy below my given instance or a driver located somewhere
above my instance causes the value on the port. At the moment, I have
the following approach:
hiconnHandle = vpi_handle(vpiHighConn, portHandle);
itrHiDriverHandle = vpi_iterate(vpiDriver, hiconnHandle);
while ( hiDriverHandle = vpi_scan(itrHiDriverHandle) ) {
...
}
This works fine and gives me all drivers, i.e. primitives that drive
that net. However, I do not get continuous assignments that may write
on that net as well. Accordingly, I tried the following:
itrContAssign = vpi_iterate(vpiContAssign, moduleHandle);
while (contAssignHandle = vpi_scan(itrContAssign) ) {
...
}
Unfortunatelly, this does not work and the pointer itrContAssign is
NULL (at least with Questasim).
Does anybody know, if my approach is generally correct? Or is there a
better/easier solution?
Many thanks for your help
Andreas