Introduction
Through previous works on creating parametric models using basic tools of REVIT Architecture, the class witnessed that there are several drawbacks that makes creating a parametric family complicated. Therefore, it was suggested that we use BIM API (Building Information Modeling Application Programming Interface) in order to support effective model creation. In this blog, a description on how an API program receives information from relevant project and an Microsoft Excel file, and then uses the data to modify parametric family model to meet the needs of the project. Photovoltaic Car Shading Canopy (PV CSC) placed on the parking building has different tilt angles according to the region.
Objective
The objective of this work are to:
- Create an API program that receives data on tilt angles
- Support API with an MS Excel database to determine a new tilt angle
- Send the new tilt angle value to the PV CSC parametric model in the project
Process
As shown in the figure below, data flows from MS Excel Database to REVIT API, and toward the PV CSC parametric family model.
Figure 1. Data flow of API program
General framework of API programming process was adopted from 'CreatingParametricFamilies' examples provided as class material, and it was modified to better fit current project.
- Initialize model documents
- Assigning variables
- Get user input from a pop-up dialog window
Figure 2. Pop-up dialog (comboBox)
4. Find matching data from Excel database
Table 1. Assumed optimal tilt angles of three US states
In an attempt to simply API programming, mathematical calculations were performed in MS Excel instead of C#. In this table, values in Row2 are optimal tilt angles, Row3 was added to convert the angles to work on already created parametric family models.
5. Get parameters
6. Set parameters for existing PV CSC family
Result
An API program was created and loaded to add-in menu of REVIT Architecture. As Figure3 below shows, the program successfully changes the tilt angles of the PV CSC as different states were selected from the combo-box.
Figure 3. Pop-up dialog appearing after running API
Figure 4. PV CSC for Texas
Figure 5. PV CSC for New York
Advantages and disadvantages
According to the work, advantages from using API programming are:
- It becomes possible to access several instances having the same charateristics and make changes to each of them.
- Using MS Excel database instead of putting formula into REVIT interface makes it much easier to have more organized data prepared and send them to the model when it is necessary.
- Usability of large amount of data makes the modeling more realistic considering various factors that may affect the building or parametric family.
- Parametric model becomes more adaptable to projects of different settings.
Disadvantages are:
- To be able to use BIM API, a certain level of skill in programming is necessary. This necessity forces engineers participating in building modeling using BIM to be used to knowledge in design and computer programming at the same time.
- Programs used for C# programming have different data paths that may cause confusion for those using different programs.
Additional Works and Images
Additional works performed in order to understand more diverse areas of Building Information Modeling application are:
- 4D Construction Animation
- Web-BIM-Database
The figures below demonstrate grocery store building model created using REVIT Architecture, parametric family modeling, and Web-BIM-Database application images.
Figure 6. Grocery store view
Figure 7. PV CSC parametric model1
Figure 8. PV CSC parametric model2
Figure 9. Web-BIM-Database 1
Figure 10. Web-BIM-Database 2
Figure 11. Web-BIM-Database 3