Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need help! Plotting a 3d model of a robot arm workspace!

Status
Not open for further replies.

kuv

Mechanical
Nov 29, 2003
8
I trying to model the 3d workspace of the robot arm. Below is the matlab syntax. Px,Py,Pz is the goal position. q1,q2,q3 is joint angle limits. a1,a2,a3,d1 and d4 is link parameter.

a1=150;
a2=600;
a3=100;
d1=400;
d4=600;
q1=linspace(-170,170);
q2=linspace(-90,155);
q3=linspace(-170,190);
Px=(a1.*(cosd(q1)))+(a2.*((cosd(q1).*cosd(q2))-(sind(q1).*sind(q2))))+(a3.*((cosd(q1).*cosd(q2))-(sind(q1).*sind(q2))).*(cosd(q3)))+(d4.*(cosd(q1)).*((sind(q2).*cosd(q3))+(cosd(q2).*sind(q3))));
Py=(a1.*(sind(q1)))+(a2.*(sind(q1)).*(cosd(q2)))+(a3.*(sind(q1)).*((cosd(q2).*cosd(q3))-(sind(q2).*sind(q3))))+(d4.*(sind(q3)).*((sind(q1).*cosd(q2))+(cosd(q1).*sind(q2))));
Pz=(a2.*(sind(q2)))+(a3.*((sind(q2).*cosd(q3))+(cosd(q2).*sind(q3))))-(d4.*((cosd(q2).*cosd(q3))-(sind(q2).*sind(q3))))+d1;

Can anyone pls show me how to plot the Px,Py,Pz graph?
Thanks
 
Replies continue below

Recommended for you



You need to add bones and flesh to the 3d points that you have created. That is amazingly tiresome to do properly, you will need to add orientation points to each rigid body.

Then you could create a subroutine that can work out the screen coordinates of a given 3d location.

You will need to use similar triangles if you do it the way I did it.



Cheers

Greg Locock

Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.
 
Thanks for the tips! Do you have any example file of it?
 
No, I did it in Excel.

Cheers

Greg Locock

Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor