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

How to check if compass is calibrated using iOS SDK #548

Open
douglaswsilva opened this issue Mar 17, 2023 · 1 comment
Open

How to check if compass is calibrated using iOS SDK #548

douglaswsilva opened this issue Mar 17, 2023 · 1 comment
Assignees

Comments

@douglaswsilva
Copy link

Hi,

During preflight check we want to make sure that the compass is calibrated. We were previously using DJICompassCalibrationState to do this check but realized that this measurement is only working during the actual calibration process of the vehicle.

Now we're trying to use DJICompassSensorState, but from the documentation it is not clear which states are valid and which states are not (by "valid" I mean states in which the drone is calibrated and will be able to fly).

Could you provide clarification if this is the right way to check for compass calibration, and on which states we will get from the SDK if the vehicle compass is not calibrated, and which values we will get when the vehicle is calibrated?

Thank you in advance, any help is very appreciated.

Screenshot 2023-03-17 at 11 20 13 PM

@DJI-William DJI-William self-assigned this Mar 20, 2023
@DJI-William
Copy link

If the compass is invalid and needs to calibrate, there will be a warning in DJIDiagnostics. Also, you can check the hasError property in DJICompass class to know if the current compass needs to be calibtrated.

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

No branches or pull requests

2 participants