Nested Families and Parameter Controls
Parameters in Autodesk® Revit® allow control over elements and information with constraints and controls. This leads to more effective and interactive spaces and information. Without a good understanding of parameters, Revit users might feel the product is frustrating and limiting. Using parameters correctly is key to success when building or customizing and family. The following example demonstrates the use of parameters in a complex track light family that allows the track head to face forward and backward, as well as to move side to side along the track without moving the other track heads. It’s a process, but the finished product is great, and the principles can be applied to all kinds of electrical families.
In a complex family, being able to make changes to different components as quickly and easily as possible is crucial. One of the best ways to ensure that edits are easy and accurate is by using nested families. A nested family is a family which has been loaded into another family, instead of a project. That model then becomes part of the final family when it is inserted into the project.
There are two major components in any track lighting system: the track and the track head. This track head is going to flip from facing forward to facing backward while remaining at the same location on the track. The best way to accomplish this is to load the single track head family into a generic family, and then mirror it there.
For this article, it is assumed the reader is has created geometry for the track and track head.
Add Visibility Parameters
First nest the track head family into a generic family (face-based is preferable, but not required).
1. Locate the base point of the head, which will attach to the track itself. In this example, a small cylinder almost directly below the lamp is used. Because this is the “point of attachment,” ensure it is also the axis line of the mirror.
2. Align the track head so that the center of the circle is the point at which both reference planes cross.
3. Mirror the light across the vertical reference plane to ensure that the cylinder attachment of both lights is the exact same point.
4. Assure that the bottom of the connector of both heads is exactly flush with the Ref. Level, as seen from the front view.
5. To add parameters to visibility to the head on the left, select that head.
6. In the properties palette, click on the expansion box to the far right of the “Visible” option. This will open an Associate Family Parameter dialog box.
7. Click “Add parameter” in the Associate Family Parameter dialog box.
8. Call this parameter “Front”
Discipline: Common
Type of Parameter: Yes/No (Creates a check box control)
Group Parameter Under: Visibility
In order to see and control these parameters once the family is loaded into the Track family, any parameters in this nested family must be instance parameters. Click this and click OK in the Associate Family Parameter dialog box. The parameter for Visible is now grayed out when the track head on the left is selected.
Select the head on the right and follow the same process, except call this parameter “Back”.
1 Open a basic “Track” family
2 Load the Track Head family, into the Track family
a. Place it anywhere along the track.
b. Center the track head on the track and check to make sure that the bottom of the head (or mounting point) lines up with the top of the track.
To have an instance of the nested family act independently of the other instances of that nested family, use control parameters (or visibility parameters), for each instance of the nested family in that family file. Once the family is loaded into a project, those parameters will give us flexibility and control over the instances.
Creating Controls to Flip Each Instance of the Track Head
Now each instance of the track head that is added to the track family needs controls and formulas to help determine whether they face forward or backward.
1. Select the track head
2. In the properties palette, select the expansion box for the “Front” Parameter.
3. Add a parameter
Name: LT 1 F (Light #1 Front)
Discipline: Common
Type of Parameter: Yes/No
Group Parameter Under: Other
Make it an “Instance” Parameter
4. With the track head still selected, click the expansion box for the “Back” Parameter.
Add a parameter
Family Parameter
Name: Flip 1
Discipline: Common
Type of Parameter: Yes/No
Group Parameter Under: Visibility
This parameter also needs to be an “Instance” Parameter
Don’t want to keep track of visibility parameters for each instance of the track head twice? Nobody does. Tell Revit that the two heads should not be seen at the same time with a formula.
5. In the properties palette under the Modify tab, click on (Family Types) to open the Family Types dialog box.
6. Locate the two parameters just created (LT 1 F, and Flip 1)
7. In the Formula Box Under “LT 1 F”, type “Not (Flip 1)
a. This formula tells the “LT 1 F” parameter to turn off when the “Flip 1” is selected, and vice versa.
Now create the same visibility Parameters (IE: LT 1 F, and Flip 1) for each track head in the system. This may limit the number of track heads desired. Determine how many heads are typically needed in this type of system, because each head will need to have its own set of parameters. For this example, use nine heads.
1. Copy the track head nine times along the track—it doesn’t matter how far apart they are.
2. Follow the Previous Steps for “Creating Visibility Overrides for the Track Head” to create the parameters for each of the nine heads.
3. The parameters for the “Front” heads will read as LT 2 F, LT 3 F, LT 4 F, etc.
4. The parameters for the “Back” heads will read as: Flip 2, Flip 3, Flip 4, etc.
5. Don’t forget to enter the Not (Flip #) Formulas for each of the LT # F Parameters.
Try importing the track family into a project and flip each track head back and forth.
Control the Number of Track Heads
It is unlikely that exactly nine track heads will be required for every instance of track in a project. The following steps walk through how to accommodate the number of heads using parameters and formulas.
1. In the properties palette, click on the expansion box to the far right of the “visible” option to open the Associate Family Parameter dialog box.
2. Click Add Parameter
3. Call the parameter “1 Light”
a. Family Parameter
b. Name: 1 Light
c. Discipline: Common
d. Type of Parameter: Yes/No
e. Group parameter under: Other
Make the number of lights be a Type Property. This way it is easier to control information, including notes, catalog number, tags, and watts.
Repeat for each of the nine track heads.
Checking every single light parameter to turn it on/off is pretty tedious. Controlling the number of lights with an integer parameter is a slick solution. This parameter won’t change how the family works, and so is not necessary, but it makes controlling the Types in the project a little bit smoother.
1. In the properties palette under the Modify tab > click on (Family Types) to open the Family Types dialog box.> click Add, under Parameter.
a. Family Parameter
b. Name: Number of Lights
c. Discipline: Common
d. Type of Parameter: Integer
e. Group Parameter Under: Dimensions (this will group the number of lights with the same information as the length of the track)
Make this parameter either a type or instance parameter to match the “1 Light” – “9 Lights” parameters.
The track head visibility parameters, which were created previously, can be controlled by the “Number of Lights” parameter by assigning a formula to the track head visibility parameters.
1. In the properties palette, under the Modify tab> click on (Family Types) to open the Family Types dialog box.
2. Scroll down to the Track Head Visibility parameters (i.e., 1 light, 2 Lights, etc).
3. In the formula column next to “1 Light” enter “Number of Lights > 0”
4. This tells the parameters that in order for the visibility for “1 Light” to be on, the integer in “Number of Lights” has to be greater than 0 (or 1 and higher).
5. Follow the same step for 2-9 lights
6. 2 Lights will read “Number of Lights > 1”
7. 3 Lights will read “Number of Lights > 2” and so on.
Now the visible instances are determined by a single parameter.
Length Parameters, In All Their Glory
1. Open the Ref. Level in the Track Family.
2. Draw a reference plane running horizontally next to Light 1.
a. The reference plane will become our manual pull point for the light parameter.
3. Name it “Pull for light 1” and make it a weak reference.
4. Align the reference plane with the center of the track head and lock it in place so that the track head and reference plane move together.
Hover over the center of the light—align and lock. Repeat with all nine track heads
Draw separate dimension lines to the “pull” reference plane attached to each track head, starting from the track head in front of it, to control the distance between each head.
1. Make sure you are selecting the reference plane that we just locked into place and not the reference line that exists in the nested family.
2. The first track head will have a dimension line from the end of the track closest to it.
3. Make sure they are separate dimension lines as opposed to a solid run of dimensions, because each dimension needs to have its own parameter.
4. With the first dimension selected, > click on the “Label” drop-down menu at the top-left hand side of the screen.
a. Select “Add Parameter…”
b. In the parameter properties dialog box, select the following options:
Family Parameter
Name: Distance of L1
Discipline: Common
Type of Parameter: Length
Group Parameter Under: Other
This parameter needs to be an Instance parameter
Repeat for each of the nine dimension lines.
Make each length parameter equal 14” so that your lights are evenly spaced when inserted into a project. Ensure that the “Number of Lights” parameter is set to show all nine lights.
Import the family into a project. When selected, the track light has a double arrow on each of the nine track light heads. Use these arrows to move the track light back and forth along the track. With the track light fixture highlighted, select “Edit Type” and change the “number of Lights” to 7, then click OK. Even though the two track heads are no longer visible, the arrows to move them are. When moving the track lights down the track, make sure not to cross any of the other track heads dimensions or else the fixture will try to delete itself.
The distances can be set to a precise distance in the instance parameter itself, under “other.”
That concludes the process for creating a fully functioning, highly controllable track light.
Cassandra Watts has been a Revit user since 2009, and has completed a number of projects both in Revit MEP and Revit Architecture. She is a drafter/designer for EELD where she is the lead BIM Designer. As well as working on several projects, she is in charge of research, development, and training in the Revit® software for the company. Cassandra was also a virtual presenter this year at Autodesk University.