Showing results for 
Search instead for 
Did you mean: 
Showing results for 
Search instead for 
Did you mean: 
Showing results for 
Search instead for 
Did you mean: 

Assembly program to control program in a component


Assembly program to control program in a component

I have an extension spring modeled up with a program to control 4 different spring lengths.  A free length, and three different extended lengths, 1, 2 & 3.  The assembly that the spring goes into has a program that controls a component offset value to show three different states, 1, 2 & 3.  Is there a way in the assembly program to control the program in the spring model?  What I want to do, is when the assembly is regenerated in the "1" state, I want the spring to regenerate in the "1" position, and do the same for 2 & 3.  Is this possible, if so, how would I go about adding whatever needs to be added to the assembly program to control this?

I've made spring components flexible in the past to control a compressed height.  This spring is an extension spring and has loops modeled on each end, and isn't modeled in an easy way to allow it to be flexible and be stable...I have the program lengths to work without any failing features and would like to keep it that way if possible.

Thanks for any info.



Would you be able to use family tables? If so, you could have instances for each of the four stable lengths and a similar set of instances of the assembly that use each of those lengths.

If you're wanting to change a parameter in the assembly and have the spring change accordingly, that could be done too, with relations. You could set up some relations in the assembly that pass the necessary dimensional changes down to the springs. In case you haven't done this type of thing before, here is the basic way:

(1) In the assembly, enter the relations editor with Tools->Relations

(2) In the editor window that pops up, use the Show->Session ID to get the session ID of the spring component(s).

(3) With the ID number, you can write relations in the assembly to modify components, such as:

    SpringLength:2 = NeededLength

    where "SpringLength" is the part parameter/dimension you want to change, "2" is the Session ID of the part, and "NeededLength" is the target length.

(4) Note that for a part (.prt) the session ID is always an even number (0, 2, 4, ... ).

Hopefully this is helpful.

I will have to play around and see if I can make something work.


21-Topaz I

Look at the Execute statement for the Program to push values from the assembly program to the part program.

you can pick family table members with pro/program. You can also suppress and unsuppress features based on a parameter.

i don't know what the above member means with execute, but you can push values (parameters) from asm to part with a simple relation:

PRM:11 = PRM

where 11 is the target part session ID. you can get it in relations somewhere in the menus.


Replaces the ADD end END ADD

This is for assemblies to link assy input variables to program variables in assembly components.

EXECUTE {PART}/{ASSY } name or variable

input variable of design at next lower level = expression

input variable.....


Thank you for your response.  I'm unfamiliar with how EXECUTE works in a program.  Would you be able explain how it works or how to set it up?

Example my spring is p/n: 210000 and the assembly is p/n: 420000.  Both the spring and the assembly have a shifting program.  The spring has an extended length that changes....input choices are: FREE, 1, 2, 3 & 4.  The Assembly has a program that has an component constraint offset on a component that the spring is attached to, input choices are: 1, 2, 3 & 4.  What I want to do, is when the assembly is regenerated in the #1 state, I want the spring to automatically regenerate in the #1 state as well and so on.  Not sure if that is enough info for you to give me an example how/what to type in the assembly to do this...if it's possible.  Thanks for any info.

Thanks for your response.  In your example

PRM:11=PRM  (was does PRM stand for?)