Quantcast
Channel: Jason Andrews Blog
Viewing all articles
Browse latest Browse all 33813

Parameter passing hygiene

$
0
0
I'm trying to make a parent schematic/symbol wrapper cell around a confusing looking child cell that has parameters e.g. a, b, c and displays those parameters via labels on its symbol. Note also that entering the parameters on the child passes them into some code via callbacks. All parameters are text fields. I want my wrapper cell to have exactly the same parameter names and just pass them down to the confusing child cell, so I create parameters a, b, c on the parent and in the child cell I set it's parameters to [@a], [@b] and [@c]. I have two problems: 1. Because the parameter names are identical for the parent and child, I seem to be getting an illegal loop when in the child cell I set parameter "a" to "[@a]". I really want the parameter names to be the same on both the parent and child cells. How would I do this? 2. When I enter the parameters on the parent (e.g. set a to 1, b to 2, c to 3) and then descend in to reveal the child cell, the child symbol parameter labels aren't showing 1, 2 and 3 - they're showing [@a], [@b] and [@c]. How can I have the child symbol show be the actual values passed down from above? Remember, the child cell operates on its parameters via callbacks and the callback is receiving “[@parent_param]” or “pPar(\“parent_param\”)” depending on what I've tried so far. I'd really appreciate some help on this and I'm sure this is a silly newbie question, so apologies in advance.

Viewing all articles
Browse latest Browse all 33813

Trending Articles