0% found this document useful (0 votes)
7 views

Lab 5 Update

Uploaded by

faizan ahmad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views

Lab 5 Update

Uploaded by

faizan ahmad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

To simulate the robot and perform forward kinematics based on the provided instructions, follow

these steps:

1. Create Simulink Model:


Start by creating a new Simulink model where you will simulate the robot and perform forward
kinematics.

2. Import Robot Model:


Use an m-file or script to import the robot model defined in Simulink, which contains the SimScape
model of the robot we Made in Lab 4.

ts = 0.001; % Sampling time (1 millisecond)


dof2_arm = importrobot('Rigidbodytree');

3. Configure Joint Properties:


Set up the joint properties for each joint in the robot:
Joint 1: Set limits (`-90` to `90` degrees), actuation (motion provided by input), and sensing
(position).
Joint 2: Set limits (`-60` to `60` degrees), actuation (motion provided by input), and sensing
(position).

Then we make Subsystem of whole this Robot. And named that as ROBOT.
4. Generate Motion Commands:
Use sine wave generators to produce motion commands for each joint (`q1` for Joint 1 and `q2` for
Joint 2), respecting the joint limits.
5. Implement Forward Kinematics Algorithm:

 Get Transform Block: Use the "Get Transform" block from the Robotic System Toolbox.
 Configure the block with the rigid body tree (`dof2_arm`) and joint configuration signals
(`[q1, q2]`).
 Coordinate Transformation Block: Use a coordinate transformation block to extract the
end effector position from the homogeneous transformation matrix.

 Create Subsystem of above and named Forward Kinematics.

6. Visualization and Analysis:

 Scope: Set up a scope to visualize the results:


 Show joint positions (`q1` and `q2`) alongside the desired motion commands.
 Show the calculated end effector position (`x`, `y`, `z` coordinates).

7. Run Simulation:
Run the Simulink simulation to observe the robot's motion and the calculated end effector position
based on the provided joint commands.
8. Analysis:
Analyze the simulation results from the scope to verify that the robot follows the desired joint
motions and to observe the end effector's position.

9. Further Development:
Experiment with different trajectories, joint configurations, and robotic algorithms using the
Robotic System Toolbox and Simulink to explore more complex behaviors and functionalities.

Conclusion:
In conclusion, this lab exercise demonstrated the essential steps in simulating a robotic system using
Simulink and the Robotic System Toolbox. We successfully imported a robot model, configured joint
properties, generated motion commands, and implemented forward kinematics to calculate the end
effector position. The visualization through scopes allowed us to observe the joint movements and
verify the calculated end effector positions.

You might also like