QuadCopters

RBBM
Phidgetly
Posts: 19
Joined: Mon Nov 23, 2009 6:03 am
Contact:

Re: QuadCopters

Postby RBBM » Tue Nov 22, 2011 8:37 am

Hi all,
sorry for my late response, but I was busy finishing my diploma thesis. As we told you, our biggest problem at present is the time delay the motor controllers produce. The vibrations are reduced mechanically. Now it seems, as Patrick wrote, that there is an additional delay due to USB issues.
The quadcopter's controlling algorithm is written in a loop that runs with 3kHz, which should be sufficient. The sensor data is filtered with a low-pass FIR which is included in the main loop. The FIR is tested on real data and produces a delay of < 5ms. The sensor data (roll/pitch) is then fused by weighing them. @Danielaaroe: On the other hand I am very interested in your Kalman implementation. Is it possible that you send it to us via eMail?

As we mentioned beforehand, we are working on a review of our software framework. We want some features implemented that will be used in future projects. The quadcopters hardware will be introduced completely into an Elwood II. Until the software is stable we will stay with non-flying vehicles. The next projects will be announced here. Maybe with a new Thread.

The intention of our work is to do all the high-level programming in Java. Our first attempt to count the flight stabilisation as high-level was wrong obviously. So some time time in the fututre we will probably switch to another system for flight stabilisation but this is not decided yet

Greetings from Lower Bavaria
Michael (RBBM)

User avatar
Patrick
Lead Developer
Posts: 3067
Joined: Mon Jun 20, 2005 8:46 am
Location: Canada
Contact:

Re: QuadCopters

Postby Patrick » Tue Nov 22, 2011 10:00 am

The 1056 has a maximum data rate of 250Hz. I'm not sure what the point of a 3000Hz loop would be. You should probably be responding to the spatialData event to get the lowest latency - running your very quick algorithms and sending the motor control commands directly from the spatialData event callback.

-Patrick

RBBT
Phidgeteer!
Posts: 90
Joined: Sun Nov 15, 2009 2:16 pm
Location: Lower Bavaria (Germany)
Contact:

Re: QuadCopters

Postby RBBT » Wed Nov 23, 2011 12:16 am

Patrick wrote:The 1056 has a maximum data rate of 250Hz. I'm not sure what the point of a 3000Hz loop would be. You should probably be responding to the spatialData event to get the lowest latency - running your very quick algorithms and sending the motor control commands directly from the spatialData event callback.

-Patrick


Hello,
this 3kHz loop is running in a seperate thread and does only
the calculations. Data acquisition is done in another thread via polling
the sensors. Using Java' event mechanism for reading sensor data
produces too much Objects which forces the gc often to run. The gc pauses
are up to 300 ms, this is disastrous during a flight task. Using this strategy
and giving jamVM as much memory as possible delays the gc up to 12 - 15 minutes.
Best Regards from Lower Bavaria
RBBT
http://www.robobuam.de/

User avatar
Patrick
Lead Developer
Posts: 3067
Joined: Mon Jun 20, 2005 8:46 am
Location: Canada
Contact:

Re: QuadCopters

Postby Patrick » Wed Nov 23, 2011 1:00 pm

I think this projects really need to be rewritten in C.

-Patrick

danielaaroe
Phidgetsian
Posts: 9
Joined: Mon May 03, 2010 1:30 pm
Contact:

Re: QuadCopters

Postby danielaaroe » Thu Nov 24, 2011 2:54 pm

I was not able to find the initial equations, but i was able to locate a thread in the arduino forum where I once posted the equations.

http://arduino.cc/forum/index.php/topic,52717.0.html

There is also a link to the page where i got the equations in the first place. The only thing i did was determine the matrix size and create non-matrix equations.

to make it easier ive used:
[1, 2,
3,4] indexes

for simplicity. It wastes one index(0).
The "a" is just to be able to use multiple axis and store different K factors and such for multiple axis.

Ive used this as is with great results. Its not the most complex version of the calman filter but it works great for this type of application.

moisdc
Phidgetsian
Posts: 13
Joined: Wed Oct 07, 2009 6:21 am
Contact:

Re: QuadCopters

Postby moisdc » Mon Dec 19, 2011 6:05 am

Dear colleagues,
Currently I am working in a project about a car. We have a similar problem with Spatial 3/3/3. We want to get a reliable acceleration, but if we filter out row data with a FIR (for example) is not enough.
We want to control angles such as roll and pitch, because gravity component acceleration should be removed in each axis.
However we have a problem with gyroscope's drift. According to the 1056 specifications, drift/minute = 4º typical in the gyroscope
My question is:
How did you remove this effect for the gyroscope??
I appreciate so much some idea or piece of advice
Best regards
- Moises Diaz-Cabrera

RBBM
Phidgetly
Posts: 19
Joined: Mon Nov 23, 2009 6:03 am
Contact:

Re: QuadCopters

Postby RBBM » Mon Dec 19, 2011 10:00 am

Dear Moises Diaz-Cabrera,

during the last days we refined our data processing for the Spatial data. Currently we are using a Kalman filter following the information that can be found here http://en.wikipedia.org/wiki/Kalman_filter. Further information can be found in Tom Pycke's tutorial. The code which can be found in danielaaroe's link does not work as expected.

The filter and the calculation algorithms work pretty well. We are now able to calculate values for roll, pitch and compass which are almost completely independent from vibration effects. The compass data is derived from the magnetic field vector the IMU provides which is rotated to account for roll and pitch influence. This gives us the course angle for all IMU orientations.

Currently I am working on streamlining the implementation and to make it more mathematically pleasing. In case you are not afraid of a physicist's coding style I can provide the sources.

Greetings from Lower Bavaria

Michael (RBBM)

moisdc
Phidgetsian
Posts: 13
Joined: Wed Oct 07, 2009 6:21 am
Contact:

Re: QuadCopters

Postby moisdc » Mon Dec 19, 2011 12:33 pm

Dear Michael,
Firstly, thanks for your faster answer. I've seen your website and your project. It's really fantastic! congratulations for your job.
I'm starting my Ph.D. According to papers I've read, I should use Kalman Filter.
I'm used to running simulation in Matlab at first. Also I am really keen on learning KF in Matlab for Spatial 3/3/3, because this is my current problem.
I wonder if you could help me, maybe some code in Matlab will be very useful for me now! Anyway, thank you for all knowledge which you have shared in this forum.
Best regards and greetings from Canary Island (Spain) ;)
- Moises Diaz-Cabrera

moisdc
Phidgetsian
Posts: 13
Joined: Wed Oct 07, 2009 6:21 am
Contact:

Re: QuadCopters

Postby moisdc » Tue Dec 20, 2011 2:33 pm

Dear colleagues,

I have tried to study some about KF. I strongly recommend you a website for a interactive course about EKF and SLAM: http://homepages.laas.fr/jsola/JoanSola/eng/course.html

I have some douts about covariance and other datas which should be presented in the 1056_0 - PhidgetSpatial 3/3/3's specifications (http://www.phidgets.com/products.php?ca ... _id=1056_0)
Michael (or other), could you help me in this part of my work, please?

Thanks in advance
- Moises Diaz-Cabrera

moisdc
Phidgetsian
Posts: 13
Joined: Wed Oct 07, 2009 6:21 am
Contact:

Re: QuadCopters

Postby moisdc » Wed Dec 21, 2011 4:21 pm

Hi everybody,

Should I make a KF for each signal? I mean, Spatial device has 9 signal (3/3/3), so that, should I make 9 independent KF?
Or
Should I make a KF which manages the 9 signals plus only one reference signal?

Thanks in advance and sorry for my silly question.
- Moisés Díaz-Cabrera


Return to “Robotics”

Who is online

Users browsing this forum: No registered users and 1 guest