cancel
Showing results for
Did you mean:
cancel
Showing results for
Did you mean:

Community Tip - You can change your system assigned username to something more personal in your community settings. X

# Mechanism Concept in Vuforia Studio- How to make rotation more easy

No ratings

Mechanism  Concept in Vuforia Studio- How to make rotation more easy

When we try to rotate a model or 3d modelitem about a particular space axis it seldom will rotate about the correct axis as we want.

So, in this case we can try to solve this  when we use  some mathematical calculations. For example in the example(picture below)  -   door assembly we want to rotate  the door subassembly via the door hinges:

but  when we  try to rotate the door model about 60degree it rotates undesired on the wrong axis.

The question is:  Which is this axis and how to change it?

The answer here is : When we have a PVZ model we cannot really change it!

We can use some mathematical relations to get the correct behavior . In this particular sample case the correct javaScript relation should be something like :

```...
\$scope.simple_door_slider_change = function (angle, door_length) {
var angle1=angle;
var l_door=door_length;
\$scope.view.wdg['modelItem-door-asm']['rx'] = angle1 ;
\$scope.app.params['door_angle']=  angle1;
};
...```

So  calling \$scope.simple_door_slider_change(70,0.950); will rotate  this particular door assembly on the correct place:

But what we can do to solve the problem  for more complex assemblies. For example when we want to rotate the door handle. Of course such calculation is no problem but this calculation will be more complex (containing movements and rotations ) and we need to invest significantly more  time for the creation of the mathematical concept of it. The main problem is that mostly we do not know what is the correct coordinate axis for each component.

Unfortunately, the only option, what we have here is to make some consideration already in the Creo Parametric design (or in another Cad tools) . So for example the following part have a default coordinate system. Here on the example picture is the name  PRT_CSYS_DEF.

When we later rotate about the x  in Vuforia Studio  then it will rotate about the X axis of the default csys here “PRT_CSYS_DEF”  So, this means when we have some component which should be later rotated in Vuforia, in this case  we need to pay attention already   in the design and try to  assemble the component were  the default csys is on the correct location.

The default coordinate system in a Creo Parametric model is created with the model and it is not possible to change it later (there is a workaround where we can use an auxiliary  assembly where we can insert the model. In this case we can move the model inside  the auxiliary assembly. The auxiliary  assembly will rotate about the default coordinate axis).

So, the next step is to consider, how to design a more complex mechanism assembly.

Lets consider the following assembly:

When we create a project and then try to rotate  different components (arms) via slider then we will have e.g. the following situation:

So that the one (blue) component is rotated as desired but when we rotate the blue component the green component does not follow it.

Let's create another version of the mechanism were we have the correct behavior:

What is there different?

The answer is that we used a different structure. Here we nested the moved component in further sub assemblies.

It is important that in this case for the modelItems widget defintion in vuforia studio we are not using only a parts  but also  assemblies. So here the subassembly arm 2 was used  for the definition of modelitem which contains the arm1  (part) which is an addtional modelitem.

So in this case we could change the rotation value of the axis and they rotates as desired.

Version history
Last update:
‎Jun 30, 2019 08:49 PM
Updated by:
Labels (1)

Contributors