<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.robolabo.etsit.upm.es/index.php?action=history&amp;feed=atom&amp;title=PhantomX_Reactor_Robot_V1</id>
		<title>PhantomX Reactor Robot V1 - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.robolabo.etsit.upm.es/index.php?action=history&amp;feed=atom&amp;title=PhantomX_Reactor_Robot_V1"/>
		<link rel="alternate" type="text/html" href="https://wiki.robolabo.etsit.upm.es/index.php?title=PhantomX_Reactor_Robot_V1&amp;action=history"/>
		<updated>2026-07-17T08:27:14Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.25.3</generator>

	<entry>
		<id>https://wiki.robolabo.etsit.upm.es/index.php?title=PhantomX_Reactor_Robot_V1&amp;diff=2086&amp;oldid=prev</id>
		<title>Aguti: Created page with &quot;__TOC__  &lt;b&gt; Note: &lt;/b&gt; Most of the information of this website is obtained from:  https://emanual.robotis.com/docs/en/parts/controller/openrb-150/#install-the-arduino-ide Ple...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.robolabo.etsit.upm.es/index.php?title=PhantomX_Reactor_Robot_V1&amp;diff=2086&amp;oldid=prev"/>
				<updated>2026-06-11T18:00:03Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;__TOC__  &amp;lt;b&amp;gt; Note: &amp;lt;/b&amp;gt; Most of the information of this website is obtained from:  https://emanual.robotis.com/docs/en/parts/controller/openrb-150/#install-the-arduino-ide Ple...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;__TOC__&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt; Note: &amp;lt;/b&amp;gt; Most of the information of this website is obtained from: &lt;br /&gt;
https://emanual.robotis.com/docs/en/parts/controller/openrb-150/#install-the-arduino-ide&lt;br /&gt;
Please refer to the previuos link if you need more information.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h1&amp;gt; Configuring the environment  &amp;lt;/h1&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Setting up the Arduino Software &amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Download the Arduino IDE according to your operating system from: https://www.arduino.cc/en/Main/Software . &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Install the Arduino IDE &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; If you have chosen to download the installer, run the installer and install the software in a path of your convenience. &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; If you have chosen to download the sources (Linux or zip on Windows), uncompress the software in a path of your convenience &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open/run Arduino IDE, so it will create all the folders needed&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close Arduino IDE &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Installing Tools and Libraries &amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Download the robot libraries from: [[https://www.robolabo.etsit.upm.es/wikiFiles/Arbotix-arduino-1-6.zip here ]]. &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Uncompress the libraries to a path of your convenience. In this file you will find two folders: &amp;lt;b&amp;gt; hardware &amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt; libraries &amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Copy both folders to the &amp;lt;ARDUINO_MAIN_DIRECTORY&amp;gt;. In some Windows you will find this folder in &amp;lt;i&amp;gt; My Documents\Arduino\ &amp;lt;/i&amp;gt;, while in others you will find it in &amp;lt;i&amp;gt; Documents\Arduino\ &amp;lt;/i&amp;gt;.&lt;br /&gt;
In Linux you will find this folder in &amp;lt;i&amp;gt;~/Arduino/&amp;lt;/i&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt; Important: &amp;lt;/b&amp;gt; If you already have a &amp;lt;i&amp;gt;libraries&amp;lt;/i&amp;gt; folder inside your &amp;lt;ARDUINO_MAIN_DIRECTORY&amp;gt;, move the content of the &amp;lt;i&amp;gt;libraries&amp;lt;/i&amp;gt; folder downloaded inside the &amp;lt;i&amp;gt;libraries&amp;lt;/i&amp;gt; folder of &amp;lt;ARDUINO_MAIN_DIRECTORY&amp;gt;.&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Check installation &amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open/run Arduino IDE &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open a Robot Test: &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
File -&amp;gt; Examples --&amp;gt;ArbotiX --&amp;gt; Tests --&amp;gt; ReactorTest&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; Select the Arbotix board &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Tools -&amp;gt; Board -&amp;gt; ArbotiX Std&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; Compile the program &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Program-&amp;gt; Verify/Compile&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there is no errors, you are ready for the next step.&lt;br /&gt;
If you found some errors, please review the previous steps.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; Close Arduino IDE&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h3&amp;gt; Installing FTDI drivers &amp;lt;/h3&amp;gt;&lt;br /&gt;
If you are using Linux or Mac, skip this step.&lt;br /&gt;
If you are using Windows, power up the robot and connect it to your computer.&lt;br /&gt;
Windows should ask you to install some FTDI drivers to be able to connect to the robot.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h1&amp;gt; Hello World example  &amp;lt;/h1&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have created a helloWorld example to test the communication with the robot.&lt;br /&gt;
Please download it from [[https://www.robolabo.etsit.upm.es/wikiFiles/ROB-HelloWorldPhantomReactor.tgz here ]] in your prefered destination.&lt;br /&gt;
Untar the file:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar -xvzf helloWorld.tgz&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Compiling the code &amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open Arduino IDE and load the .ino file in your environment: &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
File --&amp;gt; Open --&amp;gt; &amp;lt;HELLOWORLD_EXAMPLE&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; Select the Arbotix board: &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Tools -&amp;gt; Board -&amp;gt; ArbotiX Std&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; Compile the program: &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Program-&amp;gt; Verify/Compile&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Downloading the code to the robot &amp;lt;/h2&amp;gt;&lt;br /&gt;
Once compiled, select the correct por to download the binaries:&lt;br /&gt;
In Linux, typically:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tools -&amp;gt; Port -&amp;gt; /dev/ttyUSBX&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In Windows, typically:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tools -&amp;gt; Port -&amp;gt; COMX&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where X depends on your system and the number of peripherals on it&lt;br /&gt;
&lt;br /&gt;
Upload your code to the board:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Program -&amp;gt; Upload&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The IDE will notify that it is &amp;lt;i&amp;gt; uploading &amp;lt;/i&amp;gt; and after some seconds it will say &amp;lt;i&amp;gt; uploaded &amp;lt;/i&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Playing with HelloWorld &amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example allows you to move different joints of the robot.&lt;br /&gt;
&lt;br /&gt;
Once the code have been loaded, you can open the serial port:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Tools --&amp;gt; Serial Monitor&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;Important&amp;lt;/b&amp;gt;:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select 115200 bauds. This is the speed selected on the code for communicating with the robot.&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;No line ending&amp;quot;. To avoid sending a line end after entering commnds.&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In some seconds you should see the board communicating the following menu:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
################################&lt;br /&gt;
Serial Communication Established&lt;br /&gt;
################################&lt;br /&gt;
################################&lt;br /&gt;
Please enter option 1-6&lt;br /&gt;
0) Relax Servos&lt;br /&gt;
1) Hold Servos&lt;br /&gt;
2) Get Joints Pos&lt;br /&gt;
3) Gripper Close&lt;br /&gt;
4) Gripper Open&lt;br /&gt;
5) TestAllJoints&lt;br /&gt;
6) MoveSpecificJoint&lt;br /&gt;
################################&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These are the different options:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 0 &amp;lt;/b&amp;gt; unpowers the servomotors of the robot.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 1 &amp;lt;/b&amp;gt; powers the servomotors of the robot.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 2 &amp;lt;/b&amp;gt; prints the position of every generalized coordinate (Base, Shoulder, Elbow, Wrist and Wrist rotation).&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 3 &amp;lt;/b&amp;gt; closes the gripper.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 4 &amp;lt;/b&amp;gt; opens the gripper.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 5 &amp;lt;/b&amp;gt; provides a test movement for the complete robot.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; Option 6 &amp;lt;/b&amp;gt; allows to move specific joints. In this case, once the option is selected, the following menu will appear:&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Base: 0&lt;br /&gt;
Shoulder: 1&lt;br /&gt;
Elbow: 2&lt;br /&gt;
Wrist: 3&lt;br /&gt;
Wrist Rot: 4&lt;br /&gt;
&lt;br /&gt;
Joint to move?: &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The user must choose one of the 5 options, which correspond to different joints.&lt;br /&gt;
&lt;br /&gt;
For every joint, once selected, the program will ask for a position to move, given the limits of the joint, for example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Joint selected: 1&lt;br /&gt;
Shoulder: [-0.33, 2.97]&lt;br /&gt;
Position to move?: &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once the position is provided through the serial port it will return all the information inserted, for example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Moving Joint: 1 to position: 1.57&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and it will move to the specified position.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h1&amp;gt; Practice Template &amp;lt;/h1&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For the implementation of the Practice of the &amp;quot;Control and Robotics in Medicine&amp;quot; subject of the &amp;quot;Master on Bioengineering&amp;quot;  of the UPM, we have created a students template.&lt;br /&gt;
You can download the template from [[https://www.robolabo.etsit.upm.es/wikiFiles/ROB-P1Template.tgz here ]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Structure &amp;lt;/h2&amp;gt; &lt;br /&gt;
The template has 4 different files:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; poses.h &amp;lt;/b&amp;gt;: A file where different generalized coordinates can be stored.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; servos.h &amp;lt;/b&amp;gt;: A library to manage the servomotors independently.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; robot.h &amp;lt;/b&amp;gt;: A library to manage the different joints of the robot.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; P1-Template.h &amp;lt;/b&amp;gt;: The place where the practice should be developped.&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Libraries &amp;lt;/h2&amp;gt;&lt;br /&gt;
This Section provides important information for the resolution of Practice1.&lt;br /&gt;
It is based on the explanation of different methods to control the robot, but it does not explain the complete set of methods.&lt;br /&gt;
To get and exahustive description of all methods the &amp;lt;i&amp;gt; servos.h &amp;lt;/i&amp;gt; and &amp;lt;i&amp;gt; robot.h &amp;lt;/i&amp;gt; files must be studied.&lt;br /&gt;
&lt;br /&gt;
In principle, all interaction with the robot will be made by means of the &amp;lt;i&amp;gt; robot.h &amp;lt;/i&amp;gt; library.&lt;br /&gt;
Main methors are as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; void ROBOT_GripperOpen(void) &amp;lt;/b&amp;gt;: It opens the gripper, so it can release an object if already grasped.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; void ROBOT_GripperClose(void) &amp;lt;/b&amp;gt;: It close the gripper, so it can grasp an object if correctly located.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; void ROBOT_SetSingleTrajectory ( double *f_pos, uint16_t un_time, uint8_t un_trajectory_type ) &amp;lt;/b&amp;gt;: It performs a trajectory form one point (Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;)) to another point (Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;)).&lt;br /&gt;
Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;) and Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;) are defined as generalized coordinates Q={q&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;5&amp;lt;/sub&amp;gt;}.&lt;br /&gt;
Moreover, Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;) is defined as the coordinates at which the robot is located once the instruction is set.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt;double *f_pos &amp;lt;/b&amp;gt;: &lt;br /&gt;
Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;) is coded as &amp;lt;i&amp;gt; double * &amp;lt;/i&amp;gt;, for example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
double m_fCoordTest[]       = {0,M_PI/2,-M_PI/2,0,0};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; uint16_t un_time &amp;lt;/b&amp;gt;,  represents the time that it takes to travel from  (Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;)) to Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;),that is: t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt; - t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt; in milliseconds.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; uint8_t un_trajectory_type &amp;lt;/b&amp;gt;, represents the type of trajectory to perform: Linear (LINEAR = 0)  or Cubic  (CUBIC1 = 1)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Therefore, if we want to move the robot for the actual position to position &amp;lt;i&amp;gt; m_fCoordTest &amp;lt;/i&amp;gt; taking 2 seconds with a linear function, we need to execute:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ROBOT_SetSingleTrajectory (m_fCoordTest, 2000, LINEAR);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
I we want to move the robot to the same coordinates but in 10 secons with a cubic function, we need to execute:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ROBOT_SetSingleTrajectory (m_fCoordTest, 10000, CUBIC1);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; void ROBOT_SetDoubleTrajectory ( double *un_pos1, double *un_pos2, uint16_t un_time1, uint16_t un_time2, uint8_t un_trajectory_type ) &amp;lt;/b&amp;gt;: &lt;br /&gt;
It performs a trajectory form one point (Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;)) to another point (Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;)) passing by a point (Q(t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt;)).&lt;br /&gt;
&lt;br /&gt;
Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;), Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;) and Q(t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt;) are defined as generalized coordinates Q={q&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;,q&amp;lt;sub&amp;gt;5&amp;lt;/sub&amp;gt;}.&lt;br /&gt;
Moreover, Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;) is defined as the coordinates at which the robot is located once the instruction is set.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt;double *f_pos1 &amp;lt;/b&amp;gt;: &lt;br /&gt;
Q(t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt;) is coded as &amp;lt;i&amp;gt; double * &amp;lt;/i&amp;gt; , for example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
double m_fCoordTest[]       = {0,M_PI/2,-M_PI/2,0,0};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt;double *f_pos2 &amp;lt;/b&amp;gt;: &lt;br /&gt;
Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;) is coded as &amp;lt;i&amp;gt; double * &amp;lt;/i&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; uint16_t un_time1 &amp;lt;/b&amp;gt;,  represents the time that it takes to travel from  (Q(t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;)) to Q(t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt;),that is: t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt; - t&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt; in milliseconds.&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; uint16_t un_time2 &amp;lt;/b&amp;gt;,  represents the time that it takes to travel from  (Q(t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt;)) to Q(t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt;),that is: t&amp;lt;sub&amp;gt;f&amp;lt;/sub&amp;gt; - t&amp;lt;sub&amp;gt;v&amp;lt;/sub&amp;gt; in milliseconds.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; &amp;lt;b&amp;gt; uint8_t un_trajectory_type &amp;lt;/b&amp;gt;, represents the type of trajectory to perform. Only cubic trajectories are allowed  (CUBIC2 = 2)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Therefore, if we want to move the robot for the actual position to position &amp;lt;i&amp;gt; m_fCoordTest &amp;lt;/i&amp;gt;  taking 5 seconds passing by &amp;lt;i&amp;gt; m_fCoordVia &amp;lt;/i&amp;gt; with 2 seconds from the start, we need to execute:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ROBOT_SetDoubleTrajectory (m_fCoordVia, m_fCoordTest, 2000, 3000, CUBIC2);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt; Implementation &amp;lt;/h2&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;i&amp;gt; P1-Template.ino &amp;lt;/i&amp;gt;  follows the same structure as the helloWorld.ino example.&lt;br /&gt;
However, a new option has been included in the menu (Opcion A).&lt;br /&gt;
This option calls the &amp;lt;i&amp;gt; P1Solution &amp;lt;/i&amp;gt; method.&lt;br /&gt;
If you open &amp;lt;i&amp;gt; P1-Template.ino &amp;lt;/i&amp;gt; and go to the end of the file, you will see the following code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void P1Solution ( void )&lt;br /&gt;
{&lt;br /&gt;
  /* START CODE TO BE IMPLEMENTED BY THE STUDENTS */&lt;br /&gt;
&lt;br /&gt;
  /* END CODE TO BE IMPLEMENTED BY THE STUDENTS */&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
It is between those comments where you must implement all functions required to achive the task.&lt;br /&gt;
Remember you may need some &amp;lt;i&amp;gt; delay &amp;lt;/i&amp;gt; instructions, defined as &amp;lt;i&amp;gt; void delay (uint16_t millisec) &amp;lt;/i&amp;gt;, to prevent some instructions to execute before you need them.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt; &lt;br /&gt;
Moreover, in the &amp;lt;i&amp;gt; poses.h &amp;lt;/i&amp;gt; file you can find some examples of how to define the generalized coordinates of your system.&lt;/div&gt;</summary>
		<author><name>Aguti</name></author>	</entry>

	</feed>