Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
extension MapViewController: DJISDKManagerDelegate {
func appRegisteredWithError(_ error: Error?) {
if let error = error {
print(error.localizedDescription)
} else {
DJISDKManager.startConnectionToProduct()
}
}
func productConnected(_ product: DJIBaseProduct?) {
if let _ = product {
if DJISDKManager.product()!.isKind(of: DJIAircraft.self) {
let flightController = (DJISDKManager.product()! as! DJIAircraft).flightController!
flightController.delegate = self
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.