Skip to content

KeyStartTakeoff leads to Take off failed: null error #552

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

Closed
SteliosPapamichail opened this issue Apr 22, 2025 · 1 comment
Closed

KeyStartTakeoff leads to Take off failed: null error #552

SteliosPapamichail opened this issue Apr 22, 2025 · 1 comment

Comments

@SteliosPapamichail
Copy link

We seem to be getting the following error when calling KeyStartTakeoff: Take off failed: null error where null is the error's description:

    fun takeOff(successCallback: () -> Unit = {}, errorCallback: () -> Unit = {}) {
        FlightControllerKey.KeyStartTakeoff.create().action(
            {
                successCallback()
                Timber.d("DJI/DroneControl:: Started take off")
            }, { e: IDJIError ->
                errorCallback()
                Timber.i("DJI/DroneControl:: Take off failed: ${e.description()}, ${e.errorCode()}")
            }
        )
    }

What could be the cause of this? In the docs I see that the motors should be off for this action to run? Could this mean that the motors are on?

@dji-dev
Copy link
Contributor

dji-dev commented Apr 23, 2025

Agent comment from YIGUI LIU in Zendesk ticket #140676:

Dear Developer,
Hello and thank you for reaching out to DJI Innovations.

The takeoff fails. It is possible that the sensor has not been initialized completely, or the positioning signal is poor, etc.

You can try to obtain the cause of the takeoff failure through FlightControllerKey.KeyMotorStartFailureError.

In addition, FlightControllerKey.KeyFlightMode and FlightControllerKey.KeyIsFlying can also be used to determine the status of the aircraft.

Best Regards,
DJI Innovations SDK Technical Support Team

°°°

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