SolidWorks 2011 Assemblies Bible - Matt Lombard [203]
A motor, gear, and ratchet assembly driven by Basic Motion
To set up this example, apply a counterclockwise motor to the inside circular edge of the gear, and select the block as the reference part. In this example, start the motor with a slow rpm (revolutions per minute), move the timebar out a few seconds, and assign a faster speed, so the motor speeds up over time.
The linear spring is easy to apply. Select the locations of both ends. This example has circular bosses on the block and the ratchet to hold the spring.
Animating a chain and a spring using motors
Two of the most common requests from people learning how to make animations in SolidWorks are animating chains and springs. This is a simple animation, but it uses a couple of tools that you should know about. Earlier in this chapter, the Yoke Link assembly was used to demonstrate how to flex a strap by using in-context relations and a loft. This chain-gear-spring example uses motors to drive a chain, which drives gears and flexes a spring. The spring is a modeled element, not part of Basic Motion. The driving element is a motor. Figure 23.32 shows the assembly ready for animation.
FIGURE 23.32
One simple assembly can demonstrate several animation ideas.
Open the chain assembly.sldasm from the Animation folder on the DVD. The assembly consists of the following components:
2 assembly sketches
1 assembly plane
1 assembly axis
30 parts making up the chain
2 gears
1 spring (modeled in-context, connecting the end of the chain to Plane1)
This is achieved with 98 mates and 1 in-context relation. The animation is driven by a single linear motor.
The model is created by first drawing Sketch1, which represents the path of the chain. This consists of lines and tangent arcs. Next, in order for the path to be a single smooth, continuous entity, a second sketch is created and Fit Spline is used to lay a spline over the lines and arcs. A very small tolerance value is used so that the curvature comb for the spline looks as close to a line-arc combination as possible.
Several copies of the two chain pieces are then placed into the assembly. The Multi-mate mode is used to mate the Front plane of every link to the Front plane of the assembly. Next, each link is given a line that goes between the centers of each pivot. This makes it easy to connect each link to the other (with endpoint-to-endpoint coincident relations).
The final chain mate is to use Multi-mate mode again, and mate the endpoints of the pivots to the spline. This works best if you pre-position the chain links before mating them so that the chain doesn't double up or kink in any spot.
With these mates in place, the chain slides smoothly back and forth on the spline, through the S-shaped curve. Even if your computer is not particularly powerful, it should still handle even dynamic assembly motion just fine with a 15-link chain.
The gears are positioned at the centers of the arcs from Sketch1. The tricky part of the gears involves using the rack-and-pinion mate to match the linear motion of the end chain link to rotary motion of the gear. Because this is just for an animation, and not a real analysis, idealizing the assembly in this way does not have any adverse effects.
The construction of the spring is to simply use a straight line as an in-context connector between the last link of the chain and Plane1 of the assembly. This line is then used as the path of a sweep with twist enabled, which is a reasonable approximation of a spring for an animation. It doesn't flex for dynamic assembly motion, but for an animation, it does.
All that remains is the motor. Figure 23.33 shows how the motor is driven. It is a linear motor, with the Oscillating motion. The Displacement vs. Time chart shows how much the chain moves during the 6-second animation. You can also see the chart as showing how much the spring extends or retracts.
While this assembly and animation are simple, they demonstrate many of the techniques that you need to know to make animations that are more complex. Motors