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

Onboard compass call over WiFi/UDP link does not send progress messages #5505

Closed
DonLakeFlyer opened this issue Jan 5, 2017 · 38 comments
Closed
Assignees
Milestone

Comments

@DonLakeFlyer
Copy link
Contributor

Using ArduCopter stable 3.4.3 if I do an onboard compass cal over usb connection it all works fine. But if I try the exact same thing over a UDP connection the MAG_CAL_PROGRESS/MAG_CAL_REPORT messages are never sent to the groundstation. The vehicle is in onboard cal mode since I can hear it beeping like it does when doing onboard cal. It just doesn't report progress.

@WickedShell
Copy link
Contributor

WickedShell commented Jan 5, 2017 via email

@DonLakeFlyer
Copy link
Contributor Author

It's a PixRacer with the ESP8266 thingy. I assume that is how it is connected. Not much of a hardware person. Phillip Rowse built it for me.

@WickedShell
Copy link
Contributor

WickedShell commented Jan 6, 2017 via email

@proficnc
Copy link
Contributor

proficnc commented Jan 6, 2017

Phillip K? Maybe?

@DonLakeFlyer
Copy link
Contributor Author

Teehee. Yeah, Thanks to the proficnc guys.

@OXINARF
Copy link
Member

OXINARF commented Jan 10, 2017

Is this solved? If I heard correctly, @lvale said in the dev call that everything is working.

@lvale
Copy link
Member

lvale commented Jan 10, 2017

can't test again for 3 days, rebuilding racing quad :)

@DonLakeFlyer
Copy link
Contributor Author

I just tried it again with the same results. I tried debugging firmware myself but QGC won't run against laster master ArduCopter since it sends MAV_TYPE=0 in heartbeat on flash.

@lvale
Copy link
Member

lvale commented Jan 11, 2017

Just finished testing. with Copter 3.4.3 and QGC initiates onboard cal and on wifi no feedback, while on usb there's the progress bar at the top and when finished the "health" displays.

Tested with latest master
screen shot 2017-01-11 at 20 46 31
compass_cal ardupilot.mavlink.zip

@peterbarker
Copy link
Contributor

I've just tested with MAVProxy and both Plane and Copter firmwares running over esp8266 worked as expected.

I'm compiling QGC to see how it behaves.

@DonLakeFlyer
Copy link
Contributor Author

The real test is with Mission Planner over WiFi. I can seem to get that to work in my Windows VM so I can't test it myself. MAVProxy tends to do strange things since it isn't the same as a direct QGC connection. At least that has been my experience using it with SITL.

@OXINARF
Copy link
Member

OXINARF commented Jan 22, 2017

I just tested the Bebop2 (which uses UDP over Wifi) with MP and it works.
The Wifi interface in the Pixracer is a simple serial connection so it should work. Can you check your SERIAL5_PROTOCOL and SERIAL5_BAUD parameters? They should be 1 and 921 (or 921600) respectively.

@proficnc
Copy link
Contributor

Did this on a solo last night, progress bar worked fine on mission planner.

@lvale
Copy link
Member

lvale commented Jan 22, 2017

screen shot 2017-01-22 at 22 32 37

screen shot 2017-01-22 at 22 33 08

screen shot 2017-01-22 at 22 36 06

@OXINARF
Copy link
Member

OXINARF commented Jan 22, 2017

What is the difference between Bridge/QGC and QGC/Bridge?
Are those packet counters from forever or just since boot? Either way, that's very high packet loss.

@lvale
Copy link
Member

lvale commented Jan 23, 2017

those are cumulative. I should have reset'em before the screenshot, because includes losses from powering on/off the drone

@OXINARF
Copy link
Member

OXINARF commented Jan 23, 2017

Ok. What is the SR3_EXTRA3 value?

@DonLakeFlyer
Copy link
Contributor Author

@lvale Did you try PixRacer+WiFI+MP combination on same vehicle that failed with QGC? I couldn't test that myself. Seems weird it could be QGC only problem, but certainly possible.

@lvale
Copy link
Member

lvale commented Jan 23, 2017

@DonLakeFlyer Same issue with MP latest beta, so it's not a QGC only issue

@OXINARF
1untitled

@OXINARF
Copy link
Member

OXINARF commented Jan 24, 2017

All looks OK. Without having a Pixracer with a ESP8266 it's hard to help more. Two suggestions I can make are:

  • check if you receive MSG_EKF_STATUS_REPORT and MSG_VIBRATION messages
  • try to connect a normal radio to the Wifi pins and see if the same happens. If it does, it sure is an ArduPilot issue, if it doesn't, then it is an issue with the ESP8266 firmware

@OXINARF
Copy link
Member

OXINARF commented Feb 11, 2017

http://discuss.ardupilot.org/t/esp8266-wifi-on-pixhawk/14681/13?u=oxinarf

@DonLakeFlyer @lvale Please try to update your ESP8266 firmware and check if you still don't receive the compass calibration messages.

@DonLakeFlyer
Copy link
Contributor Author

I flashed the latest firmware and now it's not working at all. Going to take me a bit to recover from that!

@WickedShell
Copy link
Contributor

WickedShell commented Feb 19, 2017 via email

@DonLakeFlyer
Copy link
Contributor Author

I"m talking about flashing ESP8266 firmware, not ardupilot firmware. For ardupilot I've been testing with Copter.

@WickedShell
Copy link
Contributor

WickedShell commented Feb 19, 2017 via email

@DonLakeFlyer
Copy link
Contributor Author

DonLakeFlyer commented Feb 19, 2017

You were completing onboard cals with a PixRacer+ESP+QGC?

@WickedShell
Copy link
Contributor

WickedShell commented Feb 19, 2017 via email

@DonLakeFlyer
Copy link
Contributor Author

@WickedShell On your GCS do you specific individual compass bits in MAV_CMD_DO_START_MAG_CAL or do you specify all using =0? That's the only possible difference I can think of.

@DonLakeFlyer
Copy link
Contributor Author

DonLakeFlyer commented Feb 19, 2017

My call is like this:

            _vehicle->sendMavCommand(_vehicle->defaultComponentId(),
                                     MAV_CMD_DO_START_MAG_CAL,
                                     true,          // showError
                                     compassBits,   // which compass(es) to calibrate
                                     0,             // no retry on failure
                                     1,             // save values after complete
                                     0,             // no delayed start
                                     0);            // no auto-reboot

Where compassBits has the first three compasses turned on. compassBits is param1, with the rest param2, ...

@WickedShell
Copy link
Contributor

WickedShell commented Feb 19, 2017 via email

@DonLakeFlyer
Copy link
Contributor Author

Could you change your code to pass in the same settings as QGC (3 bits and no retyr) and see if it still works?

@DonLakeFlyer
Copy link
Contributor Author

Since I toasted my Pixracer WiFi I'm dead in the water till I figure out how to revive it.

@WickedShell
Copy link
Contributor

Status update from testing today: With master copter I couldn't begin a compass calibration over ESP8266 with Mission Planner, QGC or my GCS. However I could preform a compass calibration over USB with both MP and my GCS. (QGC was not tested with copter over USB)

With Plane however I could initiate a compass calibration over the ESP8266 on the same version. I'm not really sure what to make of that.

@peterbarker
Copy link
Contributor

If you could try 026c65d3646b0f5671bf5c5a7d58c5d2cc82844c then try 026c65d3646b0f5671bf5c5a7d58c5d2cc82844c^ to see if you see the same thing that would be great.

Note you'll want a git submodule update between as it is a submodule commit in question.

@DonLakeFlyer
Copy link
Contributor Author

FYI: My pixracer WiFi is down for the count right now. I tried flashing a new firmware and it bricked it. Waiting for a breakout board thingy so I can flash firmware over FTDI. Hopefully @lvale can help out with testing until then. I'm probably a couple weeks away from getting my thing from china I need.

@peterbarker
Copy link
Contributor

@DonLakeFlyer Was your attempted update via the "update" webpage it offers? That also soft-bricked mine...

@DonLakeFlyer
Copy link
Contributor Author

@peterbarker Yes it was.
@dogmaphobic So not just me with bad experience on firmware flash. LIkely something wrong there.

@peterbarker
Copy link
Contributor

No worries starting compass calibration now :-)

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

No branches or pull requests

7 participants