====== Motion Analysis of Lego Pieces ====== **Author:** [[unlv_lee|Joo Won Lee]] Email: \\ **Date:** Last modified on <6/3/2021> \\ **Keywords:** \\ {{:lego:1.png?400|}} \\ {{:lego:const.png?400|}} \\ {{:lego:tutorial:pen.png?400|}} \\ \\ This tutorial will be focusing on how to animate Lego Solidwork parts and calculate & display angle for various cases. \\ \\ ===== Motivation and Audience ===== The motivation of this tutorial is to teach how to animate Solidworks parts via motion study function. Solidworks comes with a powerful tool called motion analysis. The motion analysis tool allows to simulate real life interactions such as collisions, gravity and friction. The tutorial will teach how to analyze simple rotational movement of two bars via this tool. ==== Parts List and Sources ==== * One needs all of the following programs installed on their computer: [[https://my.solidworks.com/|SolidWorks]] (preferably post 2020 version with PREMIUM). Before the tutorial can begin, one must download the following item from google drive. \\ ^ File Name ^ Google Drive Link ^ Note ^ | Isogawa Solidworks Parts | https://drive.google.com/file/d/1KvLF4l2abW-GGuO1T0vRRLwzHVT3o4dG/view?usp=sharing | Ask author or lab member for password | \\ The Only lego pieces will be used for this tutorial. \\ \\ ===== How to Setup ===== \\ You need two lego bar peices connected by an axle \\ {{:lego:tutorial:setup1.png?400|}} \\ Set up the pieces as the following video. \\ {{youtube>lByvIHNT54c?medium}}\\ \\ They must be able to freely rotate about an axle. \\ {{:lego:tutorial:setup2.png?400|}} \\ \\ \\ ==== How to Add Reference Angles ==== \\ Rotate the piece to make an angle. \\ Click "Smart Dimension" on the Sketch tab. \\ Click "Reference dimension" on the menu. \\ Click two pieces where you want to see the angles between. \\ Click Okay when done. \\ {{youtube>7hNemKUkX0o?medium}} \\ \\ ===== Constant Rotation without Gravity ===== \\ Click motion study tab on the bottom \\ Add motor to the piece you want to rotate. (Must apply to the circular section of the piece). \\ Recommend slow RPM (~10 RPM) for more accurate analysis and avoid aliasing. \\ Click the drop down menu on the bottom left to "Motion Analysis" tab. \\ Click Results & Plots \\ Click "Other quantities" from from category drop down menu. \\ Select "projection angles" \\ Select the axis where you need to analyze. For the video, notice that the Y plane is perpendicular to the pieces, thus it Y axis was chosen. \\ Select two pieces that you want to measure the angle between. \\ Click okay, and calculate. \\ To view the plot, click results and click "show plots" \\ {{youtube>4e_Pu72GdlM?medium}} \\ The following graph represents angle vs time of constant motion. \\ Since Solidworks works from -180 degrees to 180 degrees, there is a jump -180 to 180, when it completes 1/2 of the rotation. \\ {{:lego:tutorial:constg1.png?400|}} \\ \\ ===== Nonconstant Rotation without Gravity ===== \\ Create a new motion study by right clicking on the bottom. (If it is the first motion study, just click the motion study tab. \\ Select motor and select data points. \\ Input your desired acceleration and speed numbers in the chart. \\ Move to motion analysis tab \\ Make a projected angled graph. \\ Click calculate. \\ {{youtube>l3-3SE0TJ70?medium}} \\ Unlike constant rotation, the projected angles will have accelerating/decelerating curvatures. \\ {{:lego:tutorial:constg2.png?400|}} \\ \\ ===== How to Add Gravity in Motion Analysis ===== \\ Create a new motion study profile. (Right click motion study tab at the bottom) \\ Click gravity icon. \\ \\ {{:lego:tutorial:grav1.png?400|}} \\ \\ Define direction and acceleration of the gravity. \\ \\ {{:lego:tutorial:grav2.png?400|}} \\ Click okay. \\ \\ Gravity is only calculated in the motion analysis section of motion study. \\ \\ ===== Rotation with Gravity without Friction ===== \\ Gravity without friction can cause problem. \\ The way Solidworks motion analysis calculates acceleration and momentum will cause error. \\ This might be because the bar is accelerating too fast for the computer to properly calculate some of the movement values. \\ Due to this calculation error, the bar may accelerate enough from free fall to rotate all the way around. \\ {{:lego:tutorial:grav3.png?400|}} \\ Thus, it is not really useful to view data beyond certain point with normal gravity's acceleration (9.82 m/s^2) \\ \\ One way to remedy this issue is to reduce gravity's acceleration by 100. \\ This looks like it fixes the issues as calculations become more precise for the computer to handle. \\ {{youtube>Ae13yWPijn0?medium}} \\ {{:lego:tutorial:grav4.png?400|}} \\ The 1/100 gravity will produce a perfect sine wave. \\ \\ ===== Rotation with Gravity with Friction ===== \\ Unlike acceleration without friction, once you add friction to the calculation, the normal gravity's calculation will not cause error. \\ \\ One must add friction in the assembly area before motion analysis can be done. \\ Click the part where the both bar and pin surfaces meet and add friction to it. \\ Add a friction (u value). \\ {{youtube>S4-8ImeFRiI?medium}} \\ \\ {{:lego:tutorial:grav5.png?400|}} \\ The graph will show a decaying oscillation. \\ \\ ===== Result ===== \\ Using motion analysis tool in the Solidworks, one will be able to analyze the angle displacement of various objects. \\ Motion analysis tool is a powerful tool that can be used for analyzing or simulating motion for different purposes. \\ As a personal example, I used motion analysis to calculate the power consumption and torque required to purchase the right motor. \\ The simulation can be a very helpful tool for any future projects. \\ \\ {{:lego:tutorial:torque_power_data3_with_gravity_.png?400|}} \\ Trying to calculate the maximum torque required to rotate the bin and see how much power is needed. \\ ===== Final Words ===== \\ This tutorial went over the following tasks: \\ -How to use motion analysis \\ -How to add reference angles \\ -How to add gravity \\ -How to view angle displacement on a graph \\ -How to add friction \\ \\ For questions, clarifications, etc, Email: