Do not strip event value member names (like "digital_node(strength")

from the name when creating a vector from event node history.
This commit is contained in:
Giles Atkinson 2023-07-27 04:51:54 +01:00 committed by Holger Vogt
parent 33f206b916
commit db39671ae2
1 changed files with 10 additions and 12 deletions

View File

@ -142,7 +142,6 @@ keyword "all" is supplied to the plot_val routine for the member name.
struct dvec *EVTfindvec( struct dvec *EVTfindvec(
char *node) /* The node name (and optional member name) */ char *node) /* The node name (and optional member name) */
{ {
char *name;
struct node_parse result; struct node_parse result;
int index, i; int index, i;
int udn_index; int udn_index;
@ -164,17 +163,16 @@ struct dvec *EVTfindvec(
/* Exit immediately if event-driven stuff not allocated yet, */ /* Exit immediately if event-driven stuff not allocated yet, */
/* or if number of event nodes is zero. */ /* or if number of event nodes is zero. */
ckt = g_mif_info.ckt;
if (!ckt)
return NULL;
evt = ckt->evt;
if (!evt || !evt->data.node)
return NULL;
index = Evt_Parse_Node(node, &result); index = Evt_Parse_Node(node, &result);
if (index < 0) if (index < 0)
return NULL; return NULL;
name = result.node;
ckt = g_mif_info.ckt;
evt = ckt->evt;
if (!evt->data.node) {
tfree(name);
return NULL;
}
/* Get the UDN type index */ /* Get the UDN type index */
@ -215,6 +213,7 @@ struct dvec *EVTfindvec(
i++; i++;
} }
txfree(result.node);
/* Add one more point so that the line will extend to the end of the plot. */ /* Add one more point so that the line will extend to the end of the plot. */
@ -224,19 +223,18 @@ struct dvec *EVTfindvec(
/* Allocate dvec structures and assign the vectors into them. */ /* Allocate dvec structures and assign the vectors into them. */
/* See FTE/OUTinterface.c:plotInit() for initialization example. */ /* See FTE/OUTinterface.c:plotInit() for initialization example. */
scale = dvec_alloc(tprintf("%s_steps", name), scale = dvec_alloc(tprintf("%s_steps", node),
SV_TIME, SV_TIME,
(VF_REAL | VF_EVENT_NODE) & ~VF_PERMANENT, (VF_REAL | VF_EVENT_NODE) & ~VF_PERMANENT,
i, anal_point_vec); i, anal_point_vec);
d = dvec_alloc(name, d = dvec_alloc(copy(node),
SV_VOLTAGE, SV_VOLTAGE,
(VF_REAL | VF_EVENT_NODE) & ~VF_PERMANENT, (VF_REAL | VF_EVENT_NODE) & ~VF_PERMANENT,
i, value_vec); i, value_vec);
d->v_scale = scale; d->v_scale = scale;
/* Return the dvec */ /* Return the dvec */
return(d); return(d);
} }