On Monday, December 6th, Autodesk Labs released a new Subassembly Composer Technology Preview for AutoCAD Civil 3D 2011. This standalone program provides a way for users to create custom subassemblies from within a easy to understand interface. Once your subassembly is created, you can import it into AutoCAD Civil 3D 2011 for use in corridor creation.
From the Autodesk Labs page:
Subassembly Composer has an interface that is designed to ease your workflow:
- The flowchart provides an intuitive view of the subassembly logic and is easily modified using drag and drop.
- The graphical preview displays the subassembly geometry and can be used to simulate how the subassembly behaves with different target values.
- Selection in the flowchart and preview are synchronized making it easy to find and edit the properties of a subassembly component.
- Subassembly Composer works directly with PKT files that can be imported into Civil 3D. No more hand-generating .atc files!
The technology preview release provides a strong set of subassembly functionality for corridor modeling:
- Define points and position them based on several positioning methods.
- Define links between points.
- Assign codes.
- Define targets and input parameters.
- Specify conditions for daylight and simple expressions
Let’s take a look at just what we can do – let’s make a subassembly! We’ll start off simple, but this will still be a pretty detailed article. Follow the link to learn more!
First, we will need to open the program. Once installed (note that it needs .NET 4.0 and SQLCE installed as pre-requisites) you will have a desktop icon for the Autodesk Subassembly Composer. If you can’t find it, look for the “S” icon – that’s it. Double-clicking this icon will open the program, which will be divided into panes for easy navigation. There are videos on the Labs page that will explain how you navigate in the program, so it would be a good idea to watch those so you can get the interface set up the way you want it. Moving a few things around made it a lot easier for me to work in the program, and might help you as well.
As I stated, we’re going to start off pretty simple – a good way to learn the interface is to recreate a subassembly that already exists. That way, you know the parameters and how it’s supposed to work, so it’s easy to test and validate. We’re going to model the BasicLane subassembly for starters. This one is easy – 4 points, 4 links. The width, depth, side, and slope are all user-input parameters, so we will have to define those parameter expressions.
Here is the user interface:
The work will be done in all panes here – the leftmost pane contains your tools that you will use to create the subassembly. It contains Decisions, Sequences, Points, Links, and Conditionals. You will drag and drop these items into the middle pane, which is the Flowchart. For anyone who has worked with flowcharts, this provides an intuitive way to connect the pieces of the puzzle that is your subassembly. On the right side, we have the Preview pane and Properties tab, which mean exactly what they say. Below that, we have Input Parameters, Packet Settings, and Target Parameters in the bottom right pane. Packet Settings defines how your subassembly looks in the tool palette, Input Parameters are the numbers that you type in to size your subassembly, and Target Parameters allow you to define alignment, profile, and surface targets.
Now that you know your way around, I should mention that subassemblies are defined from points and links. But you knew that, right? Here’s what you may not have known – the points are the meat of the subassembly and the links just hold everything together. The way I will be designing this subassembly is to define the points first and then the links, because there’s a definite method to the madness. With that being said, let’s get started!
The first thing that we will do is drag a point into the flowchart. This will be the beginning of our subassembly. You’ll notice a few things – first, we have a red circle with an exclamation mark. This tends to be the universal symbol for “hey, something’s wrong!” Such is the case here also…hovering over it indicates that there is no start node. We’ll fix that in a few seconds. Next, you will notice that the point is highlighted, which brings up the properties of the point in the Properties pane. Here, we can give it a code name, display name, and what type of geometry it is. This is where the parametric part of the design comes into play – you tell it the type and the geometry properties. Here, we can have various conditions and either hard-coded values or expressions – but more about that in a minute. We’ll just give it a name of P1 and leave everything else as default. Next comes an important step – if you hover over the start node, you will see small rectangles appear on each side of the square node. Select one of these and drag it to P1 – you’ll see the arrow flow to that point. See why it’s called a flowchart? These connections permit the points to connect to each other and react accordingly, and help define the parametric parameters of the subassembly.
Next, we will drag another point over into the flowchart and connect it to P1. We will call this P2, of course – they are numbered sequentially. For the purposes of our “BasicLane” we want P2 to connect to P1 at a user-defined distance and slope. To do this, we need to define the Width and Slope variables. This is done inside the Input Parameters tab. You will simply click where it says Create Input Parameter, which will create InputParameter1. Here comes what I like to call a 2 cent tip: don’t leave it named InputParameter1. Name it something you and your users can recognize. I like Width, because it’s what the other subassemblies use. So let’s highlight it and change it to Width. The type is going to be a Double, and we’ll set a default value of 12. Now, repeat the process for another input parameter and call it Slope. Set the default to –0.02 (a negative 2% slope.) Once those parameters are created, you can go back up to the point properties and edit P2. The point geometry type is going to be SlopeAndOffset (slope and width, right?) P2 will react from P1, which is selectable from the pulldown. Now, here’s where the magic happens – the offset is set to 0 and the slope is set to 0.5 by default. Change your offset to Width and your slope to Slope. By doing this, you have informed P2 that it should look for the numbers specified by the user for these variables. Knowing how other codes work, I make it a point to make sure my case matches across all points and stays consistent.
Now, we will let you specify P3 and P4. Drag them in and connect them up. P3 will require another input parameter (I call it Depth.) and the properties need to be changed just a little bit (P4 will connect to P3 via width and slope, but it won’t be the same as the P1 to P2 connection…here’s a hint – reverse the signs!) Here’s what you should be setting up:
P2-P3: OffsetAndDeltaElevation. Offset is 0 and Delta Elevation is Depth.
P3-P4: SlopeAndOffset. Offset is –(Width) and slope is –(Slope).
Let’s switch over to the Preview tab and see what we have so far. It looks good – the magenta cross is the origin (insertion point) and the points are reacting just as we told them to.
Once our points are defined, we will need to add the glue that holds everything together and makes this a subassembly: the links. There’s a little trick to this, which had me banging my head against the desk. I hope this helps you in your quest to build a better subassembly: when you link two points, the link isn’t between the points with regards to the flowchart – the link has to see (be after) both points before you can reference them in the link properties. In trying this out, my mind made the logical assumption that the flowchart would follow the format of P1>L1>P2>L2>P3>L3>P4>L4>P1. Instead, it has to be P1>P2>L1>P3>L2>P4>L3>L4. I know, doesn’t make much sense until you understand the workflow.
To start this process, we will drag in a link and place it graphically between P2 and P3.. It will be named L1, but I will also add a code of Top to it for surface definition purposes. If you try to pick a start point and an end point, the dropdown list will be empty because it’s not connected to anything. In this case, we will break the connection between P2 and P3 and connect from P2 to L1. We can do this by selecting the connection and just dragging the connection points to the link. Once we do, the link will see both points and allow you to select P1 for the start point and P2 for the end point. It stands to reason that we should now connect L1 and P3 to keep the chain alive.You might want to move things around just a bit to make it look correct graphically – just do this by picking the point or link and dragging it – do not select the connection arrows to do this. Now, we go ahead and drag in the other 3 links and connect them, making sure to add the Datum code to the P3>P4 link. Your flowchart should end up looking similar to this one:
Taking a look at the preview pane, it certainly looks like everything is created correctly…now it’s time to test it out!
Before we test it in Civil 3D, we need to get it ready for import into Civil 3D. I had a little problem with this initially, so I’ll tell you what I did wrong so you won’t make the same mistake. On the packet settings, you need to specify a subassembly name – again, I stick to standard naming conventions. You can choose to give it a description, and even write and specify a help file for it (honestly, the subassembly help files are where I learn the most about what these things can do…) Here’s the step that I forgot – specify an image for your subassembly. If you don’t do this, you won’t be able to select it on the tool palette! Imagine me searching for my subassembly after import and not being able to find it – quite frustrating, trust me.I also set a side parameter – I chose left since I am left-handed!
Once the packet settings are defined, just save your drawing somewhere where you can access it from other machines. It will save as a .PKT file, which can be imported into Civil 3D.
That was a great segue, I think – because the next obvious question is “how do I get this file into Civil 3D?” Here’s how: In Civil 3D 2011, go to the Insert tab of the ribbon. From there, select the pulldown on the Import panel and select Import Subasemblies. Your source file will be the .PKT file that you created, and then you pick whether you want to import it to a tool palette or to your subassembly catalog. I’m going to pick the Basic subassembly tool palette and bring it in there.
Which will then show up in my subassembly tool palette:
Now, let’s test it out on a corridor!
That was easy, wasn’t it? You can go a LOT more in-depth with this tool, specifying targets, conditional requirements, etc. Once you learn the workflow, almost anything is possible!
This post does come with a warning label, however:
We have noticed customers running Vault having issues when installing the Autodesk Subassembly Composer. Those users are reporting that it breaks Vault, Here is the official word from our development team:
This is an SAC defect, its installation breaks Vault. I'm really sorry about that, we're busy fixing this issue, and will publish an update soon.
For people haven't installed it: Please do not install this version of Subassembly Composer if you have AutoCAD Civil 3D 2011 and Autodesk Vault installed. After the install Civil 3D may fail to communicate with Vault, and a reinstall of Civil 3D may be required. We are currently looking for a resolution and hope to have a fix soon.
My note: Always keep in mind where you downloaded this from – it is an Autodesk Labs product. Just like anything developed in a lab, there may be some unexpected behavioral issues with it. Treat this as beta software and use it at your own risk!