Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GPS: Implement PLSV message for Locosys GPS #18013

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

tridge
Copy link
Contributor

@tridge tridge commented Jul 14, 2021

This adds vertical velocity support via PLSV message

@MallikarjunSE
Copy link
Contributor

MallikarjunSE commented Jul 28, 2021

Hey @tridge
I received the updated modules from Locosys. I tested 2 versions of MC1612. V3b is L1+L5(NavIC), V2b is L1+L5(GPS).
PLSV is working. EKF initializes normally without any errors. I tested these modules as dual GPS near my window. When I do CAN GPS order, I get Internal error 0x400. Without setting order it works fine. I'll try again outdoors tomorrow and share logs. One thing I noticed was HAcc, VAcc is broken. Can't see them on log. Can you have a look at the log once?
Thank you!
Link to Log: https://drive.google.com/file/d/1tFqikss2abQ55PD1zGqRlnY4F5qdJs5M/view?usp=sharing

@MallikarjunSE
Copy link
Contributor

Hey @tridge
Did some ground tests outside. I'm receiving 35 to 40 sats outside with 0.4 HDOP. Looks very promising considering the number of sats acquisition. But I'm getting internal error 0x400 sometimes. How do I check this error? If you could look at log and suggest me, I can put it on a copter and test fly.
Thank you!
Log: https://drive.google.com/file/d/1AjEc9ir9Hwxe2_Y8A7E4r-xkUCc_kuuo/view?usp=sharing

@tridge
Copy link
Contributor Author

tridge commented Aug 2, 2021

When I do CAN GPS order, I get Internal error 0x400

I've updated the PR to fix that. I wasn't handling NaN properly in the Fix2 message. Note that you will need both updated AP_Periph fw and updated main flight control fw.

One thing I noticed was HAcc, VAcc is broken

NMEA doesn't have HAcc and VAcc without a proprietary extension. The PLSV message gives speed accuracy (as NED), but not HAcc and VAcc. Is there some other message on the Locosys that has horizontal and vertical accuracy?

@MallikarjunSE
Copy link
Contributor

Hey @tridge
I test flew with previous PR. I get good satellite counts but EKF becomes unhealthy when I switch to any GPS modes. Wondering how EKF get initialized normally and becomes unhealthy during flight. The GPS and POS feels like its diverging. Currently the module outputs GNGGA, GNRMC, GNVTG, PLSV at 5Hz. Is there any output that's required for EKF?
Thank you!
https://drive.google.com/file/d/1Q8mYQZQitMmE1ZN1LEKZrqrRgrgHu_9D/view?usp=sharing
https://drive.google.com/file/d/12OOsGKm-t3gAnCouZzIRPR_M_H-0lWlK/view?usp=sharing

@MallikarjunSE
Copy link
Contributor

Locosys supports VAcc and HAcc via one more sentence GNEPE. But I'm yet to figure out way to enable it. I'll update you on this.
image

@MallikarjunSE
Copy link
Contributor

I tried switching from EKF3 to EKF2. But copter gets huge POS(Horizontal) and VEL variance.
Log: https://drive.google.com/file/d/1nK4k6vsJwRVfSEqVQtLsKcR4t5sTVEBB/view?usp=sharing

@tridge
Copy link
Contributor Author

tridge commented Aug 2, 2021

I test flew with previous PR.

could you fly with one u-blox GPS and one of the Locosys PLSV GPS? That would make it much easier to see what is going wrong.
I'd suggest using GPS_AUTO_SWITCH=0 and GPS_PRIMARY set to the u-blox. Then fly a cross pattern or similar.

@MallikarjunSE
Copy link
Contributor

MallikarjunSE commented Aug 3, 2021

Hey @tridge
Did couple of flights with Ublox M9N as primary GPS. Looks like locosys performance is very poor compared to ublox. Even though I see satellites upto 45+ and hdop of 0.4 and less, the performance looks just poor. Are we missing something in NMEA sentence? Is there a chance?
Thank you!
Log: https://drive.google.com/file/d/1zBS-qs24l0_joHCEwVnRaROnZL_PWPQw/view?usp=drivesdk
https://drive.google.com/file/d/19H8wuIZcFMfh1QARbHVkiudtcKS4g8uq/view?usp=sharing

@MallikarjunSE
Copy link
Contributor

Hey @tridge
Did few flights with Locosys MC1612V2b. Same performance as above. Even worse tbh!
As soon as I induce stick movement, I get huge POS and VEL errors!
Everything works perfect with M9N.
Logs folder: https://drive.google.com/drive/folders/1s4UJ9BGjrsHYBLibw4SsbPEWtV9nUNy9?usp=sharing

@tridge
Copy link
Contributor Author

tridge commented Aug 5, 2021

Did couple of flights with Ublox M9N as primary GPS. Looks like locosys performance is very poor compared to ublox. Even though I see satellites upto 45+ and hdop of 0.4 and less, the performance looks just poor.

it looks like the Locosys is applying a low frequency filter, much like if you were to configure a uBlox in pedestrian mode. Is there a setting for the internal filtering of the Locosys?

@MallikarjunSE
Copy link
Contributor

I have mounted GPS like this.
Uploading v8{a34fec7} (7bdf935d-3baa-45e6-9a27-434e4dfb01f5 id=0x7f0a03c0) …
Hey @tridge
I asked them and they couldn't answer whether they are using filters. They instead are pushing me to buy their own helical antenna and test. Which I felt is just waste of time and money. Its bad that we can't get good accuracy from 45+ sats but they want me to try with their antenna which receipts 60 sats. I'm not convinced that it's antenna issue!😅
Thanks for your time. Sorry we couldn't get good results out of this. I expected it to be good alternative during this ublox unavailability.

@tridge
Copy link
Contributor Author

tridge commented Aug 9, 2021

Thanks for your time. Sorry we couldn't get good results out of this. I expected it to be good alternative during this ublox unavailability.

no worries, it was worth a try, and might be fine on slow moving vehicles (mowers, tractors etc). Just no good for aircraft

@MallikarjunSE
Copy link
Contributor

Thanks for your time. Sorry we couldn't get good results out of this. I expected it to be good alternative during this ublox unavailability.

no worries, it was worth a try, and might be fine on slow moving vehicles (mowers, tractors etc). Just no good for aircraft

Yes, It was very noticeable. When I was flying in manual mode, any sharp movements would lead to GPS glitch, EKF going mad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants