Company Events Academic Community Support Solutions Products & Services Contact NI MyNI

Forward Dynamics VI

LabVIEW 2013 Robotics Module Help

Edition Date: June 2013

Part Number: 372983D-01

»View Product Info

Owning Palette: Dynamics VIs

Requires: Robotics Module

Computes the joint angles and movements of a robot arm that result from applying a given amount of torque to the arm over a period of time.

.m file: fdyn

This VI uses the ODE Solver main instance of the ODE Solver VI to calculate forward dynamics for the robotic arm.

Example

data contains arbitrary values that pass to the VI that implements the function.
torque function is a strictly typed reference to the VI that implements the torque function. Create this VI by starting from the VI template located in labview\vi.lib\robotics\Kinematics\dyn\torque_function.vit.

serial arm in is a reference to a serial robotics arm. Use the Initialize Serial Arm VI to generate this LabVIEW class object.
integration data defines the initial configuration of the robot.
initial joint position specifies the joint angles of the robotic arm pose at which to begin calculating the solution.
initial joint velocity specifies the velocity of each joint in initial joint position.
error in describes error conditions that occur before this node runs. This input provides standard error in functionality.
simulation parameters specifies the set of parameters used to compute the forward dynamics solution.
Initial Time specifies the time at which to start the ordinary differential equation (ODE) solver. The default is 0.
Final Time is the time at which the ODE solver stops.
Time Step is the interval between the times at which the ODE solver evaluates the model and updates the model output, in seconds. LabVIEW uses this parameter only if you select a fixed step-size ODE solver.
Absolute Tolerance specifies the absolute tolerance the ODE solver uses to control the error.

For y' = f(y), the ODE solver maintains error ≈ |y| * relative tolerance + absolute tolerance.

LabVIEW uses this parameter only if you select a variable step-size solver. Variable step-size solvers use this error to adjust the step size. If the error is too large, the variable step-size solver reduces the step size. If the error is too small, the variable step-size solver increases the step size. Absolute tolerance is most significant when y is small.
Relative Tolerance specifies the relative tolerance the ODE solver uses to control the error.

For y' = f(y), the ODE solver maintains error ≈ |y| * relative tolerance + absolute tolerance.

LabVIEW uses this parameter only if you select a variable step-size solver. Variable step-size solvers use this error to adjust the step size. If the error is too large, the variable step-size solver reduces the step size. If the error is too small, the variable step-size solver increases the step size. Relative tolerance is most significant when y is large.
Continuous Solver is the type of ODE solver used to evaluate the simulation diagram. The default is Runge-Kutta 45 (variable).

0Runge-Kutta 1 (Euler)
1Runge-Kutta 2
2Runge-Kutta 3
3Runge-Kutta 4
4Runge-Kutta 23 (variable)
5Runge-Kutta 45 (variable)
6BDF (variable)
7Adams-Moulton (variable)
8Rosenbrock (variable)
9Discrete States Only
Discrete Time Step specifies the base time step to use for discrete functions, in seconds. The ODE solver might not evaluate a discrete function every Discrete Time Step. The ODE solver evaluates the discrete function and updates the function output every n discrete time steps, where n is the sample rate divisor parameter you specify for that function.
Note  If you select a fixed step-size solver, the Discrete Time Step must be an integer multiple of the Time Step. If you specify a Discrete Time Step that is not an integer multiple of the Time Step, LabVIEW displays a run-time error when you attempt to run the simulation.
Minimum Time Step specifies the smallest time step size the ODE solver can use to evaluate the simulation diagram. LabVIEW uses this parameter only if you select a variable step-size solver.
Maximum Time Step specifies the largest time step size the ODE solver can use to evaluate the simulation diagram. LabVIEW uses this parameter only if you select a variable step-size solver.
Initial Time Step specifies the time step size for the first time step of the simulation diagram evaluation. LabVIEW uses this parameter only if you select a variable step-size solver.
serial arm out is a reference to a serial robotic arm. You can wire this output to other Robotic Arm VIs.
joint position trajectory contains the calculated joint angles of the robotic arm pose where each row represents a pose at a particular time and each column represents a particular joint.
joint velocity trajectory contains the calculated velocity of each joint in joint position trajectory.
error out contains error information. This output provides standard error out functionality.
times is the array of points in time at which the differential equation solver stepped or was evaluated. If you select a fixed step-size solver, then times contains evenly spaced values.

Example

Refer to the Robot Arm Examples.lvproj in the labview\examples\robotics\Robotic Arm directory for an example of using the Forward Dynamics VI.


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit