Changing MEP Fittings

Hello,

I’ve been chugging along with some scripts to automate the sizing of ducts and pipes using dynamo based on fixture units and hit a snag. I can resize pipes ok-ish but the connectors don’t change with the pipe. The Revit default here is to add a reducer so instead of getting a duct fitting that matches the inlets (10", 15" and 20") you get a fitting that is whatever it was previously (10", 10", 10" with reducers going to the other two ducts to size. Any ideas on how to make it so that the fittings size with the pipe and won’t place reducers?

You will need to find some way of getting the fittings that are connected to the duct and change them too.
In the API help there are some things relating to duct connectors;

Each Duct has a property Connector Manager .
From the Connector Manager you can get a list of the duct connectors.
From each connector you can get the property Allrefs which shows what it is connected to.
From those connectors you could get the Owner , which is the fitting connected to the duct.

So it is possible, but a long winded process. Maybe someone with the programming skills will make a node that returns what is connected to a duct or pipe…

Or… do your calculations with placeholders, then convert to duct afterwards.

Pipes and ducts have built in parameters for diameter, so that parameter is always the same. For pipe and duct fittings though the parameter that controls the size is created by the person that created the family. If the name for that parameter is the same for all your fittings then you could use that parameter to change the fittings size.

2 Likes