This action might not be possible to undo. Are you sure you want to continue?
Simulation serves a very important role in robotics development. The following list describes a few of the tasks simulation allows you to perform:
• • • • • Analysis of kinematics and dynamics of robotic manipulators Offline programming Design of different control algorithms Design of the mechanical structure of robots Design of robotic cells and production lines
Given these use cases, the LabVIEW Robotics team is providing some simulator examples for robotics users. In these examples, you can see how to control a simulated NI Robotics Starter Kit robot and a simulated iRobot®.
1.1 Accessing the LabVIEW Robotics Module Help
In LabVIEW, select Help»Search the LabVIEW Help and refer to the Robotics Module»Simulating Mobile Robots topic on the Contents tab of the LabVIEW Help for more information about designing and controlling simulated robots. Note: In LabVIEW, select Help»Find Examples to launch the NI Example Finder, which you can use to browse or search for example VIs.
1.2 Robotics Starter Kit Robot
A Starter Kit robot is a fully-assembled robot base with an ultrasonic sensor, encoders, motors, a battery, and an NI Single-Board RIO (sbRIO) that runs LabVIEW and the LabVIEW Real-Time Module and LabVIEW FPGA Module software. Refer to the Robotics Module»LabVIEW Robotics Starter Kit topic on the Contents tab of the LabVIEW Help for more information about the Robotics Starter Kit.
2 Artificial Neural Network (ANN) Simulation Example
This example demonstrates how to design and validate control algorithms using the robotics simulator in the LabVIEW Robotics Module. The example demonstrates trajectory tracking by applying an artificial neural network (ANN) control algorithm to the simulated NI Starter Kit 1.0.
the velocity controller uses a classical tracking algorithm to control the robot so the robot can get to the reference posture smoothly.Figure 2. • • Analytical function model Artificial neural network (ANN) model This demo shows that the ANN model performs as good as or better than the analytical model. w) according to the difference between P_ref and P. Finally.1 shows the control diagram. v_r) are inputs to the simulator which applies the velocities to the DaNI robot. where P_ref is the reference or desired posture (x. y. (v_l. w) is converted to velocities (v_l. The Artificial Neural Network. orientation) and P is the current posture of the robot. (v. Trajectory tracking control Figure 2. . This example also provides the following two inverse kinematic models. In this example. open the example. 2.1. v_r) of the robot’s left and right wheels. The velocity controller outputs the required linear and angular velocity (v.1 Example Files After installing the Artificial Neural Network (ANN) Simulation example. Then through the inverse-kinematic model.lvproj appears as shown in the following screenshot.
vi is the main VI of this project. When the simulation starts. The following screenshot shows the Front Panel of this VI. the robot follows the path predefined by the red points: .The ANN on Simulated Starter Kit 1.0.
2. Interpolation between elements repeats ntimes. You can view the execution of this VI as representing a virtual vehicle travelling the trajectory at a velocity of linear velocity. y). By default.y) element. y). y. method specifies the interpolation method. 2.vi This VI interpolates between positions in a path made up of (x. ntimes specifies the interpolation locations between every (x. trajectory is array of (x. trajectory returns an array of (x.vi This VI returns the reference postures (x.2.2 Supplementary VIs The simulator example contains a few important VIs. ds). where O is the desired orientation at position (x. 2. ds) values resulting from interpolation.1 Utility_GenerateTrajectory. velocity specifies the real linear velocity of the virtual vehicle. y).2. which are described in the following sections. O.2.vi . y. O. y) positions. O) of the virtual vehicle.2. where O is the desired orientation at position (x. and ds is the distance from the previous point to the current point. this example uses cubic Hermite method. linear velocity specifies the desired linear velocity of the virtual vehicle. virtual posture returns the posture (x. angular velocity specifies the real angular velocity of the virtual vehicle. and ds is the distance from the last point to current point. y. dt specifies the time interval at which to calculate the posture.2 ANN_VirtualVehiclePosture. y. O) required to travel trajectory. path specifies an array of positions (x.3 ANN_GetPosture.
In realworld applications. where O is the orientation.This VI returns the current posture information (x. vref (nan) specifies the reference linear velocity. 2. y. wref (nan) specifies the reference angular velocity. ESN trained specifies the input weight. dt specifies the time interval. which means there is no input of reference angular velocity. current posture specifies the current posture (x. you can acquire posture information from sensors. internal weight. and the reference linear velocity will be derived from desired posture. and output weight.2. y. of the DaNI robot. which means there is no input of reference linear velocity. desired posture specifies the reference posture (x. y. of the DaNI robot. If this input is not wired. O) of the DaNI robot from the simulator. O). the default value is NaN. You can specify the analytical kinematic model or ANN kinematic model options. model type specifies which inverse kinematic model to use. The position input specifies the position (x. If this input is not wired. z) of the DaNI robot’s position. vehicle status specifies the posture (x. wl returns the linear velocity of the left wheels. where O is the orientation. O). y) and the quaternion input specifies the orientation O. quaternion specifies the quaternion of the DaNI robot. . y.4 ANN_4WheeledController. and the reference angular velocity will be derived from desired posture.vi This VI returns the linear velocities of the left and right wheels. y. the default value is NaN. feedback weight. wr returns the linear velocity of the right wheels. position specifies the three dimensions (x. O).