Revo major drift in GPS flight mode
« on: December 09, 2015, 04:04:44 am »
Need some help in figuring out what else I ca try to make my CC3D Revo work in GPS mode. 

Some equipment info:
250mm Tarot Robocat drone
Afro Spec with Simon K 20A ESC
Multistar Elite K2300 2 x CW
Multistar Elite K2300 2 x CCW
Revo board
Ublox M8N GPS
3S 2200mAh battery
OPLink wireless connection
F701 RX for Spektrum 7 channel TX

If I set up the FC to be used in the Basic(Complementary) mode without GPS it flies very good.  Everything works well.  Once I set up to run in the GPS navigation(INS13) mode I get major drift and overall chaotic flight.

I have tried the following:
- re-calibration of the sensors (many, many times)
- re-calibration of the sensors via wireless connection to avoid USB interference (many, many times)
- re-calibration of the full set up, including drone type, motors, transmitter, etc. (many times)
- checked if the barometer is OK via the scope tab in the GCS (seem OK , no major out of control elevation changes)
- All software and firmware is up to date. 

I am mot sure what else to try.  I spend the last 2 weeks working on this and I am not sure where to go or what else to do next.

Can anyone suggest some other things I can try?
« Last Edit: April 19, 2016, 12:30:16 pm by f5soh »

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Revo major drift in GPS flight mode
« Reply #1 on: December 09, 2015, 11:10:40 am »
Hi,

Welcome here.

How is the Mag alarm in SystemHealth while flying ?

Please post you config file: File > Export UAV settings.

Re: Revo major drift in GPS flight mode
« Reply #2 on: December 09, 2015, 05:46:49 pm »
We probably need either a detailed description of what it is doing wrong, or a video with a running audio commentary of what it is doing wrong.

"major drift and overall chaotic flight"  if this is mainly a vertical problem it is one thing (baro, several possibilities).  If horizontal, be aware that before the first flight of the day, you need to let the quad sit outside, powered up, for 15 minutes, to download the almanac and get a really good satellite fix.

How well does Attitude mode with AltitudeVario thrust sub-mode fly?

Re: Revo major drift in GPS flight mode
« Reply #3 on: January 14, 2016, 12:59:17 pm »
hello,
i have exact the same problem.... we are here on canary islands/fuerteventura and build & repair copters and used a lot of OP CC3D flight controllers. i personally build up over hundert copters with CC3D without any problem but this REVO board makes me crazy. we ordered (aliexpress + banggood) from two different sources each 3 controllers and are not able to bring them up in the air! iam now two weeks trying to calibrate them... no way.  in basic mode absolute no problem, copter flights well... changing settings to GPS mode all goes wrong!
also in the HUD very unstable when copter is sitting still on the table. somtimes power on and HUD shows 45 degree roll to the right.
somtimes also in stabilezed mode without any GPS function drifts hard to the right...
new calibration without GPS in wizzard.... copter flights smooth... changing settings again to gps and also change flight modes with gps function... all three flightmodes are not longer flighable... including 1. flight mode (stabilize 1 standard, without any GPS function or assist)
i do not like to capitulate after two weeks of intensive investigations but i need really help!
somebody here on canary islands or UK who wants to visit me :-) for some days ?
you can send me email to my personal address with your contact phone number, i will call you by skype:  [email protected]
thanks to all future help and some sunny greetings from the canary islands

Joe_D

  • **
  • 94
Re: Revo major drift in GPS flight mode
« Reply #4 on: January 14, 2016, 01:19:58 pm »
Hello, I was experiencing the same behaviour 4 months ago using a Revolution board from fisherhobby. I was not able to obtain a stable flight until I bought a separate compas and wired it instead of the on board mag. I mounted it 10cm away from all the power lines and today my tricopter is flying without problem, attached is a video showing a hovering in the wind.

You can add the external mag like I did or wait for the next release of the Librepilot that will support the I2C connection for the compas.

I also had a baro problem with the revo clone, I had to remove a capacitor as explained in the "Warning: At least some sellers are selling Revos with bad baros" topic.

First I would recommend to check the MAG status when flying, it should stay green most of the time. Then you can check the Baro accuracy in thes cope window, it should fluctuate +/-0.5m max.

Joe

Mateusz

  • *
  • 808
Re: Revo major drift in GPS flight mode
« Reply #5 on: January 14, 2016, 01:58:02 pm »
First I would recommend to check the MAG status when flying, it should stay green most of the time. Then you can check the Baro accuracy in thes cope window, it should fluctuate +/-0.5m max.

Keep in mind that
  • Mag must be calibrated outdoors using oplink far from metalic items
  • Mag and GPS need only 1s of both being green to make arming possible. So if the mag is badly calibrated (i.e indoors) it may allow arming but it wont fly stable.
  • Mag must be away from power lines, other wires good if are short and twisted. (I would google how to reduce electromagnetic interference)
  • If you decide to use external mag usually built-in GPS board with next LibrePilot release or using development branch from Cliff, then you must mount GPS far from electronics and very rigid, so it does not rotate after whole system has been calibrated. In case mag and accel do no agree you will have oscillations in EKF states.
  • If you change anything in the aircraft, move something around, I would suggest recalibrating magnetometer again.

CC3D is very different from Revo. CC3D afaik uses complementary filter to fly and only two sensors Gyro and Accel. Revo uses extended kalman filter (EKF) with additional sensors Mag, Baro and GPS.
Although EKF picks best of all sensors, if one component is badly calibrated it may introduce noise. If you see oscillations in EKF atitude.states in Scopes, then from my experience it was usually Mag problem.

When it comes to GPS
  • You should use it only in completely clear sky far from buildings. Multpath reflections from buildings may confuse GPS and introduce spikes, you can see that by enabling diagnostics on the map in GCS, and the green path will show RAW GPS route. It should more or less travel around your location without big jumps far away.
  • GPS must get a good lock, so you need to leave it be on clear sky for ~20min before first flight. The super-capacitor in the GPS unit that keeps almanac in memory usually lasts for 5-6h without power, but it never wears off like battery.
« Last Edit: January 14, 2016, 02:07:53 pm by Mateusz »

Re: Revo major drift in GPS flight mode
« Reply #6 on: January 15, 2016, 12:50:02 am »
What GPS are you using?  If using the OP GPS with mag, and you have configured to use external mag (the one on the GPS) then you must have GPS/mag pointing in the correct direction.

External mag puts mag sensor farther away from the bad high current wires in the quad.  Released version only supports OP GPS mag for external mag.  Next release will have more options for external mag.

All multicopters that want to use GPS must have a working mag sensor.  To make that work, you must carefully and tightly twist all high current wire pairs (and triples):  Battery to Power Distribution Board, PDB to ESC, ESC to motor.  For very small quads or very powerful quads, this is not good enough and you must use an external mag sensor.

I recommend that you start with two modes on your flight mode switch:  Attitude, and VelocityRoam.

ptbh

  • *
  • 22
Re: Revo major drift in GPS flight mode
« Reply #7 on: February 07, 2016, 08:49:52 pm »
I too am having problems trying to get my quad to work with GPS(INS13), experiencing the same issues expressed by others on this topic.  I do believe that the revo onboard mag is potentially the issues as this shows instability when the motors are powered up.  I would like to try the external I2C mag which is in the antenna housing with the uBlox M8N, mounted much further away from the power wiring.  When is the next firmware release likely to be available that will support more options for external mags?  If not soon, how could I use an external mag like Joe_D has done?

Re: Revo major drift in GPS flight mode
« Reply #8 on: February 22, 2016, 01:04:06 pm »
Just making some long delayed rounds of the forum.

Does your mag sensor health go red when the motors are running at hover power?  If so, it is basically not flyable in GPS modes till you fix that.

The first thing to do to fix your mag problems is to twist all your power wire pairs / triplets: mattery to PDB, PDB to ESC, ESC to motor, and use a good PDB or hand wiring.  This is required, but more is needed for powerful or small multicopters.  It is basically impossible to use the onboard mags on a small and powerful multicopter.  If you still have mag problems that only happen with the motors running, then you need an aux mag.

The second thing is to use an external (aux) mag.  With 15.09 that means OP GPS V9.  To use the mags in a cheap eBay PixHawk/APM GPS (or a DJI GPS which only needs one port, like OP GPS V9) you must:
- read https://librepilot.atlassian.net/wiki/display/LPDOC/Aux+Mag+Setup+and+Calibration
- really ... read it :)
- make a cable
- wait for the next release or build it yourself (I find build setup to be easy on a current Linux)

Re: Revo major drift in GPS flight mode
« Reply #9 on: April 12, 2016, 05:49:15 am »
Hi, I too am able to get "All Sensors Green" with GPS disabled. This includes Mag. The Mag is Green while GPS is Disabled. In fact I can enable GPS, set a light mode to use GPS assist and mag is still green and artificial horizon as flat, level and stable and correct. However Config Alarm is red now (while it was green before). When I click on it says that because I have selected a GPS assisted flight mode that I must also use INS13. So I change it from Complimentary to INS13 and this is where things go nuts. The artificial horizon is moving about and far from flat and level. The Atti and Mag alarms are now both Red :/ This is while Quad is stting on the bench not flying etc. Its like its trying to use the GPS on board compass or something.. maybe. i dunno. Eitherway, it looks pretty clear that the mag is well and trly calibrated. I can fly straight and level too, so long as GPS is not enabled. and I can still have gree Mag and Atti so long as INS13 is not selected (even with GPS enabled on main port).

So given that I have a green Mag and Atti, and that Artificial horizon and compass are all the way I would want them and I can fly straight and level (when GPS is NOT enabled) Doesn't this mean that something else is a miss here? It appears to be something to do with INS13. Is there something else I need to be selecting?

Should I post screenies or config files? If so. Should I post one from when GPS is NOT enabled (all sensors green), and then two from when GPS is enabled,  (but complimentary) then another with GPS enabled (but with INS13 enabled) coz it seems to only go to hell when INS13 is enabled. Cheers :D Hopefully this will help not only myself but all others who are experiencing the "Can fly with NO GPS, but when GPS enabled everything is crazy"

This is my GPS:

http://www.hobbyking.com/hobbyking/store/uh_viewItem.asp?idProduct=89565

This is my Revo:

http://www.hobbyking.com/hobbyking/store/uh_viewItem.asp?idProduct=89563

hwh

  • *
  • 1018
Re: Revo major drift in GPS flight mode
« Reply #10 on: April 12, 2016, 06:30:58 pm »
The gps you posted a link to doesn't seem to have the second connector necessary for it to have a usable mag sensor.  Have you taken it apart and verified that it actually has a mag sensor and soldered wires to connect it?  Some of the gps units that say they have a mag sensor but don't have the wire also don't have the sensor on the board.

The mag sensor is unused/ignored until you select INS13.  If you didn't connect a second wire to the gps then you're trying to use the revo's onboard mag sensor.   Much of the time they don't work reliably because of interference from the magnetic fields from power wires inside the quad.  There are posts in the forums about twisting all the wiring to minimize the interference but that doesn't always work.  That was the main reason for the external mag sensors.  Other than the no longer made GPS Platinum external mags only work if you are compiling and running the next branch of the code, release 15.09 doesn't support other external mags.

In order to fly with the gps modes you have to get the mag to green while INS13 is selected.  If you click on the red status in system health it will tell you why it's red.

Re: Revo major drift in GPS flight mode
« Reply #11 on: April 13, 2016, 11:16:07 am »
OK, cool thanks for that info. I have figured how to partially get round this issue by going in to System setting> Aux Mag and you have an option for Aux Mag, On board only and Both. Mine was selected on "both" Its now on "On Board only" The on board mag seems to function just fine. Infact. I have everything working well in terms of green lights now. the problem is that the artificial horizon is pitching and rolling and the compass drifting a little even when sitting on a flat, level, stable surface. but its doesn't do that when INS13 is not selected. So I would guess its something to do with the way the Data from sensors is fused together. I imagine these "oscillations" (For lack of a better word) can be tuned out with advanced settings, but I have some reading and learning to do on that subject I would say. However I think it may be within safe limits, it doesn't seem that bad. I guess the only way to know for sure is to test fly it. and try out position hold.

I will post more information a little later. my wife is yelling at me from across the house to take our Fish & Chips out of the over. lol. BBS

Re: Revo major drift in GPS flight mode
« Reply #12 on: April 14, 2016, 10:54:46 am »
Seeing as my Magnetometer is green and seems ok (apart from some very sligt and slow drift over time. I might take my issues into a different thread, as this thread is more related to magnetometer i think :)

Re: Revo major drift in GPS flight mode
« Reply #13 on: April 18, 2016, 06:55:14 am »
Hi there, I have just built a 250 with CC3D Revo and CC3d GPS module.

I have been able to get it up and steady without GPS enabled, telemetry is good, and all lights green. However as soon as GPS in enabled the motors hit full throttle with as little as 5% throttle and surge erratically, motor to motor.
I disable GPS and she goes back to a noisy little bee, happily scooting around. GPS on and its like a drug addict, no GPS and its all steady.

I have wiped it so many times, done all the configuring outside, clear skies for the GPS etc, and mag.

I have been flying for quite some time, APM, Naza etc, so I know my stuff, but it seems the CC3D Revo GPS is buggy and needs some development work.

I am so somewhat a bit more at ease to see I do not have a dud unit and that others have issues too, but it does seem to be symptomatic of a software development issue.
Naza and APM have it sorted, and as long as you follow the rules about magnetic interference, those systems play ball, but this is a bit different.
« Last Edit: April 18, 2016, 09:17:54 am by f5soh »

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Revo major drift in GPS flight mode
« Reply #14 on: April 18, 2016, 09:16:58 am »
Hi, welcome.

So you resolve all magnetic interference on your 250 sized quad ?

Please note CC3D and Revolution are two different boards.