twitter youtube facebook linkedin email
Connect with:

Learn the Power of Dynamo for Automated Reinforcement Detailing – Part 1

Tomasz Fudala

In this blog post I would like to demonstrate how to automate reinforcement designs with the Dynamo graphical programming interface using the example of standard rebar designs for window and door openings.

Revit 2019.1 comes with Dynamo 1.3.3 preinstalled, however the workflows covered in this blog post are compatible with Dynamo 2.0. When you try to run scripts presented in this post you should make sure you are using Dynamo 2.0, which you can download and install from dynamobim.org/download.

Dynamo 2.0 can be installed side-by-side with an existing 1.x version allowing you to have control over which major version you use for your project. In Dynamo for Revit, you will be prompted to choose which version you wish to run on first launch of Dynamo. This setting is cached per-session of Revit. A restart of Revit will enable you to change to a different version of Dynamo.

Building my Dynamo script I will be using Revit 2019.1 and the Structural Design 1.0.2 Dynamo package.

Structural Design package

The Structural Design Dynamo package supports various structural workflows in Dynamo and Revit (metric units only [mm]). The 1.0.2 version of the package mostly supports the reinforcement detailing workflows, however, moving forward the scope of the package will be extended.

Before getting started please make sure and verify the package is installed on your machine.

You can use the Search for a Package option if the package is not installed on your computer yet.

If the package is installed properly you should see it under the Add-ons.

 

Input Parameters

First, let’s define some input parameters.

Note: To define Straight Rebar Diameter and Diagonal Rebar Diameter and Stirrup Rebar Diameter input nodes you should use the RebarBarType node from the Structural Design package. It can be found under Structural Design->Rebar->Properties.

Double click the node title bar to rename it accordingly.

This is how the input parameters should look in Dynamo Player:

Get Window/Door Opening Characteristics

You may ask “What about the selection process? Where is any Select button to get a model geometry?

In this case I will create a different approach. Instead of clicking the Select button, I will set up input parameters and click the Run script  button to execute the script, and then I will be asked to make a selection. Once the selection is made the script proceeds its execution.

Let’s get started:

1) I will use the PickObjectsOfCategory node to define the selection functionality of my script. The node can be found under Structural Design->Model->Selection.

This node prompts the user to select multiple objects of the defined categories while showing a custom status prompt string.

  • category: Single category or a list of categories.
  • objectType (int): Specifies the type of object to be selected 0-Nothing, 1-Element, 2-PointOnElement, 3-Edge, 4-Face, 5-LinkedElement, 6-Subelement. Default value: 1
  • statusPrompt (string): The message shown on the status bar. Default value: “Click to select multiple elements, TAB for alternates, ESC quit”
  • preselection (bool): Takes into account the initially selected set of objects. Default value: false
  • refresh (bool): Refresh selection. Default value: true

In this case the user will be able to pick only elements of the Window and the Door categories.

2) Next, I need to retrieve window and door opening characteristics using a dedicated node from the Structural Design package.
The Geometry.GetWindowDoorOpeningCharacteristics node can be found under Structural Design->Model->Geometry.

Thanks to this node I can get:

  • Curves from which an opening is created.
  • Opening plane.
  • Opening host.
  • Opening host width.
  • Vector normal to opening plane.
  • Opening category.
  • Opening width.
  • Opening height.
  • Opening corner points.

3) Let’s get the rebar cover dimensions for the host of the selected opening element.

Straight Rebars

Now, based on the selected opening characteristics, I can create straight rebars around the opening.

1) First, I need to generate Dynamo curves which will be used during the creation of straight rebars. There is a dedicated node in the Structural Design package to do this.

As the above node needs two input parameters which are rebar diameters, I need to get a rebar diameter from Rebar Bar Type first.

2) Now I can connect all inputs with the right data.

3) Next, I can create Revit rebars using the FromCurve node (Structural Design->Rebar->Create).

Note: The respective vectors are taken from the Vector output of the Designs.OpeningStraightRebarCurves node. Vector is the normal to the plane that the rebar curve lies on.

4) Next, let’s set the Layout Rule property of newly created rebars to Fixed Number. The default number of bar positions in rebar set is 2, so no need to make a connect in this case as this is the number of rebars we want to set up.
Note:
The respective distribution length of rebar sets (arrayLenght) is taken from the Spacing output of the OpeningStraightRebarCurves node.

5) There is one more thing I am going to include in the logic of creation of straight rebars. When the Top Stirrup is Closed input parameter is True, and the Two Layers parameter is True too, then I would like to have the top straight rebars copied to create reinforcement of a lintel. To do this, let’s filter out top bars first.

6) Next, if the conditions are met then we copy filtered rebars.

7) Of course, we need to determine a vector that is used when we copy elements.

Note: In this case we don’t perform an operation on a Dynamo geometry when we copy elements, but instead when we copy Revit objects. The Geometry.CopyElement node copies an element and places the copy at a location indicated by a given transformation (Structural Design->Model->Geometry).

The Dynamo script I built in this article can be found here.

In my next post I will continue to develop this script and I will:

  • add Diagonal Rebars
  • add Boundary Stirrups
  • and set up Rebar Visibility

Continue reading: Learn the Power of Dynamo for Automated Reinforcement Detailing – Part 2

@tomekf

What is BIM (Building Information Modeling)?

Free Form Rebar - Aligned Distribution

Featured Links

Tomasz Fudala

Tomasz Fudala is the Technical Marketing Manager for Structure. He has over 15 years of experience in the software industry and a comprehensive background and vast knowledge of structural solutions in the Autodesk portfolio. With a Structural Engineering background he is responsible for technical sales readiness. He achieved a Master of Science degree in Structural Engineering from the Cracow University of Technology, Poland. Find him on Twitter @tomekf

15 Comments

View by:
Most Recent Oldest
    // Display trackbacks differently than normal comments.
  1. Pingback: Structural Design package version 1.0.5 - Shop Architect

  2. Avatarvelimir.pavlic@ingolab.hr

    0

    0

    Hi,
    can you help me why the script does not work. It appears “Run completed with errors”. Can you help me, this script would help me a lot

    1. Tomasz FudalaTomasz Fudala (Post author)

      0

      0

      Hello. What kind of error? Did you read the article? How can I help you?

    2. Avatarvelimir.pavlic@ingolab.hr

      0

      0

      Yes, I read the article. I installed The Structural Design Dynamo and the script looks okay. The unit I use is millimeter, I work in revit structure, the German standard. I tried Englishstandards where he wrote the height and the width but simply does not draw reinforcment. What matter is the type of wall or window? Finally writes Run completed with errors but I can not see the errors

  3. Avatarjiandanlll

    0

    0

    Is there any way to get this to work with 2018 ?

    1. Tomasz FudalaTomasz Fudala (Post author)

      0

      0

      The Structural Design package 1.0.2 works with Revit 2019 and Dynamo 2.

  4. Avatarchubbard

    0

    0

    Is there any way to get this to work with 2018 Dyamo 2.02?

    1. Tomasz FudalaTomasz Fudala (Post author)

      0

      0

      The Structural Design package 1.0.2 works with Revit 2019 and Dynamo 2.

  5. Avatareinarrb

    0

    0

    Great stuff! Is the source code of the package available on GitHub or something like that?

    1. Tomasz FudalaTomasz Fudala (Post author)

      0

      0

      I am glad you like it! The source code is not available on GitHub.

  6. Avatarqoqo1065@naver.com

    0

    0

    I’m still waiting, Adding Diagonal Rebars / Boundary Stirrups. What you’ve done is so amazing! Thanks.

  7. Avatarhtlcnn

    0

    0

    Hi,
    Thanks for the tutorial and the package. Do you plan to make the package available for Dynamo 1.3?

    1. Tomasz FudalaTomasz Fudala (Post author)

      0

      0

      I don’t as Dynamo 1.3 will be obsolete soon.