Thursday, 30 April 2015

Edit iProperties with global forms

I’m fed up with this problem so I’ve decided to solve it and since the result came out pretty nice I will share it with you and will try and cover but fusion fittings next time.
                 - You have a drawing with multiple LOD’s (Level of Detail) and you want to change iproperties of the model like for example if you need to change the description of the model. So you right click on a view it could even be the main view, main LOD and select open. You try and change some iproperties and Inventor throws a window telling you that you that a different LOD is being edited and before you close that you can’t save the assembly!
WHAT…. I am just trying to change iproperties, what’s that got to do with LOD? See my post on Inventor forum here :
- You need to have multi-line iPropertie texts in the title block and you need to control what goes on each line, control the end of line.
                 - You got bored opening models just to can alter properties, especially on large assemblies.
                - You don’t want to hunt for different ipropeties on different tabs, rather lazy want them all in one place for fast editing
                Create a form that will edit the properties without opening the assembly, where you add all your needed info in one page with multi-line iProperties on it.

                First you need to setup the folder for your iLogic codes so go to Tools / Options / iLogic Configuration and add a folder in your “External Rule Directories”. This way you can use external rules and keep your drawing template clean and small.
                If you’re working in a shared environment you might want to copy all your design data on a shared network drive because any external forms you add will be available to all your colleagues this way. The files will be located in ..Design Data / iLogic / UI.
                Open a drawing (could be your template.idw) and click on Manage/iLogic/iLogic Browser and head over to global forms tab. Right click create a new form, give it a proper name (Label field) and make sure Modal is set to false (so you can do other stuff in Inventor while this is open on top).

                 Click ok for now and let’s add a couple of empty iLogic rules that will appear as buttons on our form.
                Head over to the “External Rules” tab on the iLogic browser pane and create new external rules by right clicking. This is what I’ve added:
·         “iPropsFromModel” – to copy existing properties from the model.
·         “iPropsToModel” – in case you want to update the model with the drawing iproperties.
·         “DrawingCheckIn” – if you use vault you can check the drawing and model back to vault.
·         “Drw_Create_Parameters” – this will create the multi-line properties if they don’t exist in the drawing
·         “Drw_Update_iProps” – to force update the iproperties with our multi-line parameters
·         “Save_PDF_DWF” – to automate creation of PDF’s and DWF’s

                In order to add things to your form you need to drag them from the left pane, “Parameters”, “Rules”, “iProperties” or “Tollbox” into the top right pane in the order you want them to show up. Here’s the sequence from my form:

                Resizing the form while editing it is not persistent, so you need to run the form and choose "resize Controlls" while right cliking on the form, check my previous blog here:

                All iProperties are multi-line texts but the iproperties window will only show you the last line of text and will allow you to control the end of line just for the “Comments” field. To test it out type your custom text inside “Comments” and call it in “Description” by adding this formula =<Comments> and you will see the title block showing your line-by-line formatted text.
                You can add Description to your form but it doesn’t display as multi-line and for that you need to create custom parameters, in my case called the same for simplicity: Description and Project.
                Now you can add the above parameters to your form and change “Edit Control Type” to “Multi-line Text Box”. Make sure you resize your form so you can better see all the lines, I keep mine to 3 visible lines but as soon as you pass that the scrollable arrows become active on the right.

                I could have included some of these codes inside the drawing template but I want to keep it as clean as possible, minimizing crashes and problems when upgrading to new releases of Inventor.
                The other reason I have separate button (code) for creating Description and Project parameters is so that you can edit old drawings for which you would have to recreate the ilogic rule. Remember that those drawings don’t have Description and Project as parameters so you either add them manually or run this code. You can easily copy an external rule into the document or you could have used code injector to push this code into a batch of drawings. Here’s the link for codeinjector.
                I think it’s not worth the hassle; it’s just one click away to create the parameters in the form so I suggest you add this button to your form even though you might not use it all the times.
                Because I want this form to show up automatically with each new drawing I need to add a small ilogic code inside the drawing template and trigger it before save. The code has a nice trick to only pop-up the form at first time you save the drawing. I don’t want to see it every time I save a drawing especially on large assemblies.

                The trick was to check if the drawing was saved before, having a path on disk and for that we’ll use “IsNullOrWhiteSpace” to verify it. If it doesn’t have a path then just before saving the drawing fire up the form. The drawing still saves but the form shows up as well.
                  Here isthe drawing (AIP 2015), the rules and the form included (you need to copy it over to global forms).
                This way I can edit the model iProperties without needing to open the model which throws out that ugly error about different LOD being edited.


Wednesday, 22 April 2015

Tube and pipe construction lines

Last week I’ve shown you how to do mixed styles routes and how to align the 3D ortho tool and now it’s time to discuss construction lines for Tube and Pipe module of Autodesk Inventor. At this point I wonder how many of you are using them and even know of their existence?
The place command is hidden, you cannot change them to normal and vice-versa, they are always visible in the model and drawing and yet there are times when you might need them.
Can’t say I blame you if you’re not using them, you can do away with just dimensions and constraints but I found them useful at times and that’s why I decided to share this post.

They could be annoying being visible all the time but you can hide the route if need to and on the positive side you can edit the route really quick by double clicking on the visible lines.

The command is not on the ribbon and it can only be invoked by right clicking on a node inside the route. This is only available for route nodes, not on construction line nodes, and it’s only available in the contextual menu while you are in the main Tube and Pipe environment. If you open the run on itself and try to edit the route you won’t have the option to do construction lines.

On each node you can start multiple construction lines but keep in mind that you need to constrain them even though you used the triad axis when drawing them. Regular segments get constrained at least collinear or perpendicular with previous segments, while construction lines are floating in model space with just one end connected to the starting node.

In the image bellow I am constraining the tee center in between the pumps by first creating a construction line from one pump center to the second. Then I am doing a different line starting from the tee node perpendicular to the first one and coincident with the middle of first one.

A more eloquent example might be when you need to dimension you route at an angle for which you can’t use included geometry. At this point you can’t add dimension between segments and planes, just to nodes and to get it right you might need to play with formulas and trigonometry.

Using construction lines you can constrain the projection of the angled segment into a plane that suits you where dimensions can be applied.
As you can see in the image bellow I have created a couple of construction lines to serve as projection of the angled segment. There is a third one that is constrained against the run origin (included geometry) and is used as fixed reference to dimension against.
In the last example that I have used construction lines to form a grid to which I have constrained my nodes. This will work similar to reused dimensions but it’s less messy, and the route is a little neater.

Start a construction line and constrain it to your references, I would recommend that you use include geometry on run origin planes. Keep your external references to a minimum, try to avoid faces that could change leaving you with broken links. Keep these as local as you can just like my run planes.
Constrain this construction line coincident to one of the points, it doesn’t need to be the farthest away, and you could even just use a small dimension to minimize its visual impact outside of the route. Coincide the rest of the points that lay on this line even if it doesn’t passes through them. The points will be in line with the construction segment.
At this point you just need to dimension one of the nodes and the rest of them in-line will follow.

The good part is that Inventor doesn’t generate a pipe segment where you’ve used construction lines but you can’t switch them back and forward as you might expect. Once you’ve done it as construction you need to remove it and draw it again as regular if you need a pipe segment there.
The drawing environment is having the same visibility problem with this type of lines. As soon as you use include route centers it will bring over the construction lines as well. You then need to turn visibility off by selecting them individually or with window select.

And that’s how you can use construction lines to help you speed up your design.

As usual, there’s a video.


Thursday, 16 April 2015

TP Mixed Styles and Align 3D Ortho Tool

Let’s discuss mixed styles and aligning the 3D ortho tool for today. I am not talking about mixed flange styles but having route with both fittings and bends all in one route.
In some cases you’re having a route with fittings but for space and/or access consideration you might need a custom bend segment to be manufactured. While routing a “Rigid Pipe with Fittings” you can actually switch on the fly to creating segments with bends.
Once inside the sketch after starting the route command if you right click you will find a “Custom Bend” option on the contextual menu.

As soon as you choose Custom bend, the direction arrows change from straight to arc and 4 more arrows appear on the node. If you click on any of the node arrows, or start typing while holding your mouse over them it will change the value of the bend radius. You can do it globally not in the styles but in the parameters where a User Parameter “B” stores the default bend radius value.

Once you finish orientating the triad and you specify a distance you will end up with a fillet between your segments. This is not perfect and if you ask me when bending 90 degree it should constrain the segments perpendicular to each other and at all times the arc segment should be tangent with the straight lines but it’s not doing it. I’ve had times when the new segment was constrained to existing straight lines automatically but most of the times you need to constrain it yourself.

Sometimes these are not enough so you need to add a dimension angle between the segments and draw some construction lines to help you dimension the segment but more on that next week when we’ll cover construction lines in detail.

If your beds are 45 or 90 degrees only and you need more than one bend I would not bother to use Custom Bend especially since you need to activate it for every new segment you create. I would do my sketch as usual and then use the bend command in the Create tab of the route to add a radius between straight segments.

When you populate your route it will create straight pipe segments with fittings and sweep pipe segments from the same route.

This only works on “Rigid Pipe with Fittings” style where you have declared your fittings in the style setup, because in “Tubing with Bends” style you have no fittings declared and Inventor doesn’t know what fittings to populate.
You can drop a fitting into a tube segment and it will split that pipe segment in two separate segments.

You can also delete the arc segment inside the sketch connecting the straight segments but if the angle is not 45 or 90 (selected fittings in style) you will get a route violation, angles no permitted. If the angle is.

What’s all this got to do with aligning the 3D Ortho Tool? If you use the align command and the consecutive segments are not 45 or 90 degrees it will create a custom bend. Sometimes even if the angle is permitted by the route it will still ad a fillet for custom bend but you can remove it as described above.
If you find yourself having the 3D orho tool skewed or you want to align it to existing geometry you can do that by right clicking on the axis to align and choosing “Parallel With Edge” or “Perpendicular To Face”. This works for all axes so you can change them one after the other to an advanced align like for example if you needed to match those on the origin (check graphical window lower left corner). The colours of the ortho tool match those on the UCS origin, red X, green Y, blue Z making it really easy to do this.

And that’s it for today. Join me next week when we’ll discuss construction lines, how use them in sketching your routes faster and constrain them on weird angles.

And the video:


Wednesday, 8 April 2015

Tee Branch and Route Editing

Last post on Inventor was about authoring T&P clips and today I will cover just a bit about route editing and tee branching.
After doing a quick layout and pipe laying it become obvious that the filter in the image bellow is too close to the building column. It needs to move left but there is not enough room with the route in the current state. I need to move the tee around the corner just before the discharge flange. I need to insert an elbow between the by-pass tee and the one with the sample valve.

 You could extend the flange segment and insert the tee but you would then need to disconnect/connect the sample valve as well and if you use component tagging (my post here) you will have to tag them again. What we want is to move the elbow along with the sample valve altogether around the corner.
First I will disable the building so that it becomes un-selectable, transparent ghost like. This will allow me to work around it and still visually see the impact of my changes. Now I will modify my selection filter to part priority and double click on the route end to start editing it.

 The eeg (elbow + elbow + gap) dimension right before my tee needs to increase so that I can insert a node without Inventor complaining about violating the minimum allowed distance.

Then I can insert a node and remove the collinear constraint so that I can pull my segments just about 90degrees before I constrain the route. Otherwise I might have the route flipping in the wrong direction therefore I will pull it a bit so when constrained it will solve a minimum move.

Now I can move the filter and remove the extra node (new socket coupling) just before the flange.

Note: The filter here is placed and constrained at the top level assembly but it’s been authored and it’s droppable as a T&P fitting.

So in order to keep the fittings you need to keep the nodes in place. If I want to move the filter and the by-pass route I will insert two nodes and delete the segment in between them. Removing the segment without adding new nodes would delete the end fittings as well (my tee).

I use this lot and it’s very good for when moving equipment. I usually insert nodes, brake routes before moving equipment because the route goes into violation mode and it becomes locked. At that point you can’t insert nodes, you can only delete segments which will remove fittings at the nodes and you can only remove constraints which is not helpful enough.
 The last thing I’ll show you today is how to add tees. In the image bellow I want to have a tee branch where the socket coupling is. There are 3 ways of doing this:

1 – Inset the tee at the top level assembly and constrain it. Connect your routes to it.
2 – Just like in my image drop a tee on top of the coupling and start a new route from it.
3 – My favourite method, especially when having same route size is to have one single route.
Because Inventor doesn’t allow branches you can’t connect the line end points (3 lines or more) but you can have the 3’rd line at a distance and fix it with dimensions and constrains.

So how do you create a nother line especially when route end points are conencted ? This is where you become creative and start routing at any allowed geometry anywhere in space and remove the first segment and the included geometry that Inventor adds when you start a new route segment. Then you constraint those floating segments to your node at a distance constrained in the T position.

When you finish the route you just need to drop an elbow on top of the coupling or whatever fitting you have specified in the style settings.

Maybe you were using this methods already still, I hope you found it useful. Join me next time when we’ll show you how to work with mixed route styles and how to align the 3D Ortho Tool when it’s really skewed.
And the video: