How should I resolve the issue "java.lang.NoClassDefFoundError: Failed resolution of: Ldji/v5/manager/interfaces/SDKManagerCallback" ?

Follow

Comments

2 comments

  • quentin garwig

    Hello, I still have this issue too.I'am calling  com.secneo.sdk.Helper.install and tried to run init() on the main thread. Is it possible the the error come from the connection to the DJI AppKey ? What kind of erro does it provide ?  Here is mine. 

    FATAL EXCEPTION: main
                                                                                                        Process: com.example.msdksample, PID: 29312
                                                                                                        java.lang.NoClassDefFoundError: Failed resolution of: Ldji/v5/manager/interfaces/SDKManagerCallback;
                                                                                                            at java.lang.Class.newInstance(Native Method)




    0
    Comment actions Permalink
  • Alexandr Sah

    Hello, don't know if you've fixed your error already. I've started with the sample example here and was getting the same error - https://developer.dji.com/doc/mobile-sdk-tutorial/en/quick-start/user-project-caution.html
    What helped me was to move this line from MyApplication ( it can possible be any file ) into MainActivity inside onCreate method.

    SDKManager.getInstance().init(this,object: SDKManagerCallback {

    From the first glance, https://github.com/dji-sdk/Mobile-SDK-Android-V5/blob/dev-sdk-main/SampleCode-V5/android-sdk-v5-sample/src/main/java/dji/sampleV5/aircraft/DJIApplication.kt

    You can try and move line 23 - msdkManagerVM.initMobileSDK(this) into MainActivity .
    Hope it helps, GL

    0
    Comment actions Permalink

Please sign in to leave a comment.

close