Applying a dropped kerb using Dynamo for Civil 3D

Applying a dropped kerb using Dynamo for Civil 3D

A common task in a Civil 3D project is to apply a dropped kerb to a road corridor. While it can be achieved manually using Civil 3D tools, the process is time consuming. Dynamo for Civil 3D is a tool that can help us automate this task. I will be describing how you can create a script in Dynamo to achieve this goal. For the script to work, you will need to import a custom node into Dynamo first. Both the script and the library to import the custom node are available to download.

Some familiarity with Dynamo is required to understand how the script works. YA common task in a Civil 3D project is to apply a dropped kerb to a road corridor. While it can be achieved manually using Civil 3D tools, the process is time consuming.ou can still use it even if you don’t know Dynamo with the use of Dynamo Player, as will be explained.

The script will create a region for the dropped kerb, including the transitions, and it will then change the kerb type to a dropped kerb using corridor overrides. It is assumed that the kerb is modelled using the ‘British Multikerbs (with transitions)’ subassembly, available in Civil 3D 2021 as part of the UKIE country kit. The region will be created by a custom node that I coded using the Civil 3D API, everything else will be done using standard nodes. Custom nodes in Dynamo allow you to add additional functionality that is not available in the nodes included with the application.

Let us start by importing the custom node. From Dynamo for Civil 3D, select ‘Import Library…’ from the ‘File’ pull-down menu and select Excitech.dll. You should now see an ‘Excitech’ branch in the Add-ons section of the left panel that contains the AddStations node. Click on it to insert it in the graph.

 

The DroppedKerb.AddStations node will create a region for the dropped kerb, including the transitions, centred around the chainage that is specified as an input. It will output a list with all the stations where the kerb type needs to be overridden to a dropped kerb. It takes the following inputs:

  • corridorName: the name of the corridor that contains the dropped kerb.
  • baselineName: the name of the corridor baseline.
  • chainage: the central station of the dropped kerb.
  • droppedKerbLength: the length of the dropped kerb, excluding transitions.
  • transitionLength: the length of the transition from the current kerb type to the overridden dropped kerb type. A transition will be added before and after the dropped kerb to connect with the existing kerb.

Using the custom node and standard Dynamo nodes, reproduce the graph below to get the baseline for the dropped kerb and the stations that need overriding. Note how a group was created for clarity, to indicate what the inputs are. The String and Number nodes used as inputs to the custom node have been renamed (by double-clicking on them) and defined as input nodes (right-click on the node and tick “Is Input”). This last step will allow us to edit the inputs directly from Dynamo Player without the need to access the Dynamo script.

The next group will take the outputs from the previous step to obtain all the UKIE_Multikerbs subassemblies that need to be overridden to a dropped kerb type, using a boolean mask.

Starting from that list of kerb subassemblies, we restrict the selection to only the kerbs on the side that we want to drop according to the corresponding input node. An input of 0 will drop the left kerb, 1 will drop the right kerb and 2 will drop both.

Finally, the kerb type is overridden for the corresponding subassemblies with the dropped kerb type selected in the input node and the corridor is rebuilt.

The finished dynamo script DroppedKerb.dyn can be downloaded.

The script can be run from Dynamo directly or using Dynamo Player. The latter is especially useful for users that are not familiar with Dynamo. The process is as follows:

  • In Civil 3D, access ‘Dynamo Player’ from the ‘Manage’ tab of the ribbon.
  • Browse to the folder that contains DroppedKerb.dyn. All the Dynamo scripts contained in that folder will be listed.
  • Click on the ‘Edit inputs’ button to display the inputs of the script.
  • Modify the inputs accordingly and run the script

After running the script with the inputs above in a sample drawing, a new region is added to the corridor around the specified chainage, containing the dropped kerb. The frequency in that region is set to the baseline length to avoid undesirable stations being automatically added in the transitions. This frequency should not be changed. Some additional stations are also added. “Dropped Kerb Start” and “Dropped Kerb End” should not be deleted and no new stations should be added to this region in the transitions, that is before “Dropped Kerb Start” or after “Dropped Kerb End”. Doing so would affect the geometry of the transition.

This is how the dropped kerb will show in object viewer:

If you are new to Dynamo for Civil 3D and you would like to get a basic understanding of it, you may want to look at our “Dynamo Fundamentals for Autodesk Civil 3D” private training course, available both as virtual or face-to-face training.

Alternatively, If you would like help with Dynamo scripts, application automation, content creation, project support and much more, visit our website to explore our consultancy services.


Unlock Your Potential: The Benefits of Investing in a Learning Path with Symetri

26 February 2025

At Symetri, we understand the importance of tailored education and deliver exceptional training solutions, available both in our classrooms or through our unique Virtual Classroom. Here, we explore the many advantages of committing to a learning path with Symetri and how it can transform both personal and professional growth.

Strengthening Cybersecurity & IT Best Practices

26 February 2025

As businesses continue to rely on digital tools and internet connectivity, cyber risks remain a constant concern. This month, we're exploring three important topics: the hidden risks of public Wi-Fi, the importance of regular IT audits, and QR code security. These insights will help you stay secure and ensure your business IT infrastructure remains resilient.

Boost Your Security and Productivity: Essential IT Insights

19 January 2025

As we enter the new year, it's crucial to stay informed about the latest tools and strategies to safeguard your digital life and optimise productivity. This month, we're focusing on three essential topics to help you strengthen cybersecurity practices and make the most of your technology. Learn how password managers can protect your sensitive information, understand the rising threat of malvertising and how to avoid it, and explore smart Windows 11 settings designed to boost efficiency in your daily tasks. These insights are designed to empower you with practical tips to stay secure and work smarter in 2025.