NordicSemiconductor/IOS-DFU-Library

DFUServiceDelegate probelm

LucaDonetti opened this issue · 2 comments

I try to update a firmware with the library and use the same method of your example app:

self.dfuInitiator = DFUServiceInitiator(queue: DispatchQueue(label: "FirmwareUpdate"))
self.dfuInitiator?.delegate = self
self.dfuInitiator?.progressDelegate = self
self.dfuInitiator?.logger = self
self.dfuInitiator?.dataObjectPreparationDelay = 0.4
self.dfuInitiator?.packetReceiptNotificationParameter = 0

The problem is that I set the delegate and the delegateProcess, but they are nil into the DFUServiceSelector.
In DFUServiceInitiator: self.initiator.delegate is not nil, but in DFUServiceSelector: self.initiator.delegate is nil. For this
the callback for the state and the progress not work

How and why do you get access to DFUServiceSelector? The selector is started with the initiator instance so all the fields should be set as well, unless you set them back to nil of the self from your code was disposed.

Also, sorry for answering so late. I am busy with lots of projects and have missed your question. Did you manage to solve the issue? Can we close it?