wanted to do dfu ota from.net maui

hi there i hope you are doing fine and best of your health. actually i am developing the custom app to communicate with nrf 52840 soc device through bluetooth, which is working fine at the moment. now i wanted to perform dfu.. so can you please tell me any compatible library for that. plus i currently u am using Laerdal.Dfu but it gives error as soon as i upload the zip file and log returns this 


[DOTNET] File selected: /data/data/com.companyname.bluetoothcourse/cache/2203693cc04e0be7f4f024d5f9499e13/1c8e89218872463aa3de5e71a30f02d6/dfu_application.zip
[0:] File path exists: True
[0:] Attempting to start DFU process...
[ViewRootImpl@69f7d86[IntermediateActivity]] stopped(false) old=true
[ViewRootImpl@69f7d86[IntermediateActivity]] stopped(false) old=false
[SurfaceControl] assignNativeObject: nativeObject = 0 Surface(name=null)/@0x3f2fe3 / android.view.SurfaceControl.readFromParcel:1121 android.view.IWindowSession$Stub$Proxy.relayout:1830 android.view.ViewRootImpl.relayoutWindow:9005 android.view.ViewRootImpl.performTraversals:3360 android.view.ViewRootImpl.doTraversal:2618 android.view.ViewRootImpl$TraversalRunnable.run:9971 android.view.Choreographer$CallbackRecord.run:1010 android.view.Choreographer.doCallbacks:809 android.view.Choreographer.doFrame:744 android.view.Choreographer$FrameDisplayEventReceiver.run:995
[SurfaceControl] assignNativeObject: nativeObject = 0 Surface(name=null)/@0x5cb7647 / android.view.SurfaceControl.readFromParcel:1121 android.view.IWindowSession$Stub$Proxy.relayout:1840 android.view.ViewRootImpl.relayoutWindow:9005 android.view.ViewRootImpl.performTraversals:3360 android.view.ViewRootImpl.doTraversal:2618 android.view.ViewRootImpl$TraversalRunnable.run:9971 android.view.Choreographer$CallbackRecord.run:1010 android.view.Choreographer.doCallbacks:809 android.view.Choreographer.doFrame:744 android.view.Choreographer$FrameDisplayEventReceiver.run:995
[ViewRootImpl@69f7d86[IntermediateActivity]] Relayout returned: old=(0,0,1080,2340) new=(0,0,1080,2340) req=(1080,2340)4 dur=11 res=0x1 s={false 0} ch=false fn=-1
[bluetoothcours] Explicit concurrent copying GC freed 22003(1059KB) AllocSpace objects, 10(624KB) LOS objects, 49% free, 5051KB/10102KB, paused 110us total 34.109ms
[ViewRootImpl@3983e16[MainActivity]] stopped(false) old=true
[System] A resource failed to call close.
[System] A resource failed to call close.
[ViewRootImpl@3983e16[MainActivity]] stopped(false) old=false
[SurfaceControl] assignNativeObject: nativeObject = 0 Surface(name=null)/@0x3a32195 / android.view.SurfaceControl.readFromParcel:1121 android.view.IWindowSession$Stub$Proxy.relayout:1840 android.view.ViewRootImpl.relayoutWindow:9005 android.view.ViewRootImpl.performTraversals:3360 android.view.ViewRootImpl.doTraversal:2618 android.view.ViewRootImpl$TraversalRunnable.run:9971 android.view.Choreographer$CallbackRecord.run:1010 android.view.Choreographer.doCallbacks:809 android.view.Choreographer.doFrame:744 android.view.Choreographer$FrameDisplayEventReceiver.run:995
[ViewRootImpl@3983e16[MainActivity]] Relayout returned: old=(0,0,1080,2340) new=(0,0,1080,2340) req=(1080,2340)0 dur=20 res=0x7 s={true 488039866368} ch=true fn=-1
[DfuBaseService] DFU service created. Version: 2.3.0
Thread started: #17
[0:] DFU process started successfully.
[SurfaceControl] assignNativeObject: nativeObject = 0 Surface(name=null)/@0x3f2fe3 / android.view.SurfaceControl.readFromParcel:1121 android.view.IWindowSession$Stub$Proxy.relayout:1830 android.view.ViewRootImpl.relayoutWindow:9005 android.view.ViewRootImpl.performTraversals:3360 android.view.ViewRootImpl.doTraversal:2618 android.view.ViewRootImpl$TraversalRunnable.run:9971 android.view.Choreographer$CallbackRecord.run:1010 android.view.Choreographer.doCallbacks:809 android.view.Choreographer.doFrame:744 android.view.Choreographer$FrameDisplayEventReceiver.run:995
[SurfaceControl] assignNativeObject: nativeObject = 0 Surface(name=null)/@0x5cb7647 / android.view.SurfaceControl.readFromParcel:1121 android.view.IWindowSession$Stub$Proxy.relayout:1840 android.view.ViewRootImpl.relayoutWindow:9005 android.view.ViewRootImpl.performTraversals:3360 android.view.ViewRootImpl.doTraversal:2618 android.view.ViewRootImpl$TraversalRunnable.run:9971 android.view.Choreographer$CallbackRecord.run:1010 android.view.Choreographer.doCallbacks:809 android.view.Choreographer.doFrame:744 android.view.Choreographer$FrameDisplayEventReceiver.run:995
[ViewRootImpl@69f7d86[IntermediateActivity]] Relayout returned: old=(0,0,1080,2340) new=(0,0,1080,2340) req=(1080,2340)8 dur=10 res=0x1 s={false 0} ch=false fn=-1
[ViewRootImpl@3983e16[MainActivity]] MSG_WINDOW_FOCUS_CHANGED 1 1
[InputMethodManager] prepareNavigationBarInfo() DecorView@9dac42e[MainActivity]
[InputMethodManager] getNavigationBarColor() -855310
[InputMethodManager] prepareNavigationBarInfo() DecorView@9dac42e[MainActivity]
[InputMethodManager] getNavigationBarColor() -855310
[InputMethodManager] Starting input: tba=com.companyname.bluetoothcourse ic=null mNaviBarColor -855310 mIsGetNaviBarColorSuccess true , NavVisible : true , NavTrans : false
[InputMethodManager] startInputInner - Id : 0
[InputMethodManager] startInputInner - mService.startInputOrWindowGainedFocus
[InputTransport] Input channel constructed: 'ClientS', fd=91
[SurfaceControl] nativeRelease nativeObject s[488271482528]
[SurfaceControl] nativeRelease nativeObject e[488271482528]
[SurfaceControl] nativeRelease nativeObject s[488271482432]
[SurfaceControl] nativeRelease nativeObject e[488271482432]
[DfuBaseService] Starting DFU service in foreground
[ViewRootImpl@69f7d86[IntermediateActivity]] dispatchDetachedFromWindow
[InputTransport] Input channel destroyed: '755b839', fd=86
[DfuArchiveInputStream] Manifest failed to be parsed. Did you add
[DfuArchiveInputStream] -keep class no.nordicsemi.android.dfu.** { *; }
[DfuArchiveInputStream] to your proguard rules?
[DfuBaseService] An exception occurred while calculating file size
[DfuBaseService] java.io.IOException: The ZIP file must contain an Application, a Soft Device and/or a Bootloader.
[DfuBaseService] at no.nordicsemi.android.dfu.internal.ArchiveInputStream.<init>(ArchiveInputStream.java:269)
[DfuBaseService] at no.nordicsemi.android.dfu.DfuBaseService.openInputStream(DfuBaseService.java:1457)
[DfuBaseService] at no.nordicsemi.android.dfu.DfuBaseService.onHandleIntent(DfuBaseService.java:1201)
[DfuBaseService] at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:77)
[DfuBaseService] at android.os.Handler.dispatchMessage(Handler.java:106)
[DfuBaseService] at android.os.Looper.loop(Looper.java:246)
[DfuBaseService] at android.os.HandlerThread.run(HandlerThread.java:67)
Thread finished: #17
[DfuBaseService] DFU service destroyed

Parents Reply Children
  • but it still throwing this exception which i am not been able to understand or fix it 

    [DfuArchiveInputStream] Manifest failed to be parsed. Did you add
    [DfuArchiveInputStream] -keep class no.nordicsemi.android.dfu.** { *; }
    [DfuArchiveInputStream] to your proguard rules?
    [DfuBaseService] An exception occurred while calculating file size
    [DfuBaseService] java.io.IOException: The ZIP file must contain an Application, a Soft Device and/or a Bootloader.
    [DfuBaseService] at no.nordicsemi.android.dfu.internal.ArchiveInputStream.<init>(ArchiveInputStream.java:269)
    [DfuBaseService] at no.nordicsemi.android.dfu.DfuBaseService.openInputStream(DfuBaseService.java:1457)
    [DfuBaseService] at no.nordicsemi.android.dfu.DfuBaseService.onHandleIntent(DfuBaseService.java:1201)
    [DfuBaseService] at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:77)
    [DfuBaseService] at android.os.Handler.dispatchMessage(Handler.java:106)
    [DfuBaseService] at android.os.Looper.loop(Looper.java:246)
    [DfuBaseService] at android.os.HandlerThread.run(HandlerThread.java:67)

  • Hi,

    Reading the bold text I suspect you are not using a valid zip file? But again, this library is not made by us nor have we worked with it, so I am not able to say anything specific, unfortunately.

Related