Two link mainpulator

 comp.robotics.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Two link mainpulator Methods-MaN 01-14-2007
Posted by Methods-MaN on January 14, 2007, 12:43 pm
Please log in for more thread options
i`m working in a project to design to link arm that writes letters or
draws some simple figure(sqaure,traingle).i obtained the inverse
kinematic and simulated the mechanasim in mathlab.I could draw cicrle
my question is how i can modify my program to draw a suqaure or
trianlge or even letters?
this is the mathlab code:

clear all
close all
clc
clear
t=0:0.1:2*pi;
r=1; //raduis of the cicle
n=length(t);
l1=1;
l2=1;

for i=1:n;
x(i)=r*cos(t(i));
y(i)=r*sin(t(i));

c2=(x(i)^2+y(i)^2-l1^2-l2^2)/(2*l1*l2);
s2=sqrt(1-c2^2);
th2(i)=atan2(s2,c2)
k1=l1+l2*c2;
k2=l2*s2;
th1(i)=atan2(y(i),x(i))-atan2(k1,k2)
x1=l1*cos(th1(i));
y1=l1*sin(th1(i));
x2=x1+l2*cos(th1(i)+th2(i));
y2=y1+l2*sin(th1(i)+th2(i));
line([0,x1,x2],[0,y1,y2]);hold on;pause(0.5);


end;


Posted by howy on January 14, 2007, 1:54 pm
Please log in for more thread options
>From what I can guess, you will need to replace the two lines of code
x(i)=r*cos(t(i));
y(i)=r*sin(t(i));
(that fill the x() and y() arrays with all the points in a circle) with
a table that fills x and y with the points that compose a letter or a
square.

This program is filling x and y with a bunch of points for the arm to
go to.
If you have a PCB design program, the gerber file output could be used
to give you a list of points that make up text and shapes. I imagine
there must be simpler ways to convert text to line segment data (like
maybe PostScript).
Note you will need a "Lift pen" command in there somewhere.

-howy





> i`m working in a project to design to link arm that writes letters or
> draws some simple figure(sqaure,traingle).i obtained the inverse
> kinematic and simulated the mechanasim in mathlab.I could draw cicrle
> my question is how i can modify my program to draw a suqaure or
> trianlge or even letters?
> this is the mathlab code:
>
> clear all
> close all
> clc
> clear
> t=0:0.1:2*pi;
> r=1; //raduis of the cicle
> n=length(t);
> l1=1;
> l2=1;
>
> for i=1:n;
> x(i)=r*cos(t(i));
> y(i)=r*sin(t(i));
>
> c2=(x(i)^2+y(i)^2-l1^2-l2^2)/(2*l1*l2);
> s2=sqrt(1-c2^2);
> th2(i)=atan2(s2,c2)
> k1=l1+l2*c2;
> k2=l2*s2;
> th1(i)=atan2(y(i),x(i))-atan2(k1,k2)
> x1=l1*cos(th1(i));
> y1=l1*sin(th1(i));
> x2=x1+l2*cos(th1(i)+th2(i));
> y2=y1+l2*sin(th1(i)+th2(i));
> line([0,x1,x2],[0,y1,y2]);hold on;pause(0.5);
>
> end;


Similar ThreadsPosted
FAQ Link for This Group December 10, 2005, 4:19 am
Security robot link June 24, 2005, 2:01 pm
encoder link might be usefull August 1, 2006, 11:21 am
Aibo, SDR, and Qrio, Missing Link? September 18, 2005, 8:33 pm
camera link frame grabber April 21, 2006, 6:59 am
Re: he will cool the short link and crack it except for its grave November 10, 2007, 3:42 pm
Re: Cheap idiot-proof season-link PVR December 25, 2007, 3:52 pm
Re: Zelda: Oracle games and the "link" system December 27, 2007, 1:41 pm
Bluetooth link to replace serial cable for OOPic January 31, 2006, 12:26 pm
Link for Joining the FPGA/CPLD Design Group on LinkedIn June 14, 2008, 9:37 pm

The site map in XML format XML site map
other useful resources:
Official Robosapien Website
Lego Mindstorms Website

Contact Us | Privacy Policy