问:
On-site waste-sorting robot feasibility and availability
I am thinking about a project at my university for doing on-site waste sorting. The problem with having one waste bin for recyclables, compost and landfill and doing the sorting at a facility, is that the organic materials can destroy paper and other recyclable materials.

I have searched quite a bit but all of the robotic solutions available that I have found are for facilities. I am looking for a robotic bin to be deployed in replacement of the traditional waste and recycling bin.

The budget is approximately $1000.

$1000 -- is that materials cost only, or does it include assembly and
maintenance costs?: materials and assembly not maintenance for all 4 bins plus robotic sorter

it must be bin-sized (whatever that means): let's say 3 ft (height) x
2 ft (length) x 2 ft (width) per bin and there are 4 bins -- recycle
paper, recycle plastic, compost, landfill

Do you have weight requirements so the consumer can move the bin to
the curb, or are you planning to have the robot separate the
materials into other, mobile, bins?: There are no weight
requirements. We should be able to use a forklift to move it. What
would be nice is to have a single waste entry hole which customers
use. The device should internally sort the waste into the 4 bins
listed above. The entry hole and sorter should be 1 ft (height) x 8
ft (length) x 2 ft (width) to fit directly on top of the set of 4
adjacent bins.

What power is available?: It can be plugged into a wall outlet (in
case there is one nearby) but should also be able to use a
rechargeable battery (in case there isn't).

What about environmental concerns, especially if this is to be
located outside? Don't forget noise constraints and safety concerns.:
The whole point of this is to reduce waste and help the environment.
Assume the noise it can make can be as loud as a heater, AC unit, or
fan. The entire system should be one box with one waste entry hole --
the rest should be blackbox-ed, so it should be safe.

And, most importantly, what characteristics of the materials are you
planning to use for doing the actual sorting?: the shorter should be
able to detect pure recyclable plastic vs recyclable paper vs
organic/food material vs pure waste using either computer vision or
chemical techniques or both.

What size requirements are there for the products themselves?: The
waste whole should be .75 ft x .75 ft so assume the waste is less
than .75 ft^3

For example, how to detect organic garbage from non-organic (and do
it many times a day without human intervention to "resupply
chemicals") can be a topic of research that could take a couple of
years itself: Yes this is a good point. However, my question is more
focused on whether it's possible to use the robots already
commercially available today to solve this problem.

I read through how to ask but so here is my specific question: Is there a commercially available robot today that does or can be retro-fitted to do this on-site waste sorting?

答:
A robotics student would attach a manipulator on the bin and see what they can get done.   A good roboticist wouldn't even consider whether or not robotics was a good solution until the problem's requirements were well-defined.   You kind of have two requirements already:  the cost must be less than $300 (is that materials cost only, or does it include assembly and maintenance costs?), and it must be bin-sized (whatever that means).   Do you have weight requirements so the consumer can move the bin to the curb, or are you planning to have the robot separate the materials into other, mobile, bins?   What power is available?   What about environmental concerns, especially if this is to be located outside?   Don't forget noise constraints and safety concerns.  And, most importantly, what characteristics of the materials are you planning to use for doing the actual sorting?  What size requirements are there for the products themselves?   You need to be able to sense the characteristics, manage the span of sizes and shapes, and maneuver the materials to their destinations.   </p>

<p>In summary, start by defining the problem and the design constraints before you decide that robotics is the solution.  </p>

Body:
A robotics student would attach a manipulator on the bin and see what they can get done.   A good roboticist wouldn't even consider whether or not robotics was a good solution until the problem's requirements were well-defined.   You kind of have two requirements already:  the cost must be less than $300 (is that materials cost only, or does it include assembly and maintenance costs?), and it must be bin-sized (whatever that means).   Do you have weight requirements so the consumer can move the bin to the curb, or are you planning to have the robot separate the materials into other, mobile, bins?   What power is available?   What about environmental concerns, especially if this is to be located outside?   Don't forget noise constraints and safety concerns.  And, most importantly, what characteristics of the materials are you planning to use for doing the actual sorting?  What size requirements are there for the products themselves?   You need to be able to sense the characteristics, manage the span of sizes and shapes, and maneuver the materials to their destinations.

In summary, start by defining the problem and the design constraints before you decide that robotics is the solution.


问:
Mobile robot identification
The problem: line follower robots - non linear systems - use linear PID regulation algorithm in order to bring error to zero. However, using linear regulator is not the best way to drive non linear system.

There is something like global linearization of non linear systems - an algorithm that can bring regulation error to zero. In order to use it, one has to know kinematics of robot: Coriolis, inertion, gravity and friction matrixes. Those were once measured in EDDA manipulator and are now used in science, and that is how I learned about global linearization.

The question: I'd like to identify <s>kinematical</s> dynamical parameters of my line follower robot. I already have kinematical model, since it is simple (2,0) platform. Has anyone got information about good sources on physical parameters identification of mobile robot like this?

答:
"using linear regulator is not the best way to drive non linear
  system"

All systems are non-linear to some extend; for example, we will always encounter actuator saturation in practical systems.  And all practical controllers (e.g., PID controllers) are implemented in such a way as to handle these non-linearities, e.g., preventing integrator windup due to actuator saturation. Thus, controllers for non-linear systems are usually designed to be non-linear when the errors are large, and linear  if the errors are small.

As to your question:

"I'd like to identify kinematical parameters of my line follower
  robot. Has anyone got information about good sources on identification
  of mobile robot like this?"

Why don't you start off with an analytical model of the robot which describes the dynamics and kinematics. Kinematics (rotational and translational position due to velocity, due to acceleration,...) can be modelled perfectly.  If you know which forces and moments the actuators supply, then you only need to know masses, inertias and friction to be able to model the dynamics. These can then be measured or identified.

It is much easier to identify the parameters of a model than to identify the structure of a model... :-)

ContentLicense: CC BY-SA 3.0

Title: Mobile robot identification


问:
Is there a tool for building and analysing robots (kinematics, control) visually?
I am reading research papers about robotics and many of them follow the same pattern:

some construction is established

kinematical formulas are read from the mechanical structure

the state space is analysed (e.g. how far the robot can reach, what the maximum speed can be, what is left underspecified and how to handle such mathematically incorrect systems and so on)

Is there some tool or software product that can receive (as input) the mechanical structure and then output the kinematical formulas?  Preferably, it would provide some kind of plots, analysis, suggestions for optimal design parameters (e.g. length, angles of the sturcture, optimum parameters of motors and so on).  Does this exist?

答:
You can use SolidWorks, ADAMS, or CATIA software.
You can design your platform and analyses or make a formula for that with this software.</p>

ContentLicense: CC BY-SA 4.0


问:
EKF state propagation model using variables that are not part of state vector
I am trying to understand the EKF theory. Can the state transition function depend on variables that are not part of the state space?  For example, the state propagation below depends on the quaternions that keep changing. If I get the quaternions from a very dependable source and I dont want to filter them, can I take them out of the state space? In that case, when calculating the Jacobian I will treat the quaternions as constants even though its a dynamic value from some external sensor. What are the implications of this approach?
$$
\begin{bmatrix}
x\\
y\\
z\\
\end{bmatrix}_{k+1} = \begin{bmatrix}
x\\
y\\
z\\
\end{bmatrix}_{k} + \begin{bmatrix}
Rotation Matrix\\
using\\
Quaternions
\end{bmatrix} * \begin{bmatrix}
u \\
v \\
w \\
\end{bmatrix}_{k}
$$

The state space I am using is
$$
\begin{bmatrix}
x& y& z& u& v& w
\end{bmatrix}^T
$$
where x y z are the position coordinates and u v w are the linear velocities.

答: if the quaternion is correct, this approach will work. </p>


答:
There are a lot of unknowns to this problem, as SteveO has mentioned in an answer. My suggestion is to start inventing missing functionalities one by one and leave the assembly into a complete product for when all that is done. For example, how to detect organic garbage from non-organic (and do it many times a day without human intervention to "resupply chemicals") can be a topic of research that could take a couple of years itself.

Doing this, you can focus on solving the core of each problem (detecting a specific kind of garbage, or handling variable-sized and variable-consistency objects) without bothering with complexities of other problems. When you have each problem solved, you can start piecing things together and make a product.

Title: On-site waste-sorting robot feasibility and availability

Body:
I am thinking about a project at my university for doing on-site waste sorting. The problem with having one waste bin for recyclables, compost and landfill and doing the sorting at a facility, is that the organic materials can destroy paper and other recyclable materials.

I have searched quite a bit but all of the robotic solutions available that I have found are for facilities. I am looking for a robotic bin to be deployed in replacement of the traditional waste and recycling bin.

The budget is approximately $1000.

$1000 -- is that materials cost only, or does it include assembly and
maintenance costs?: materials and assembly not maintenance for all 4 bins plus robotic sorter

it must be bin-sized (whatever that means): let's say 3 ft (height) x
2 ft (length) x 2 ft (width) per bin and there are 4 bins -- recycle
paper, recycle plastic, compost, landfill

Do you have weight requirements so the consumer can move the bin to
the curb, or are you planning to have the robot separate the
materials into other, mobile, bins?: There are no weight
requirements. We should be able to use a forklift to move it. What
would be nice is to have a single waste entry hole which customers
use. The device should internally sort the waste into the 4 bins
listed above. The entry hole and sorter should be 1 ft (height) x 8
ft (length) x 2 ft (width) to fit directly on top of the set of 4
adjacent bins.

What power is available?: It can be plugged into a wall outlet (in
case there is one nearby) but should also be able to use a
rechargeable battery (in case there isn't).

What about environmental concerns, especially if this is to be
located outside? Don't forget noise constraints and safety concerns.:
The whole point of this is to reduce waste and help the environment.
Assume the noise it can make can be as loud as a heater, AC unit, or
fan. The entire system should be one box with one waste entry hole --
the rest should be blackbox-ed, so it should be safe.

And, most importantly, what characteristics of the materials are you
planning to use for doing the actual sorting?: the shorter should be
able to detect pure recyclable plastic vs recyclable paper vs
organic/food material vs pure waste using either computer vision or
chemical techniques or both.

What size requirements are there for the products themselves?: The
waste whole should be .75 ft x .75 ft so assume the waste is less
than .75 ft^3

For example, how to detect organic garbage from non-organic (and do
it many times a day without human intervention to "resupply
chemicals") can be a topic of research that could take a couple of
years itself: Yes this is a good point. However, my question is more
focused on whether it's possible to use the robots already
commercially available today to solve this problem.

I read through how to ask but so here is my specific question: Is there a commercially available robot today that does or can be retro-fitted to do this on-site waste sorting?


问:
Is RobotBASIC outdated?
I found this website http://robotbasic.org/ and it talks about a language used for programming things related to robotics, and I want to make sure whether or not it's worth investing any time or energy into compared to other languages before I just wipe it from my browser bookmarks for good. Nowadays, are there better languages and methods for going about the same things that it talks about?

I mean, the site looks pretty old, like something from the late 90s or pre-2010, plus I never heard of it anywhere except for this site, so I wonder if it's just not relevant any more if it ever was.

答:
RobotBASIC (or RROS) is the best thing since sliced bread for the Robotics Hobbyist. And it’s free which pretty much puts it into everybody’s budget. It’s based on BASIC which is a super easy way to learn a programming language (my daughter was writing simple code in 15 minutes). All the low level tedium has been done for you. You add a compass and you have a direction available to you without deciphering a bunch of meaningless bits / protocols from a fluxgate compass. Add ultrasonic sensors (many if you want) and you have distance data and collision avoidance. The list goes on and on. Add a laptop and you have speech recognition and synthesis. RROS takes care of all the low level mundane interfacing so you can quickly assembly a smart bot with a higher level language ( kind of like BIOS does in a PC ) .

Lots of articles have been written in Servo magazine about Navigation, Sensors and a host of other issues by the creator John Blankenship, a Professor back East. On Amazon if you put in his name he has written a dozen robot books and the latest is about ARLO built upon some Parallax structures that walks you through just about every bot issue you could encounter . I could write tons more but it will start to sound like an info-mercial. Please check it out for yourself and you will be pleasantly surprised!

One last thing I have to mention. You get a simulator with the software that allows you to test your real code before you have any hardware. When your software is working as you like it ports directly over to your real bot. How cool is that?

Title: Is RobotBASIC outdated?


问:
"Updated" Help in iRobot create serial communication in Arduino
I am programming an iRobot Create to follow serial commands using Arduino Uno. I have written the library, and found the serial commands to move the robot forward in the iRobot manual, but I couldn't find the bytes for other movements (backward, right and left).
Could you please help me with this. How can I move the robot backward, right and left. I will upload my code library.

```<code>#include "iRobot.h"

#if defined(ARDUINO) && ARDUINO >= 100  //to check if the arduino is plugged and the its number is above 100

#include "Arduino.h"

#include "SoftwareSerial.h"  // so we can use all pins
SoftwareSerial softSerial = SoftwareSerial(10, 11);

#endif

iRobot::iRobot() //constructor to set the pins
{
_rxPin = 10;
_txPin = 11;
}

void iRobot::begin()  //needs to be called inside setup function
{

delay(2000); // Needed to initialize the iRobot, the delay is to ensure that each command before this is excucted or there will be overlap

// define pin modes for software tx, rx pins for iRobot
pinMode(_rxPin, INPUT);
pinMode(_txPin, OUTPUT);

softSerial.begin(19200); //we set the data rate received by the irobot

Serial.begin(19200); // set the data rate sent from the arduino

//these two line are necessary from the irobot manual
softSerial.write(128); // This command starts the communication.
softSerial.write(131); // set mode to safe, it will stop of there is a cliff or a wheel drops or

Serial.write("Enter Command: "); // here, if we start serial monitor, we can enter the command
}

void iRobot::runIt()   //needs to be called inside loop function
{
if (Serial.available())
{
String data = String(Serial.read()); //this will read the command, each word will call a function

if(data == "forward")
  goForward();
if(data == "backward")
  goBackward();
if(data == "left")
  goLeft();
if(data == "right")
  goRight();
}
}

void iRobot::goForward()
{
softSerial.write(137); // Opcode number for DRIVE, it's understood by the irobot that 137 means drive

// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);

//Radius (-2000 - 2000 mm)
softSerial.write((byte)128); // we should adjust this to make the robot go straight or slightly right or left
softSerial.write((byte)0); // we should adjust this to make the robot go straight or slightly right or left
}

void iRobot::goBackward()
{
softSerial.write(137);
//we should change the bytes to make the robot drive backward
//negative vaule of velocity drive the robot forward
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);

//Radius (-2000 - 2000 mm)
softSerial.write((byte)128); // we should adjust this to make the robot go straight or slightly right or left
softSerial.write((byte)0); // we should adjust this to make the robot go straight or slightly right or left

}

void iRobot::goLeft()
{
softSerial.write(137);
 //we should change the bytes to make the robot drive left
 //radius value should be positive
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);

//Radius (-2000 - 2000 mm)
softSerial.write((byte)128); // we should adjust this to make the robot go straight or slightly right or left
softSerial.write((byte)0); // we should adjust this to make the robot go straight or slightly right or left
 }

 void iRobot::goRight()
 {
softSerial.write(137);
 //we should change the bytes to make the robot drive right
 //radius value should be negative
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);

//Radius (-2000 - 2000 mm)
softSerial.write((byte)128); // we should adjust this to make the robot go straight or slightly right or left
softSerial.write((byte)0); // we should adjust this to make the robot go straight or slightly right or left
}
</code>```

Update:
I have connected the robot to the Arduino and tried the code. Unfortunately, the robot didn't move
This is my Arduino code:

```<code> #include <Arduino.h>
 #include <iRobot.h>
 iRobot irobot;

 void setup() {
  irobot.begin();
 }

 void loop() {
  irobot.runIt();
 }
</code>```

I have connected the the pins 10, 11 and GND on the Arduino to pins 3, 4 and 7 on the robot.

答:
Page 9 of the Open Interface specification gives the following instructions:

Serial sequence: [137][Velocity high byte][Velocity low byte][Radius high byte][Radius low byte]

It then gives special cases for the radius:

Special cases:

Straight = 32768 or 32767 = hex 8000 or 7FFF

Turn in place clockwise = hex FFFF

Turn in place counter-clockwise = hex 0001

Each portion, speed and radius, are two 16-bit signed values. Your robot does the same thing for forward/backward/left/right because you have copy/pasted the same code in each section. You don't have anything different in any of the code segments.

Here is a converter that will do the decimal to hex conversion for you - be sure to select 'signed 16-bit' from the dropdown box. Once you have the four digit hex number, the 'high' byte is the first two digits and the 'low' byte is the last two digits. Plug each pair into this converter to get the decimal value you should write.

So, for example, let's say you want to use a speed of 200 mm/s for all cases. Your code should look like the following:

```<code>void iRobot::goForward()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)128);
softSerial.write((byte)0);
}
void iRobot::goBackward()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)255);
softSerial.write((byte)56);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)128);
softSerial.write((byte)0);
}
void iRobot::goLeft()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)0);
softSerial.write((byte)1);
}
void iRobot::goRight()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)255);
softSerial.write((byte)255);
}
</code>```

I'll mention here that the Create won't "strafe" or move left/right while facing forwards. It only moves forwards. It can turn while moving forward, such that it follows an arc, but that's the only "goLeft" or "goRight" you get. As I've written it above, goLeft and goRight are both zero-radius turns.

Body:
Page 9 of the Open Interface specification gives the following instructions:

Serial sequence: [137][Velocity high byte][Velocity low byte][Radius high byte][Radius low byte]

It then gives special cases for the radius:

Special cases:

Straight = 32768 or 32767 = hex 8000 or 7FFF

Turn in place clockwise = hex FFFF

Turn in place counter-clockwise = hex 0001

Each portion, speed and radius, are two 16-bit signed values. Your robot does the same thing for forward/backward/left/right because you have copy/pasted the same code in each section. You don't have anything different in any of the code segments.

Here is a converter that will do the decimal to hex conversion for you - be sure to select 'signed 16-bit' from the dropdown box. Once you have the four digit hex number, the 'high' byte is the first two digits and the 'low' byte is the last two digits. Plug each pair into this converter to get the decimal value you should write.

So, for example, let's say you want to use a speed of 200 mm/s for all cases. Your code should look like the following:

void iRobot::goForward()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)128);
softSerial.write((byte)0);
}
void iRobot::goBackward()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)255);
softSerial.write((byte)56);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)128);
softSerial.write((byte)0);
}
void iRobot::goLeft()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)0);
softSerial.write((byte)1);
}
void iRobot::goRight()
{
// Drive op code
softSerial.write(137);
// Velocity (-500 – 500 mm/s)
softSerial.write((byte)0);
softSerial.write((byte)200);
//Radius (-2000 - 2000 mm)
softSerial.write((byte)255);
softSerial.write((byte)255);
}

I'll mention here that the Create won't "strafe" or move left/right while facing forwards. It only moves forwards. It can turn while moving forward, such that it follows an arc, but that's the only "goLeft" or "goRight" you get. As I've written it above, goLeft and goRight are both zero-radius turns.


问:
Confusion between wrist, tool and end effector
I have a confusion between the wrist frame, the tool frame and the end effector as used in the unmodified DH conventions. Can you differentiate with diagrams?</p>

答:
Tool frame is the same as the end-effector.
The wrist frame is located at the point where the last 3 axes of the robot, if extended as imaginary lines, intersect (in case of a robots equipped with a wrist). It is oriented the same way as the DH frame of previous axis. A wrist is essentially a subcomponent of the structure (the last 3 axes) used for setting the orientation of the tool.

Sometimes flange frame is also used. That is the physical end of the robot when no tool and tool holder is attached to it. It is usually a ISO flange for mounting tools and tool holders.

UPDATE: coordinate system 4 is the wrist coordinate system and 6 is the tool and end effector frame.


问:
Can I use digital animation software to define the movements of humanoid robots?
I'm working with a lifesize (~130cm) humanoid robot (Hubo+) and looking for a way to easily program new motions and gestures into him. Obviously, I could write my own tool, but I am looking for a solution that can leverage existing tools or standards for robot motion. My first thought was trying to use animation software like Blender or Maya, and writing a script to extract the joint angles at keyframes. However, few robotics researchers are probably proficient with Maya. (I know I'm not!)

Is there already some kind of 3D posing tool for robotics that is a standard? The only things I have seen so far that comes close is the Pose Utility in RoboPlus and Choregraphe for the Nao, but both programs seem limited to particular robots and don't appear to be extendable to Hubo.

So my questions are:

Are there standard file formats for robot motion? Not 2D wheeled robot motion. Arm and leg motion! Something equivalent to the .bvh file format used in motion capture.

Do you know of any WYSIWYGish tool for creating robot motion using keyframes and inverse kinematics?

答: If you want to Design your robot you can use SolidWork, CATIA or ADAMS software then you can animate your robot. But you can use Aldebaran standard platform robot (NAO) simulator. This simulator can be helpful for you but NAO robot is a kid size robot with good sensors.</p>


问:
CNC: Linear motion without timing belt or lead screw
Is it possible to build a CNC whose Linear motion system does not contain any timing belt(pulley) or lead screw(threaded rod).
I was wondering whether I could directly control the Linear motion by securing wheels of a slider onto aluminum rails & directly connecting the wheels to a stepper motor.

The main objective of this question is to find the cheapest method for controlled Linear motion.

答:
CNC controllers, in most cases, control rotary motion and the model of how this rotary motion is tranformed, by the mechanism attached to the motor, to a translational motion is implemented in the controller.

You can use any method of transforming rotary motion to a linear motion as long as the model for it is pre-implemented in the CNC controller or you can implement it to the CNC. Moreover, it does not even has to be a decoupled translational motion. E.g. LinuxCNC can controll multiple axes to achive 1 decoupled linear motion. On a parellel mechanism, moving all axes results in a Z translation. Video of this here.

The only limit to what mechanism can you put on the end of the motor of a CNC is what are you able to model and integrate to the CNC controller. If you do not have the possibility to implement a model, then the question becomes what pre-implemented models are there and how can you adjust their parameters to make them refelct your mechanism.

Needles to say the accuracy of the model will affect the accuracy of the CNC.


答:
If you want to build something that more or less resembles CNC machine, and use a pen as a tool and draw some pictures, then you will probably be fine (as long as you can do programming and have a lot of patience to do calibration).

Why is this not a common solution?

Usually you want CNC to be precise and to have enough power to move a tool at reasonable speed. Cheap rubber wheels are... well cheap. Nobody cares if their diameter is 10mm or maybe 10.3. Or 9.7. What's more you can buy several wheels and each one of them will have different diameter. This will lead to problems when calibrating the machine.

Additionally, threaded rods and belts can transfer more torque without slipping, so higher dynamics will be achievable.

Title: CNC: Linear motion without timing belt or lead screw

Body:
Is it possible to build a CNC whose Linear motion system does not contain any timing belt(pulley) or lead screw(threaded rod).
I was wondering whether I could directly control the Linear motion by securing wheels of a slider onto aluminum rails & directly connecting the wheels to a stepper motor.

The main objective of this question is to find the cheapest method for controlled Linear motion.


问:
Definition of payload for industrial robots
I'm currently looking for an industrial robot for a depalletizing application. I had a look at some datasheets but I'm not quite sure how the maximum payload is defined. e.g. the Kuka Agilus weighs 52kg and looks rather strong, but is listed with only 6kg. Is this really the highest weight that the robot can lift or is this the heaviest object that the robot can move with its maximal velocity and I can move heavier stuff at lower speeds?</p>

答:
If you only consider the simple physics of the problem you are completely right, it should be able to move lower payloads at lower velocities and accelerations.

However, the maximum payload can only be used as a rule of thumb to dimension a robot. In order to do a proper dimensioning you need the center of gravity, the mass and the inertia of the payload. Kuka has a free tool to verify the dimensioning properly called KukaLoad. I would recommend giving that a try to see if you hit an overload condition with your load and motion specifications.

Since you did not give any information on the application, besides that is depalitizin, if we are talking about the europallet sizes pallets, the Agilus line is definetly too small for that task.


问:
What are human-friendly terms for mobile-robot orientation and relative direction of non-robot objects?
Within robotics programming, orientation is primarily given in terms of x, y, & z coordinates, from some central location.  However x, y, z coordinates aren't convenient for rapid human understanding if there are many locations from which to select (e.g., {23, 34, 45}, {34, 23, 45}, {34, 32, 45}, {23, 43, 45} is not particularly human friendly, and is highly prone to human error).  Yet more common English orientation descriptors are frequently either too wordy or too imprecise for rapid selection (e.g.,  "front-facing camera on robot 1's right front shoulder" is too wordy; but "front"/ "forward" is too imprecise - is the camera on the leading edge or is it pointing forward?)

In the naval and aeronautical fields vehicle locations are generically talked about as fore, aft (or stern), port, and starboard. While, direction of movement that is relative to the vehicle is frequently given in reference to a clockface (e.g., forward of the the fore would be "at 12", rear of the aft would be "at 6", while right of starboard and left of port would be "at 3" and "at 9", respectively).  This language supports rapid human communication that is more precise than terms such as "front" and "forward".  Are there equivalent terms within mobile robotics?

答:
I think you could use bearing (or azimuth or right ascension) and mark (or altitude or declination). For example 0 mark 0 is straight ahead and on the horizon. 30 mark 30 is 30 degrees to the right and 30 degrees above the horizon. -90 mark -90 would be 90 degrees to the left and then face down into the ground.  These could be relative to your current position and orientation or relative to some reference such as true north or magnetic north and the horizon.

This is the system astronomer's use.


问:
Dealing with fixed transformations while solving inverse kinematics
I am trying to solve inverse kinematics (using the Jacobian pseudoinverse method) for a 7 DoF arm, but because of the way the robot is mounted, the base frame does not coincide with the frame of the first joint, so there is a transformation between base and frame 0. As the Jacobian expresses the joint-end effector velocity relationship w.r.t. the base frame, and also because my target poses etc. are expressed w.r.t the base frame, I encoded the transformation as an extra row in my DH parameters, but these angles are always fixed. Hence, I ended up with 8 rows in my DH although I have only 7 joints.

Because of this, my inverse kinematics algorithm, when trying to minimize the end effector pose error, continuously attempts to change the angle of the "first" joint which really isn't a joint at all. Hence, although the algorithm thinks the end effector has reached the target position, in real world it would not, because that base-robot transformation would be invalid for my setup. If I force this angle to be constant after every update of the iteration, the algorithm fails to converge and gets stuck at some pose. So I am guessing my approach for encoding the fixed base-first joint transformation is wrong? How are these transformations usually dealt with?

答:
Hopefully you still have only 4 rows in your DH matrix, not 8 as you said.  I think you mean that your Jacobian matrix has 8 $\require{enclose} \enclose{horizontalstrike}{\text{rows}}$ columns.

Your approach is close to correct, but it has one flaw.   The flaw is when you make the transformation that you are calling the "first joint."  Instead of letting the rotation between that coordinate system and the next be a variable, say, $q_1$, just plug in the value of that angle (for example, $\pi \over 2$).

If you do this, then you'll see that your Jacobian has only 7 $\enclose{horizontalstrike}{\text{rows}}$ columns, as it should.   The iterative pseudoinverse process will have a higher likelihood of converging to a proper solution since it will not be trying to move a nonexistant degree of freedom.   And you won't need to reset that angle after each iteration, because it is constant.


答:
Having 8 rows in the DH parameters table is completely ok. However, this does not lead to 8 rows in your jacobi matrix. The size of the jacobi matrix is always given by number of degrees of freedom in Cartesian space and number of degrees of freedom in joint space. In your case 6 and 7, as I understand.

Elements in the Jacobi matrix express to what extent does a small change in a joint variable cause a change in the cartesian variables. Based on this, it should be clear that your fixed transformation from base to joint 1 cannot have any changes in it therefore cannot have its own variable and row in the jacobian matrix.

This situation is very common. It is essentially the same as having a last transformation from the flange coordinate system to the tool coordinate system.

So, to build up the jacobian, I always do it as follows:

Write the DH parameter table

Multiply all matrices together (all 8 in your case)

Write the equation

$A_{lhs} = A_{rhs}$

where $A_{lhs}$ is the transformation matrix from the joint space side (DH transformations multiplied together) and $A_{rhs}$ is the Cartesian transformation matrix multiplied togehter ($T_x(x) * T_y(y)*...$).

From this matrix equation express the equations:

$x = f_x(q_1, q_2, q_3, q_4, q_5, q_6, q_7)$

$y = f_y(q_1, q_2, q_3, q_4, q_5, q_6, q_7)$

$z = f_z(q_1, q_2, q_3, q_4, q_5, q_6, q_7)$

$a = f_a(q_1, q_2, q_3, q_4, q_5, q_6, q_7)$

$b = f_b(q_1, q_2, q_3, q_4, q_5, q_6, q_7)$

$c = f_c(q_1, q_2, q_3, q_4, q_5, q_6, q_7)$

This is the direct kinematics problem in explicit from.

Derive all elements of the Jacobi Matrix (with a computer algebraic system, e.g. Maple, Matlab Symbolics toolbox, Math.net, symPy, etc.)

$\frac{\delta x}{\delta q_1}$ = $\frac{\delta f_x}{\delta q_1}$

Build up all 6x7 elements of the jacobi matrix this way

Title: Dealing with fixed transformations while solving inverse kinematics

Body:
I am trying to solve inverse kinematics (using the Jacobian pseudoinverse method) for a 7 DoF arm, but because of the way the robot is mounted, the base frame does not coincide with the frame of the first joint, so there is a transformation between base and frame 0. As the Jacobian expresses the joint-end effector velocity relationship w.r.t. the base frame, and also because my target poses etc. are expressed w.r.t the base frame, I encoded the transformation as an extra row in my DH parameters, but these angles are always fixed. Hence, I ended up with 8 rows in my DH although I have only 7 joints.

Because of this, my inverse kinematics algorithm, when trying to minimize the end effector pose error, continuously attempts to change the angle of the "first" joint which really isn't a joint at all. Hence, although the algorithm thinks the end effector has reached the target position, in real world it would not, because that base-robot transformation would be invalid for my setup. If I force this angle to be constant after every update of the iteration, the algorithm fails to converge and gets stuck at some pose. So I am guessing my approach for encoding the fixed base-first joint transformation is wrong? How are these transformations usually dealt with?


答: What you are looking for is called a linear potentiometer. It is the same tech that is in your car known as a fuel sending unit, volume control knobs, etc. It is most basically a voltage divider whose resistance is increased or decreased and can be measured. Aditional details can be found on the wiki at en.wikipedia.org/wiki/Potentiometer</p>


问:
Driving sensorless three phase BLDC motor with Arduino and IMU
I have started to work on a little project of mines, which consists in implementing the stabilization a single axis gimbal using Arduino.

The gimbal is driven by a sensorless three phase brushless DC (BLDC) motor, while on it's shaft there is a generic payload provided with an IMU board (3 axes gyros + 3 axes accelometers), which can give feedback to the Arduino about the angular rates and accelerations.

I have googled a bit about this topic and there are so many solutions out there, the only thing I really do not understand is about the control of the BLDC motor.

Can I use a sensorless control of the motor, by sensing the back EMF
even if the motor is spinning very low?

How can I energize properly the phases of the BLDC motor if it is sensorless?

Can I use the IMU for finding out how to spin the BLDC motor properly without counter rotations?

Could you give me any help, please?

答: Are you opposed to adding components to the power circuit? If you add in a portion that measures current being drawn by the motor, you can get some decent feedback about what the motor is doing and how much of a mechanical load is being applied to it. </p>


答: Sort of. This is in the possible but not probable category of things. All you need is a system with very little play and active position feedback and you can get around the usual requirement of stepper motors and lead screws. What is wrong with belts though? They are really not that expensive for what they do and how well they do it compared to alternatives. At time of writing AndyMark carries timing belts for $14. Given, however, that you want the amazingly large size of 100m×50m (!) might I suggest steel cable and a roller system on 80/20. Make a free rolling system and then use steel cables to move the positions on each of the axes. Such a large system will have both hysteresis and nonlinearity so you're going to want active position feedback and PID control scheme to make sure the machine head actually ends up where it needs to be for each line of the gcode. Can you not partition that space down to smaller quadrants though? 100mx50m is enormously demanding and de facto firmly out of the budget CNC category of projects.


问:
Pick and place using only vision information and forward kinematics
Is it possible to do pick and place tasks using only forward kinematics and object detection information from a camera?

I want to avoid having to do inverse kinematic calculations for my robot. Is there a way I can avoid them for pick and place object sorting?

答: If you can get the objects to be located consistently at the same positions, you may be able to use "teach and repeat" programming.   Otherwise you need some method to translate the objects' positions into joint angles.   Inverse kinematics is the most straightforward method.   There are some optimization / search algorithms that you could try, too, but they are even more challenging than just computing the closed-form inverse kinematics.   </p>


问:
Prototyping a device with 25-100 small DC 3.0V motors, is Arduino a good fit?
I want to prototype a therapeutic device that will have a lot of tiny mobile-phone type vibration motors like this one in it, and I want to be able to activate them in any configuration I want.  I'm going to need analogue control, and support for logic like perlin noise functions and so on.  I'm not really going to need sensor data or any other kind of feedback beyond a few buttons for control.  I just need fine control over lots of little motors.  Depending on what results I can get out of, say, 25 motors on the initial prototype, I may decide that I'm done, or that it needs more motors.  I also don't have an enormous budget.

So the question is, is Arduino a good fit for a project like this?  Is it feasible to get that many motors working off the same controller?  I know some of the Arduino boards have up to 50-something serial outputs, but from what I can tell, that may only translate to 25 or so motors, so I'd need a way to extend the board with more serial outputs if I wanted to try more.

Additionally, if Arduino isn't a good fit, what would be better?  Could I try something directly out of a serial port on my PC?  I've never tried to home-cook a robotics application before, so I'm not really aware of the options.

答:
"I'm going to need analogue control"

This is almost always done by rapidly connecting and disconnecting the motor to power, using PWM or something similar.
The switching is faster than the motor can respond, and often the designer picks a switching frequency faster than the 20 kHz humans can hear.

generating PWM signals

There are 3 popular methods of generating PWM signals: ( a, b )

Generate the PWM in software ("Bit-banging Pulse Width Modulation"). Typically this is the lowest-cost approach. With enough 74HC595 or TPIC6595 chips, one Arduino can control any number of motors. (But I doubt you'll be able to get 20 kHz PWM frequency this way).

Generate the PWM using on-chip PWM hardware on the microcontroller. With enough Arduinos, you can control any number of motors at a high PWM frequency with 3 or 4 motors per Arduino.

Generate the PWM using dedicated PWM peripheral chips such as the TLC5947, which the microcontroller occasionally loads with a new PWM duty cycle. With enough TLC5947 chips, one Arduino can control any number of motors and still maintain a high PWM frequency.

Converting PWM signals into something that can drive a motor

It appears your motors are rated at 85 mA start, 75 mA continuous.
That is really tiny for a motor.
But it's still more power than most digital logic chips can drive directly.
As you can see from this list, only one of the chips mentioned above (the TPIC6595) is really designed to directly drive that amount of power:

TPIC6595 datasheet: test conditions ... 250 mA continuous sink current capability.

TLC5947 datasheet: test conditions ... 30 mA continuous sink current

ATmega328P datasheet: "test conditions ... 20 mA at VCC = 5V, 10 mA at VCC = 3V... Pins are not guaranteed to source current greater than the listed test condition."

74HC595 datasheet: test conditions ... 7.8 mA.

We typically use some kind of "buffer" between the digital logic chips (any of the above chips) and a motor.

For motors that we only need to turn in one direction, we typically we use flyback diode and either a nFET or a npn transistor as the "buffer":

ULN2803A or ULQ2803A (transistor + flyback diode array) datasheet: test conditions ... over 150 mA continuous.

There are thousands of discrete transistors and diodes that can easily handle: 10 V, 1 A. ( a )

For motors that we need to turn both "forwards" and "reverse", we typically use 4 transistors arranged in a H bridge as the "buffer":

L293D H bridge datasheet: test conditions ... 600 mA.

There are thousands of discrete transistors and diodes that can easily handle: 10 V, 1 A.


问:
Sensor for tracking relative position of human
I am making a robot that needs to continuously track the relative position of a human, up to 15 meters away and with at least 300 degrees coverage. Currently I am using a Hitechnic IRSeeker v2 sensor and made a beacon wristband with 6 TV remote IR LEDs. But the maximum distance I can get is around 3 meters.

I ordered some 3 watts IR LEDs to boost the power, but the size of the wristband will be a problem because it will not run on a CR2032 battery.

I also bought some IR remote receivers. But I am not sure if the reflection from the wall will give false results.

Is what I am trying to do possible? Is a beacon 15m away feasible using this technology?

If it is, then what do I need to modify in my current implementation?

If not, are there any other technologies that I should be considering to track the relative position or direction of human, 15 meters away with at least 300 degrees coverage?

答:
A rather inexpensive solution to your problem is to use a vision based IR solution- Infragram. There is some good work done to post-process gathered IR images and you could post process you "human" images and tune them for your application. It is cheap and light which is why I used it for my open-source projects.

Also, addressing Prasad's concern, this works in both indoors and outdoors environments. Alternatively, if you really want to be adventurous, take out the infrared filter of any camera that you have and convert it into a low-cost IR camera that can detect human heat signatures (Beware: this might render your camera useless and is generally difficult to do. I've tried it, but damaged the filter beyond repair)


答:
Interesting question.  Some degree of precision is required.  There are two ways to do this:

a) use an encoder associated with a wheel which reports the rotary position. That value is then related to the wheel circumference to obtain the distance travelled. Perhaps a wifi transmitter on each carriage would be more practical than wiring.

b) use an absolute positioning measurement system.  Your dimensions of 100m x 50m are very large and clearly any traditional belt drive/screw drive is impractical. As an example of absolute positioning, a laser rangefinder (+/- 1-2mm) at each corner would locate the gantry.  How a commercial product would be interfaced with the PID/control system is a homework exercise.


问:
Line follower for coloured lines
I am building a line-following robot with a Raspberry Pi Zero, using the explorer PHat.
The robot is supposed to follow black, red, green and blue lines and react to the colour, so it should drive faster on a red line and slower on a blue line.

I do not have much experience with line followers, so I am not sure what kind of hardware I need.
My questions are:

Is it possible to follow a red, blue or green line with IR LEDs? Most of the line followers obviously use IR LEDs (like TCRT5000), but they are supposed to only follow black lines.

I have a RGB sensor which works quite well with the explorer PHat and I am able to recognize colours very accurately. Is it possible to use this single sensor as a line follower? As the robot should be able to drive on a curvy course a single sensor is probably not enough?

答:
IR sensors are about reflection. With TCRT5000, distinguishing black from white is based on the absorption of the black surface, it almost absorbs all of the IR waves. While white reflects almost all of it.

Now with different colours, it is all about how much difference is between their absorbtion or reflection capabilities. (I think, you won't be able to make difference between blue and black, unless if it is a really light blue.)

What you should do is make some tests. Hook-up a single TCRT5000 and measure with red, green, blue and other surfaces. Do a lot of measurements and analyze the results, so you can decide if those colours are entirely distinguishable.

Now the RGB sensor. You should add a datasheet if you want anyone to tell you if it can really work.

Is it possible to use this single sensor as a line follower? As the robot should be able to drive on a curvy course a single sensor is probably not enough?

Depends on how large is the area that a single sensor can cover. Is it a single pixel sensor or it can detect N x N pixel's colour? It is not impossible to use it.

Title: Line follower for coloured lines


问:
How to create Matlab Simulation for Kinematics of Differential Drive
I studied the forward and inverse Kinematics of the robot and got a clear understanding. I am in the progress of developing my matlab simulation for a two wheeled differential drive robot. The robot moves in a straight line and has been integrated with PID. I want to show by the animation the movement of the robot.

Equation is,

```<code>The Vector in Initial Frame = Rotation Matrix Inverse x Vector in Robot Frame

My Rotational Matrix is, [0 -1 0; 1 0 0; 0 0 1] since the angle is 90.

The Robot Frame is [a; b; c]
where a = Total translational Speed = (r x w1)/2 + (r x w2)/2
      b = In y direction = 0
      c = Total Rotational Speed = (r x w1)/2l + (r x w2)/2l

where l = 0.12 and r = 0.033 and w1 and w2 are angular velocities of wheel 1 and 2.
</code>```

I have w1 and w2 data in a file as

```<code>w1 1 2 3 4 5 6 8 9
w2 1 3 4 5 6 7 8 9
</code>```

I want to run an algorithm in such a way, Mat lab runs the equation and calculate the values of Total translational Speed and Total angular speed in the world frame and plot the graph. I also want to make an animation in such a way a box moves according to this equation. How can I do that? I can run it for one time if I input one value for w1 and w2, But not continuously. Help. Thanks Much.

答:
Making a plot in Matlab can be done using the plot(data) command where data is a vector containing the series of points to plot. Further refinements to the plot can include the correct timeseries for example plot(data, time) where time is a vector with the same length as data as contains the timestesp at which data has been sampled.

Repetitive tasks in programming are solved be [loops][2]. Common ones are for-loops or while-loops. For loops (in Matlab) are useful when you know how many times do you want to execute something. While loops are useful when you want to satisfy a condition for stopping (e.g. robot reached its target).

In each loop cycle you have to know what the simulation time of your algorithm is. E.g. you can choose to increment the time variable with 0.1 seconds in each cycle. this will be one timestep. You have to store the value of the positions of the robot (e.g. in a vector) in each timestep (please note that you only posted the velocity calculations, which for the constant input of w1 and w2 will be always constant, so expect a straight line as a velocity plot).

A simple example would be:

```<code>x_init = 0; %[m]
y_init = 0; %[m]

x_target = 5; %[m]
y_target = 5; %[m]

x_vel = 1; %[m/s]
y_vel = 1; %[m/s]

target_reached = 0;
timestep = 0.1; %[s]

sample_no = 1;
x_robot(sample_no) = x_init;
y_robot(sample_no) = y_init;
timestamps(sample_no) = 0;
tol = 0.1; %[m]

while ~target_reached
    %increase timestep
    sample_no =  sample_no + 1;

    %calculate new position
    x_robot(sample_no) = x_robot(sample_no - 1) + x_vel * timestep;
    y_robot(sample_no) = y_robot(sample_no - 1) + y_vel * timestep;
    %store timestep
    timestamps(sample_no) = timestamps(sample_no - 1) + timestep;

    %check if target is reached
    if ((abs(x_robot(sample_no) - x_target) < tol) || (abs(y_robot(sample_no) - y_target) < tol))
        target_reached = 1;
    end

    %insert animation here
    %...
end

figure
plot(x_robot, timestamps);
figure
plot(y_robot, timestamps);
</code>```

Please note that this is a simple example to show how to generate a position plot and requires a number of improvements for making generally applicable.

For the animation, at each timestep the a figure should be updated with the current position values of the robot. A tutorial on making animations in Matlab can be found here.

Body:
Making a plot in Matlab can be done using the plot(data) command where data is a vector containing the series of points to plot. Further refinements to the plot can include the correct timeseries for example plot(data, time) where time is a vector with the same length as data as contains the timestesp at which data has been sampled.

Repetitive tasks in programming are solved be [loops][2]. Common ones are for-loops or while-loops. For loops (in Matlab) are useful when you know how many times do you want to execute something. While loops are useful when you want to satisfy a condition for stopping (e.g. robot reached its target).

In each loop cycle you have to know what the simulation time of your algorithm is. E.g. you can choose to increment the time variable with 0.1 seconds in each cycle. this will be one timestep. You have to store the value of the positions of the robot (e.g. in a vector) in each timestep (please note that you only posted the velocity calculations, which for the constant input of w1 and w2 will be always constant, so expect a straight line as a velocity plot).

A simple example would be:

x_init = 0; %[m]
y_init = 0; %[m]

x_target = 5; %[m]
y_target = 5; %[m]

x_vel = 1; %[m/s]
y_vel = 1; %[m/s]

target_reached = 0;
timestep = 0.1; %[s]

sample_no = 1;
x_robot(sample_no) = x_init;
y_robot(sample_no) = y_init;
timestamps(sample_no) = 0;
tol = 0.1; %[m]

while ~target_reached
    %increase timestep
    sample_no =  sample_no + 1;

    %calculate new position
    x_robot(sample_no) = x_robot(sample_no - 1) + x_vel * timestep;
    y_robot(sample_no) = y_robot(sample_no - 1) + y_vel * timestep;
    %store timestep
    timestamps(sample_no) = timestamps(sample_no - 1) + timestep;

    %check if target is reached
    if ((abs(x_robot(sample_no) - x_target) < tol) || (abs(y_robot(sample_no) - y_target) < tol))
        target_reached = 1;
    end

    %insert animation here
    %...
end

figure
plot(x_robot, timestamps);
figure
plot(y_robot, timestamps);

Please note that this is a simple example to show how to generate a position plot and requires a number of improvements for making generally applicable.

For the animation, at each timestep the a figure should be updated with the current position values of the robot. A tutorial on making animations in Matlab can be found here.


问:
Mechanical design for motorized spherical caster wheels
Design goal is to have a mobile robot that operates on 3 large casters, essentially 2 to 4 inch diameter steel ball bearings, that are motorized. No other mechanism would touch the surface. The robot should thus be able to move in any XY direction on a flat surface, with steering being achieved by varying the speed and rolling direction of these wheels. The robot has no designated "front" side, so it does not need to (and should not have to) bodily turn, in order to move off in any given direction.

Conventional wheels or tracks are not the preferred approach.

Looking for suggested mechanical layouts of multiple rubber wheels, pressing down onto the steel ball from within the castor housing, to drive the ball in any direction. A single wheel on a stepper, rotated around the vertical axis using a sail-winch servo, is one approach under consideration. Would this be ideal, or are there any serious flaws in this approach?

Alternatively, is there any other suggested method of driving such a steel ball in any arbitrary direction under electronic control?

答:
How about Omnidirectional wheels?

You could drive the sphere on two pairs of such wheels, with each pair driven by one motor. This would give you two axis control of the sphere. I.E. you can drive forwards or sideways.

Or you could use three wheels and three motors just like this robot:

This allows you to spin the sphere about the vertical axis, if that's helpful.

The good thing about this solution is that the wheels both drive the sphere, and bear the weight.


答:
I would say the answer to the first question is "Yes and No".

Yes, you could hook a stepper motor directly to drive wheels on some sort of shuttle.  CNC controllers normally have a setting for inches/step or some equivalent.  If you set that correctly, the machine should drive the motors "correctly".

But No, this not likely to give you the output you want.  Stepper-based CNC machines work on the idea that the machine never "loses steps": that for every electrical pulse, the motor moves a fixed amount; and that N forward steps followed by N backwards steps brings you back to exactly where you started.  If you are driving wheels which rely on friction for motion, those two assumptions are almost certain to fail, and your output path will be stretched or compressed in strange ways.


答: Have you tried using combination of your RGB sensor with other sensors like LDR or photo diode. You can use these 2 sensors on the side with your RGB sensors at the centre which you say is quite accurate.  You can set your potentiometer  such that these 2 sensors can differentiate the background color from the lowers intensity line color. You can make a simple PID controller which can keep the robot following the line using the combination of these 3 sensors, while your RGB sensor can sense the coloured line as it is always on top of the line. I remember making a coloured line follower robot long back using photodiode which could sense the translation in color. Hope it helps.</p>

Title: Line follower for coloured lines

Body:
I am building a line-following robot with a Raspberry Pi Zero, using the explorer PHat.
The robot is supposed to follow black, red, green and blue lines and react to the colour, so it should drive faster on a red line and slower on a blue line.

I do not have much experience with line followers, so I am not sure what kind of hardware I need.
My questions are:

Is it possible to follow a red, blue or green line with IR LEDs? Most of the line followers obviously use IR LEDs (like TCRT5000), but they are supposed to only follow black lines.

I have a RGB sensor which works quite well with the explorer PHat and I am able to recognize colours very accurately. Is it possible to use this single sensor as a line follower? As the robot should be able to drive on a curvy course a single sensor is probably not enough?


问:
Ornstein Uhlenbeck vs Epsilon Greedy
There are many methods of exploring in a Reinforcement Learning setting but two of the most used ones are Ornstein Uhlenbeck (OU) processes and epsilon-greedy approaches. Could anyone elucidate the major advantages/disadvantages of using one over the other?

One of the things associated with OU processes is that you need to two additional parameters to bias exploration which might mean additional tuning. I'd be glad if someone could help!

答: Ornstein Uhlenbeck processes and epsilon-greedy are no antagonist but epsilon-greedy is a algorithm for finding actions for an Ornstein Uhlenbeck process. Reinforcement learning is another term for a Function Approximation, also known as metaprogramming. The idea is not to focus on the domain which can be control of a car or multi-arm-bandit problem but to recognize the data as a stochastic process. Like all blackbox optimization algorithm the problem is the huge search space. There are unlimited number of possibilites for a function to control the system. According to my knowledge, there is no example in which reinforcement learning ever solved a problem.</p>

Title: Ornstein Uhlenbeck vs Epsilon Greedy


问:
Stereo Camera calibration with different camera types
I'm trying to perform stereo camera calibration, rectification and disparity map generation. It's working fine with normal sample data. However, I'm trying to use the dual cameras on an iPhone 7+, which have different zoom. The telephoto lens has 2X zoom compared to the wide angle camera. I ran the images through the algorithm, and it is succeeding, although with a high error rate. However, when I open up the rectified images, they have a weird spherical look to the edges. The center looks fine. I'm assuming this is due to the cameras having different zoom levels. Is there anything special I need to do to deal with this? Or do I just need to crop any output to the usable undistorted area? Here is what I'm seeing:

EDIT:

I tried using the calibration result from these checkerboard images to rectify an image of some objects, and the rectification was way off, not even close. If I rectify one of my checkerboard images, they are spot on. Any ideas why that happens?

These are what my input images look like that result in the spherical looking output image. They are both taken from the exact same position, the iPhone was mounted to a tripod and I used a bluetooth device to trigger the shutter so the image wouldn't get shaken, my code automatically takes one image with each lens. I took 19 such images from different angles, all images show the full checkerboard. The more zoomed in image is the one that rectified to the top spherical looking image.

This is the code I am running. I compiled it and ran it using the sample images, that worked fine. Ran it with my own images and here I am.  https://github.com/sourishg/stereo-calibration

I might just need to crop the result to a certain area. Regardless, it doesn't seem to work cropping or not when I use a picture I took of normal objects. Here is the output of an image of normal objects I ran through the filter:

答:
It looks like what I saw when a colleague of mine was working with fisheye lenses; I found this post after doing an image search for "rectify fisheye image" and following the link from this picture.

At that post, they're using openCV to do the rectification. I'm always reluctant to bulk copy/paste someone else's content, so I'll just say that the tl;dr version of that post is:

Long story short, stereoCalibrate() couldn't handle the extreme distortion, but it you can remove that distortion before calling stereoCalibration().

As I asked in my comment above, you haven't stated what you're using to do the rectification, so I'm not sure how much this applies to you.

Hopefully this helps; if it doesn't, please edit your question to detail what exactly you're doing to generate that image.


问:
What is the difference between DC motor with encoder and DC with out encoder?
My question is: what is the difference between DC motor with encoder and DC without encoder? As long as I can control the speed of DC motor using PWM, for example on the Arduino, what is the fundamental difference?</p>

答:
Fundamental difference is closed loop feedback. Without encoder you just know how much speed you sent to engine, but have no information about speed that is on it - lower battery voltage will decrease your speed. Encoder gives you ability to measure engine <s>speed</s> position, from which you can calculate speed, and regulate those parameters, for example with PID regulator. Usage example can be micromouse robots, where odometry is crucial in moving through maze.

Read this to learn more about rotary encoders.


问:
Robots minimum distance
I am trying to implement a mechanism to make robots avoid being too close (Say in a distance less than d). I am not familiar with those systems and I have to implement a strategy to avoid robots being too close to each other. Could anyone recommend me some readings for such a problem or a set of keywords to search for? I don't know yet how to start.

答: A good place to start is with the work by Dr. Jur van den Berg and his colleagues. Check out the publications velocity obstacles and reciprocal collision avoidance. You could start with the latest paper, Reciprocal Collision Avoidance for Robots with Linear Dynamics using LQR-Obstacles, they have released on the subject and use the citations to find more related material.</p>

Title: Robots minimum distance


问:
Implementation of the Control of a Quadrotor, as taught in Aerial Robotics in Coursera
I completed the course of Aerial Robotics in Coursera and I want to implement what I learned in a real quadrotor. The thing is that when I see the equations given like this:
<img src="https://i.stack.imgur.com/TtsN0.png" alt="enter image description here">
For the sake of the argument let's assume I have implemented the PD Controllers and every moment I find u1 (the sum of the forces applied to the quadrotor) and u2 (the sum of the moments applied to the quadrotor). I then ask myself: How can I find what force and moment should specifically each one of the motors produce? And here I am stuck as I can't find an answer.Could anyone help?  </p>

答:
If i've understood your question correctly, you are trying to convert the desired set of moments and total force which you calculated from a hypothetical pd controller into a set of forces. This is the relation that needs to be solved

\begin{equation}
\begin{bmatrix}
u_1\\
\mathbf{u}_2
\end{bmatrix}
=
\begin{bmatrix}
1&1&1&1\\
0&L&0&-L\\
-L&0&L&0\\
\gamma&-\gamma&\gamma&-\gamma
\end{bmatrix}
\begin{bmatrix}
F_1\\
F_2\\
F_3\\
F_4\\
\end{bmatrix}
\end{equation}

where $u_1$ is the total force of all motors and $\mathbf{u}_2$ is the vector of moments acting on the system. This can simply be solved for by inverting this matrix. So
\begin{equation}
\begin{bmatrix}
1&1&1&1\\
0&L&0&-L\\
-L&0&L&0\\
\gamma&-\gamma&\gamma&-\gamma
\end{bmatrix}^{-1}
\begin{bmatrix}
u_1\\
\mathbf{u}_2
\end{bmatrix}
=
\begin{bmatrix}
F_1\\
F_2\\
F_3\\
F_4\\
\end{bmatrix}
\end{equation}


答:
As @szczepan mentions, the difference is one of feedback.

There are many ways to get feedback regarding the motion of a dc motor.   People implementing a control system will often put a mark on the motor's shaft, or attach a "flag" of masking tape, so that they can visually see the turning of the shaft.   This helps to ensure the direction of motion is correct (otherwise the dc polarity needs to be reversed).   It also helps for observing motion at slow speeds - but is otherwise not appropriate for an automated system.

If you want to automate the observations of the motor's rotation, you must implement some type of sensor that provides appropriate information to the control computer.   There are many ways to do this.   For example, you can monitor the current being consumed by the motor's windings, and use the motor constant $k_\tau$, to infer the torque generated by the motor.   This can be related to acceleration of the shaft by using an appropriate dynamic model of the system.   This method, however, is not very accurate and is prone to modelling errors and signal noise.  This method is similar to you monitoring the PWM output and inferring motion dynamics - neither is robust to changing dynamics of the system.  Another approach is to glue a magnet to the shaft, and monitor it with a Hall effect sensor.  This will provide a single pulse to the computer for each rotation of the shaft.   This is frequently a solution for high-temperature, or dirty, environments (such as in automotive applications).   However, often you need finer granularity of the motion.  That is where encoders come in.

There are two basic types of encoders:  incremental and absolute.  They can be further characterized as quadrature, or non-quadrature encoders.  A non-quadrature incremental encoder provides a single pulse to the controller for every incremental motion of the motor shaft.  As the previous answer makes clear, this position feedback can be interpreted to infer velocity, acceleration, and possibly jerk (although three derivatives of a sensed value are "spikey" in most applications).   This type of encoder, however, only provides information when the position changes, and it does not provide any information about the direction of motion.   A quadrature encoder provides two pulses, out of phase, that can be used to detect direction also.

An absolute encoder can provide not only the same information as the incremental encoder does, but it also has many more bits of information from which you can know the angular position of the shaft, in addition to detecting the incremental changes in position.

You can make a very simple encoder by using a disc with slots cut into it.   Place a photodiode on one side of the disc, and a photodetector on the opposite side.  You will get one pulse each time a slot passes between the sensor elements.   As you can see, the accuracy of motion detection is determined by the number of slots in the disc.   Encoders are available with many different numbers of pulses per revolution.

I suggest reading a book such as this one if you want to know more about motion metrology:

Title: What is the difference between DC motor with encoder and DC with out encoder?

Body: My question is: what is the difference between DC motor with encoder and DC without encoder? As long as I can control the speed of DC motor using PWM, for example on the Arduino, what is the fundamental difference?</p>


问:
Simulation software for KUKA LBR iiwa robot?
I have been working with KUKA LBR iiwa 7 R800 robot, with the KUKA's IDE, which is the 'Sunrise.Workbench'. Since it does not have any virtual platform to verify the code (simulate), it's been quite difficult, as I need to test each code by deploying to the robot.

Can anyone suggest if there is any simulation software available where I can test the code written using the Robotics API in Sunrise.Workbench?

I came across V-REP simulation software, but, not sure if I can use my code in the workbench platform.

Appreciate if anyone can shed some light on it.
Thanks in advance.

答:
I have drivers for the kuka iiwa and integrate the V-REP simulator with my library grl, you can even have the simulator drive the physical robot.

Another independent tool is iiwa_stack.
grl can integrate with iiwa_stack as well.


问:
KUKA arm's damping ratio
Does anyone know how one can calculate the exact damping of KUKA arm during impedance control mode. According to their manual one can control only the Lehr's ratio. However, I want to know the exact value,say in Ns/m.</p>

答:
If Kuka does not specify the damping ratio, then on remaining option is determining it experimentally. </p>

<p>You can excite the structure (e.g. with an excitation hammer) and measure the vibration response (e.g. using accelerometers). Please note that you might need to measure in different poses to compute damping for different joint and to see sensibility to pose. </p>

Title: KUKA arm's damping ratio

Body:
If Kuka does not specify the damping ratio, then on remaining option is determining it experimentally.

You can excite the structure (e.g. with an excitation hammer) and measure the vibration response (e.g. using accelerometers). Please note that you might need to measure in different poses to compute damping for different joint and to see sensibility to pose.


答:
Do you mean too close to each other?

It sounds like you might be referring to the sorts of steering behaviours that Craig Reynold's refers to in his Boids project. He describes some behaviours that exhibit as flocking or herding because of the way the participants avoid each other, yet stick together.  He uses the terms 'separation', 'alignment' and 'cohesion' to describe the algorithms involved.

Craig applies these to computer simulations, but you could just as well apply the concepts to robots.

Other searches that may prove beneficial: 'flock simulation', 'crowd modelling'.

Title: Robots minimum distance

Body: I am trying to implement a mechanism to make robots avoid being too close (Say in a distance less than d). I am not familiar with those systems and I have to implement a strategy to avoid robots being too close to each other. Could anyone recommend me some readings for such a problem or a set of keywords to search for? I don't know yet how to start.


问:
How to get live audio from robot?
I am building a robot and I want to be able to hear sounds from it's environment (ideally from my laptop). What is the best way to get live audio from my robot's microphone to my computer?

I have looked into a few solutions for hosting live audio streams using packages such as darkice and icecast. I'm just wondering about better solutions for robotic applications.

Additional details:
- I have access to hardware such as Raspberry Pi, Arduino, etc.

答: If you are controlling the Robot with ROS, i suggest you to look at this package audio_common. With this we can live stream the audio or capture it. You can use raspberry pi as a node and your laptop as a ros server.There is a tutorial to do exactly what you want over here "Remotely listen to what your robot is listening"</p>

Title: How to get live audio from robot?


问:
Differential Drive Odometry Model
```<code>%PREDICT Apply odometry model for differential drive robot.
%   [R,FXR,PATH] = PREDICT(R,ENC,PARAMS)
%   calculates the final pose and final pose covariance matrix given
%   a start pose, a start pose covariance matrix and the angular wheel
%   displacements in ENC. PARAMS contains the robot model and the
%   error growth coefficients.
%
%   Input arguments:
%      R   : differential drive robot object with start pose R.X, R.C
%      ENC : structure with fields
%            ENC.PARAMS.KL: error growth coefficient of left wheel
%            ENC.PARAMS.KR: error growth coefficient of right wheel
%               with unit in [1/m].
%            ENC.STEPS(i).DATA1: angular displacements of left wheel
%            ENC.STEPS(i).DATA2: angular displacements of right wheel
%               in [rad] and monotonically increasing
%      PARAMS.B : wheelbase in [m]. Distance between the two wheel
%                 contact points
%      PARAMS.RL: radius of left wheel in [m]
%      PARAMS.RR: radius of right wheel in [m]
%
%   Output arguments:
%      R    : differential drive robot object with final pose R.X, R.C
%      FXR  : 3x3 process model Jacobian matrix linearized with
%             respect to XROUT
%      PATH : array of structure with fields PATH(i).X (3x1) and
%             PATH(i).C (3x3) which holds the poses and the pose
%             covariance matrices over the path
%
%   The function implements an error model for differential drive
%   robots which models non-systematic odometry errors in the wheel
%   space and propagates them through the robot kinematics onto the
%   x,y,theta-pose level.
%
%   Reference:
%      K.S. Chong, L. Kleeman, "Accurate Odometry and Error Modelling
%      for a Mobile Robot," IEEE International Conference on Robotics
%      and Automation, Albuquerque, USA, 1997.
%
%   See also SLAM.

% v.1.1, ~2000, Kai Arras, ASL-EPFL, Felix Wullschleger, IfR-ETHZ
% v.1.2, 29.11.2003, Kai Arras, CAS-KTH: toolbox version

function [r,Fxr,path] = predict(r,enc)
</code>```

<p>When I try to run this complete code, it asks me to input values for R and Enc. I am not sure whether they are just one digit values or a matrix. Can anyone help me by looking at the description in the code, what kind of input is required. </p>

答:
The inputs needed for the function are objects of the structures R and ENC. The member variables are clearly specified in the description. Declare and initialize these values before calling the function. That should solve your problem.

learn more about structures in Matlab and how to initialize one here: https://in.mathworks.com/help/matlab/ref/struct.html

Hope it helps!

Title: Differential Drive Odometry Model


问:
Can I use a FTC regulation phone to use the camera on multiple tasks?
PREFACE:

THIS QUESTION REGARDS FTC ROBOTICS
I am aware that a question similar to this exists on SE and I have looked at it, but the solutions provided did not solve my problem, and the nature of my question has additional constraints and criteria involved that make this a distinct problem.

PROBLEM:

I have been put in charge of creating java classes to add to an existing app, used to control a robot (FTC robotics, for those who are wondering). The features I have been given to add to the app include:

Shape detection (provided by FTC, all I need to do is tweak some
files)

Automatically record and save a video in the background of the app using the back camera

QUESTION:

I was wondering, if this is even possible, how I would go about both recording video and using shape detection? How do I even record a video from the background of an app? If i cannot achieve both I was told to prioritize recording, as we have substitutes for shape detection.

SPECS:

Motorola moto g 2nd gen with Android Marshmallow

Or as a fallback:

ZTE speed with Android Marshmallow

答: OpenCV is a comprehensive vision processing library with an Android port. It should work fine for both of your needs.</p>


问:
Forward Kinematics od Differential Robot
```<code>r = 1;
w1 = 4;
w2 = 2;
l = 1;

R = [0 -1 0; 1 0 0; 0 0 1];
X = [(r*w1)/2 + (r*w2)/2; 0 ; (r*w1)/(2*l) - (r*w2)/(2*l)];

A = R*X;
disp(A)
</code>```

I am getting the solution for the matrix as [0; 3; 1] which is exactly what I expect. I would like to input a series of w1 and w2, Lets say I have a data file 1.xlsx and 2.xlsx with ten values each. I want to load 1.xlsx into w1 and 2.xlsx into w2 and get ten answers for X. How can I do that?

答:
1) Load or import the data that is in your xlsx files into w1 and w2, by using importdata as an array of values.

2) Write a for loop for extractting individual values from w1 and w2, to perform the necessary computation.


问:
I found the matrices but can't find the inverse kinematics angles
I need to find inverse and forward kinematics of Mitsubishi RV-M2 as a homewrok. I found the forward kinematics part. But I got stuck in inverse kinematics.

Teacher said we can think that wrist joints is not moving.(To make equations easier I guess.) This is why I thought tetha4(in T4) and tetha5(in T5) should be 0.

Here is my MATLABcode

```<code>syms t1 t2 t3 d1 a1 a2 a3 d5 px py pz r1 r2 r3 r4 r5 r6 r7 r8 r9 % sybolic equations

T1=[cos(t1)     -sin(t1)        0       0;
    sin(t1)     cos(t1)         0       0;
    0            0              1       d1;
    0            0              0       1;];

T2=[cos(t2)     -sin(t2)        0       a1;
    0            0              -1      0;
    sin(t2)     cos(t2)         0       0;
    0            0              0       1;];

T3=[cos(t3)     -sin(t3)        0       a2;
    sin(t3)     cos(t3)         0       0;
    0             0             1       0;
    0             0             0       1;];

T4= [0           -1             0       a3;
     1             0             0       0;
     0             0             1       0;
     0             0             0       1;];

T5=[1             0             0       0;
    0             0            -1      -d5;
    0             1             0       0;
    0             0             0       1;];

Tg= [r1 r2 r3 px;
    r4 r5 r6 py;
    r7 r8 r9 pz;
    0 0 0 1;];

left= inv(T1)* Tg;
left=left(1:4,4);
left=simplify(left)
right= T2*T3*T4*T5;
right=right(1:4,4);
right=simplify(right)
</code>```

This gives us

I find t1 using this and results are matching with forward kinematics equations.  But I couldn't find t2 and t3. How can  I do that? Is there a formula or somethig?

答: I don't want to just give the answer....try squaring the $x$ and $z$ terms (after moving $a_1$ to the left) and see where that gets you.   </p>


问:
Can I create an autonomous robot that can adapt its strategy using machine learning?
BACKGROUND:

I am creating a robot to score the most points in 30 seconds while running autonomously. Naturally, two thoughts come to mind: Linear programming and machine learning.

Linear programming would provide a stable, simple method of scoring points. However, it is limited by what it can do, and optimizing scores would require reworking the entire bot.

PROBLEMS:

The robot and code itself can change, but it is not time efficient due to the fact that it would require completely reworking the code and robot by a single programmer. The robot has to work with what its got.

QUESTION:

Can I create Android Java classes to allow my robot to work the field as an AI and tweak its strategy or course of action based on stats from previous rounds? (Self-Supervised Learning) If it is possible to do, how would I do it?

SPECS:

Max robot size of 18'' cubes

Android Marshmallow

ZTE speed or Motorola moto g gen 2 phones

Multiple inputs from a controlling phone and various sensors

Output to multiple motors and servos

答:
I think the problem you're going to find is that machine learning requires learning. If the goals or objective vary just a little, then manually adjusting the software shouldn't be too difficult (if you programmed it well), and it might only take a few trials for the AI to adjust to the new scenario.

If the objectives change so much that you're looking at "reworking the entire bot," then you're probably also looking at ditching the previous AI and retraining it on the new course.

:EDIT:

I wrote the answer above on my phone over the weekend. I'll add some more content now:

What you're asking for is almost more like consciousness than a "simple task" - you want the robot to be spatially aware of itself, aware of the objectives its been given, how to move around its environment and then how to use its physical structure to achieve the goal. I'm positive this is all very far beyond the scope of the project/competition you're asking about.

The route I would take would be to break each action out into their own functions and then tune each as required. So you might have functions like:

Localize - this is how the robot determines where it is. Dead reckoning, localization, SLAM (simultaneous localization and mapping), etc. would exist here.

Navigate - this would do pathfinding as required to set waypoints or instructions for how the robot would get from a given start to a given end. Maps and navigation routines like A*, Dijkstra, etc. exist here.

Locomotion - this would be the low-level interface between the navigate function and the wheels. Navigate says turn to a heading of XXX degrees and travel YYY centimeters, Locomotion actually does it. Here's where the wheel base, wheel radius, gear ratios, and other parameters related to locomotion reside.

Obstacle detection - if required, a detected obstacle could pause the navigate/locomotion routine, update the map with an obstacle, and force a new navigate call to find the best path from the current position to the original destination. Mapping, SLAM, or other detection algorithms could exist here.

Manipulate - this would control the device on the robot that is designed to interact with the course.

Mission control - this would be the higher-level function that calls everything else.

So, for example, if you were given some arbitrary number of ball locations and told to deposit them in a basket, your code might look something like the following (Matlab) pseudo-code:

function MissionControl()
basketLocation = [xBasket, yBasket];
objective(1).startPosition = [xBall1, yBall1];
objective(2).startPosition = [xBall2, yBall2];
% This continues for all objectives

% All of the objective locations are at the basket, so
% assign all of the objective goals to that location.
[objective.goal] = deal(basketLocation);

for currentObjective = 1:numel(objective)
    currentPosition = Localize();
    path = Navigate(currentPosition, objective(currentObjective).startPosition);
    for currentWaypoint = 1:numel(path)
        Locomotion(currentPosition,path(currentWaypoint));
        currentPosition = Localize();
    end
    Manipulate('get');
    currentPosition = Localize();
    path = Navigate(currentPosition,objective(currentObjective).goal);
    for currentWaypoint = 1:numel(path)
        Locomotion(currentPosition,path(currentWaypoint));
        currentPosition = Localize();
    end
    Manipulate('put')
end
```

Each subfunction has its own parameters - again, things related to how the robot moves goes in Locomotion(). How the robot 'get's the ball goes in Manipulate(), etc. If you were going to insist on using AI, I would encapsulate each AI routine in a similar manner, such that there are actually several AI routines.

Again, if there are any dramatic changes, such as a dramatically different footprint or something similar, you'll probably need to wind up retraining the AI. If you don't discard the previous AI, then all of the new training is going to try to "fight" its previous learning of how to behave or interact, and the result may not be optimal in either scenario (old or new).

But like I mentioned earlier, any use of AI would, in my opinion, be a big overkill. Parameterize your code - don't use any magic numbers - and you should be able to update/tune your performance relatively quickly by tweaking the configuration parameters.

Body:
I think the problem you're going to find is that machine learning requires learning. If the goals or objective vary just a little, then manually adjusting the software shouldn't be too difficult (if you programmed it well), and it might only take a few trials for the AI to adjust to the new scenario.

If the objectives change so much that you're looking at "reworking the entire bot," then you're probably also looking at ditching the previous AI and retraining it on the new course.

:EDIT:

I wrote the answer above on my phone over the weekend. I'll add some more content now:

What you're asking for is almost more like consciousness than a "simple task" - you want the robot to be spatially aware of itself, aware of the objectives its been given, how to move around its environment and then how to use its physical structure to achieve the goal. I'm positive this is all very far beyond the scope of the project/competition you're asking about.

The route I would take would be to break each action out into their own functions and then tune each as required. So you might have functions like:

Localize - this is how the robot determines where it is. Dead reckoning, localization, SLAM (simultaneous localization and mapping), etc. would exist here.

Navigate - this would do pathfinding as required to set waypoints or instructions for how the robot would get from a given start to a given end. Maps and navigation routines like A*, Dijkstra, etc. exist here.

Locomotion - this would be the low-level interface between the navigate function and the wheels. Navigate says turn to a heading of XXX degrees and travel YYY centimeters, Locomotion actually does it. Here's where the wheel base, wheel radius, gear ratios, and other parameters related to locomotion reside.

Obstacle detection - if required, a detected obstacle could pause the navigate/locomotion routine, update the map with an obstacle, and force a new navigate call to find the best path from the current position to the original destination. Mapping, SLAM, or other detection algorithms could exist here.

Manipulate - this would control the device on the robot that is designed to interact with the course.

Mission control - this would be the higher-level function that calls everything else.

So, for example, if you were given some arbitrary number of ball locations and told to deposit them in a basket, your code might look something like the following (Matlab) pseudo-code:

function MissionControl()
basketLocation = [xBasket, yBasket];
objective(1).startPosition = [xBall1, yBall1];
objective(2).startPosition = [xBall2, yBall2];
% This continues for all objectives

% All of the objective locations are at the basket, so
% assign all of the objective goals to that location.
[objective.goal] = deal(basketLocation);

for currentObjective = 1:numel(objective)
    currentPosition = Localize();
    path = Navigate(currentPosition, objective(currentObjective).startPosition);
    for currentWaypoint = 1:numel(path)
        Locomotion(currentPosition,path(currentWaypoint));
        currentPosition = Localize();
    end
    Manipulate('get');
    currentPosition = Localize();
    path = Navigate(currentPosition,objective(currentObjective).goal);
    for currentWaypoint = 1:numel(path)
        Locomotion(currentPosition,path(currentWaypoint));
        currentPosition = Localize();
    end
    Manipulate('put')
end

Each subfunction has its own parameters - again, things related to how the robot moves goes in Locomotion(). How the robot 'get's the ball goes in Manipulate(), etc. If you were going to insist on using AI, I would encapsulate each AI routine in a similar manner, such that there are actually several AI routines.

Again, if there are any dramatic changes, such as a dramatically different footprint or something similar, you'll probably need to wind up retraining the AI. If you don't discard the previous AI, then all of the new training is going to try to "fight" its previous learning of how to behave or interact, and the result may not be optimal in either scenario (old or new).

But like I mentioned earlier, any use of AI would, in my opinion, be a big overkill. Parameterize your code - don't use any magic numbers - and you should be able to update/tune your performance relatively quickly by tweaking the configuration parameters.


问:
Integrating GPS into Graph SLAM (how orientation fixed?)
I'm working on Graph SLAM to estimate robot poses (x, y, z, roll, pitch, yaw). Now I want to integrate GPS measurement (x, y, z, of course no angles).

I implemented GPS as pose's prior. But I have a problem.

Position(x, y, z) is perfectly corrected by graph optimization

But orientaiton(roll, pitch, yaw) is very unpredictable(unstable) after optization.

i.e. It looks like position is fitted by the sacrifice of orientation.

I'm very confused about what's the right way of integrating GPS into graph SLAM. GPS should be handled as prior? or landmark? or one of pose-vertices?

...Thanks for your help in advance.

PS

I use g2o as a graph-optimization library. In g2o, I implemented GPS measurement with EdgeSE3_Prior. GPS's quality is RTK so it's enough precise.

答: Frankly speaking, I don't have any experience with implementing a SLAM algorithm. That said, GPS gives you a position and SLAM gives you a position. My advice would be to use a data fusion technique, such as a Kalman filter or maybe even the Madgwick filter, to combine the position estimates.</p>


答:
You can use a very low information matrix value at the orientation elements of your state,  given that the information matrix is the inverse of the covariance matrix.

The covariance matrix represents the uncertainty about the measurement,  and the information matrix the certainty about it.

So, the GPS constraints would have a small value at the elements of the information matrix corresponding to the orientation

Title: Integrating GPS into Graph SLAM (how orientation fixed?)

Body:
I'm working on Graph SLAM to estimate robot poses (x, y, z, roll, pitch, yaw). Now I want to integrate GPS measurement (x, y, z, of course no angles).

I implemented GPS as pose's prior. But I have a problem.

Position(x, y, z) is perfectly corrected by graph optimization

But orientaiton(roll, pitch, yaw) is very unpredictable(unstable) after optization.

i.e. It looks like position is fitted by the sacrifice of orientation.

I'm very confused about what's the right way of integrating GPS into graph SLAM. GPS should be handled as prior? or landmark? or one of pose-vertices?

...Thanks for your help in advance.

PS

I use g2o as a graph-optimization library. In g2o, I implemented GPS measurement with EdgeSE3_Prior. GPS's quality is RTK so it's enough precise.


问:
Granite devices Ionicube
Is it possible to enable/disable the 4 Ioni drives mounted in Ionicube individually?  It appears with IoniCube that enable/disable applies to all Ioni drives simultaneously.  However, Ionicube 1X does appear to have enable/disable for individual Ioni drives.  Can you confirm?

I wish to control the enable/disable state of each Ioni drive separately.  And if possible to do this on IoniCube.

Most grateful for your help!

Best wishes,
Mark

答:
The IONICUBE has global enable and STO inputs, so all IONI drives are enabled/disabled simultaneously. And thus, enabling a single IONI drive is not possible.

The IONICUBE 1X only hosts a single IONI drive, and thus it's enable and STO inputs control only that drive.

Title: Granite devices Ionicube