User Tools

Site Tools


control_system

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
control_system [2019/12/01 07:49] – [Headline] grafcontrol_system [2023/05/11 17:13] (current) – [Motor Model] ursgraf
Line 1: Line 1:
 ====== Control System ====== ====== Control System ======
 +
 +The coordinate system is as follows
 +[{{ :delta:software:orientation.png?200 |//Orientation of the axis// }}]
 +In z direction, positive values move the TCP upwards.
 +\\
 +
 The figure below shows the complete control system for our delta roboter.  The figure below shows the complete control system for our delta roboter. 
-{{:delta:software:controlsystem.png|Control System of the Delta Roboter}}+{{:delta:software:controlsystem.png|//Control System of the Delta Roboter//}}
  
  
Line 14: Line 20:
 using AxisVector = eeros::math::Matrix<3, 1>; using AxisVector = eeros::math::Matrix<3, 1>;
 </code> </code>
 +The mouse delivers a signal with four dimensions. As we do not use the fourth dimension (additional wheel would be necessary) we have to reduce the mouse signal to three dimensions with a special block. At the same time this block swaps x and y axis in order to adapt to the axis setup of the robot. 
  
  
Line 25: Line 32:
   * The ''CirclePlanner'' moves the robot in a circle with a given radius and speed.   * The ''CirclePlanner'' moves the robot in a circle with a given radius and speed.
   * The ''Mouse Input'' gets the movement of the mouse. We use this block to manually control the Delta robot. The output of the ''Mouse Input'' is an vector with 4 entries. We must reduce it to 3 containing x, y, z.   * The ''Mouse Input'' gets the movement of the mouse. We use this block to manually control the Delta robot. The output of the ''Mouse Input'' is an vector with 4 entries. We must reduce it to 3 containing x, y, z.
 +
 +You have to make sure, that the path planner delivers a path with a acceleration and velocity which can in fact be achieved by the robot. If not, the arm might move in unpredictable ways. That is, moving from e.g. 0/5 to 5/5 must be made in a straight line. 
  
 ==== Controller ==== ==== Controller ====
  
-The "Motor Modelgets the actual speed and the calculated torque as input, and outputs the desired voltage for each motor.\\  +The position of the TCP is controlled by taking in the setpoint (see above) and adding planned velocities and accelerations. The resulting total acceleration is then fed into the block 'Inertia' which - through Newton's law - calculates the resulting force. This force is still in cartesian coordinates and has to be translated into torques applied to each of the three motors.  
-The "voltageSetPoint" serves for the initializing of the encoder. This block is no longer used after reaching Safety Level "systemReady".+ 
 +==== Motor Model==== 
 +As our board cannot only control voltages fed to each motor, we must use a motor model to calculate these voltages. The block 'Motor Modelgets the actual speed and the calculated torque as input, and outputs the desired voltage for each motor. We must also take the gear into account. The speed is reduced by the gear ratio while the torque must be multiplied with the same ratioThe following equation holds 
 +<code> 
 +U = kM * w + I * RA + dI/dt * L  
 +</code> 
 +with I = M / kM and dI/dt * L beeing very small with our motors and accounting for the gear i we get 
 +<code> 
 +U = kM * w * i + M * RA / (kM * i) 
 +</code>
 ==== Outputs ==== ==== Outputs ====
 The drive signals to the motor are of type ''PeripheralOutput''. They are described in the HAL as well. The drive signals to the motor are of type ''PeripheralOutput''. They are described in the HAL as well.
Line 35: Line 53:
 eeros::control::PeripheralInput<double> mot1("motor1"); eeros::control::PeripheralInput<double> mot1("motor1");
 </code> </code>
 +
 +The block 'voltageSetPoint serves for the initializing of the encoder when homing. It drives the motors with slow speed into a mechanical stop. This block is no longer used after reaching Safety Level ''systemReady''.
control_system.1575182951.txt.gz · Last modified: 2019/12/01 07:49 by graf