dji-sdk / Mobile-SDK-iOS

DJI Mobile SDK for iOS: http://developer.dji.com/mobile-sdk/
Other
579 stars 255 forks source link

Record and shutter buttons state always idle #190

Open NicolasPanhaleux opened 6 years ago

NicolasPanhaleux commented 6 years ago

Hi,

I'm using xcode 9.1 on iOS 11.1.2 device (iPhone 7+ / 8+), DJI mobile SDK 4.3.2, an Osmo and an Osmo mobile.

My goal is to know when the user press the record or/and the shutter button. For the Osmo, these buttons have a snapshot/record function and i can deal with it with system/media states. But for the Osmo mobile, these buttons only up the volume of the iPhone. I want to do the same functions snapshot/record in my video application.

The problem is on the Osmo mobile. I connect to the Osmo in bluetooth with a valid key and i'm succesfully registered. I cast my product as an DJIHandheld product to access the handheldController to receive buttons callbacks. I succesfully linked the handheldController(_ controller: DJIHandheldController, didUpdate state: DJIHandheldControllerHardwareState) callback cause i receive the state of the triggerButton when it's pressed. But when i press the record or shutter button, the recordAndShutterButtons state is always idle. I put logs in all cases of a switch and never saw anything else (even with breakpoints).

If you can please solve this fastly or show me what i missed it would be great :)

Thanks,

Nico.

lijia6745 commented 5 years ago

DJIHandheldControllerHardwareState is only support by Osmo Mobile.

Did you resolve your issue with new version? if not, pls report the issue to dev@dji.com it's the official channel to request DJI SDK support now.