Getting "CRC does not match!" in nRF Connect iOS mobile application

I am trying to integrate GitHub - NordicSemiconductor/IOS-DFU-Library: OTA DFU Library for Mac and iOS, compatible with nRF5x SoCs library in one of the SwiftUI mobile application. The integration was easy due to really well documentation instructions on the library page. 

I went ahead and tried to load my ZIP file, but it gave me "CRC does not match!" error in the logs, and then DFU process just stuck at aero progress.

Then I tried to load DFU using your app, which is currently on AppStore - nRF Connect for Mobile on the App Store (apple.com), but I got the same log

I am trying to integrate GitHub - NordicSemiconductor/IOS-DFU-Library: OTA DFU Library for Mac and iOS, compatible with nRF5x SoCs (v4.11.1) pod library in one of the SwiftUI mobile application project. The integration was seamless due to really well documentation instructions on the library page. 

I went ahead and tried to load my ZIP file, but it gave me "CRC does not match!" error in the logs, and then DFU process just stuck at zero progress.

Then I tried to load DFU using your app, which is currently on AppStore - nRF Connect for Mobile on the App Store (apple.com), but I got the same error in log (attached TXT version log from nRF iOS app)

File Name: myDfuFile.zip
Parts: 1
Size: 118 KB
Soft Device Size: Zero KB
Bootloader Size: Zero KB
[Callback] Central Manager did update state to: Powered ON
Connecting to ABDC617280049...
centralManager.connect(peripheral, options: nil)
[Callback] Central Manager did connect peripheral
Connected to ABCD617280049
Discovering services...
peripheral.discoverServices(nil)
Services discovered
Starting Secure DFU...
Connected to ABCD617280049
Services discovered
Secure DFU Service found
Discovering characteristics in DFU Service...
peripheral.discoverCharacteristics(nil, for: FE59)
DFU characteristics discovered
MTU set to 43
Enabling notifications for 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.setNotifyValue(true, for: 8EC90001-F315-4F60-9FB8-838830DAEA50)
Notifications enabled for 8EC90001-F315-4F60-9FB8-838830DAEA50
Secure DFU Control Point notifications enabled
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x0601, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 600601000100000000000000000000
Command object selected (Max size = 256, Offset = 0, CRC = 00000000) received
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x010143000000, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 600101
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x020000, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 600201
Packet Receipt Notif disabled (Op Code = 2, Value = 0)
Writing to characteristic 8EC90002-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x0a410801123d080110888ef9371a028c0120002800300038b097074224080312203d06d39007b6f8, for: 8EC90002-F315-4F60-9FB8-838830DAEA50, type: .withoutResponse)
Writing to characteristic 8EC90002-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0xb6af2ee12083d0e564d22e9a734e6d00201d98841f830d4a604800, for: 8EC90002-F315-4F60-9FB8-838830DAEA50, type: .withoutResponse)
Command object sent (CRC = AAF6B2D4)
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x03, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 6003010000000000000000
Checksum (Offset = 0, CRC = 00000000) received
CRC does not match! Retrying...
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x010143000000, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 600101
Writing to characteristic 8EC90002-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x0a410801123d080110888ef9371a028c0120002800300038b097074224080312203d06d39007b6f8, for: 8EC90002-F315-4F60-9FB8-838830DAEA50, type: .withoutResponse)
Writing to characteristic 8EC90002-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0xb6af2ee12083d0e564d22e9a734e6d00201d98841f830d4a604800, for: 8EC90002-F315-4F60-9FB8-838830DAEA50, type: .withoutResponse)
Command object sent (CRC = AAF6B2D4)
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x03, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 6003010000000000000000
Checksum (Offset = 0, CRC = 00000000) received
CRC does not match! Retrying...
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x010143000000, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 600101
Writing to characteristic 8EC90002-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x0a410801123d080110888ef9371a028c0120002800300038b097074224080312203d06d39007b6f8, for: 8EC90002-F315-4F60-9FB8-838830DAEA50, type: .withoutResponse)
Writing to characteristic 8EC90002-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0xb6af2ee12083d0e564d22e9a734e6d00201d98841f830d4a604800, for: 8EC90002-F315-4F60-9FB8-838830DAEA50, type: .withoutResponse)
Command object sent (CRC = AAF6B2D4)
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x03, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50
Notification received from 8EC90001-F315-4F60-9FB8-838830DAEA50, value (0x): 6003010000000000000000
Checksum (Offset = 0, CRC = 00000000) received
CRC does not match!
Writing to characteristic 8EC90001-F315-4F60-9FB8-838830DAEA50...
peripheral.writeValue(0x0c, for: 8EC90001-F315-4F60-9FB8-838830DAEA50, type: .withResponse)
Data written to 8EC90001-F315-4F60-9FB8-838830DAEA50

I also tried nRF Connect Android app from Play Store, with same BLE device and same ZIP file, it worked!

I am not sure why iOS DFU library or nRF Connect iOS app giving CRC error.

Any help would be appreciated.

I have tested this on iPod Touch (iOS 14.8)

Parents
  • Hi Meet,

    Can you confirm the following questions?

    1) DFU for hrs_application_s132.zip works on nRF Connect for Mobile - nordicsemi.com(both iOS and Android) and your SwiftUI mobile application?

    2) zip file from your firmware engineer report "CRC Does not match!" on nRF Connect for Mobile - nordicsemi.com(both iOS and Android) and your SwiftUI mobile application?

    3) If 1) 2) is correct, can you ask your firmware engineer to share more details on the zip file generation process? so I can repeat the issue on my side to find the cause.

    4) CRC check is an important process to make sure your application zip file is not broken during transmission or modified by someone on purpose. You should not avoid CRC check for any reason. Since the library already provides source codes, I suggest you read the source codes to learn details on the DFU process.

    Best regards,

    Charlie

     

  • Hi Charlie,

    Below are the answers for your questions:

    1. DFU for hrs_application_s132.zip works on nRF Connect for Mobile - nordicsemi.com(both iOS and Android) and your SwiftUI mobile application?
      Yes, I tested hrs_application_s132.zip on both nRF apps on iOS and Android; and it works perfect.

    2. zip file from your firmware engineer report "CRC Does not match!" on nRF Connect for Mobile - nordicsemi.com(both iOS and Android) and your SwiftUI mobile application?
      Correct.

    3. If 1) 2) is correct, can you ask your firmware engineer to share more details on the zip file generation process? so I can repeat the issue on my side to find the cause.
      Ok, I will ask them.

    4. CRC check is an important process to make sure your application zip file is not broken during transmission or modified by someone on purpose. You should not avoid CRC check for any reason. Since the library already provides source codes, I suggest you read the source codes to learn details on the DFU process.
      Ok, thank you for letting me know. I will check it.
Reply
  • Hi Charlie,

    Below are the answers for your questions:

    1. DFU for hrs_application_s132.zip works on nRF Connect for Mobile - nordicsemi.com(both iOS and Android) and your SwiftUI mobile application?
      Yes, I tested hrs_application_s132.zip on both nRF apps on iOS and Android; and it works perfect.

    2. zip file from your firmware engineer report "CRC Does not match!" on nRF Connect for Mobile - nordicsemi.com(both iOS and Android) and your SwiftUI mobile application?
      Correct.

    3. If 1) 2) is correct, can you ask your firmware engineer to share more details on the zip file generation process? so I can repeat the issue on my side to find the cause.
      Ok, I will ask them.

    4. CRC check is an important process to make sure your application zip file is not broken during transmission or modified by someone on purpose. You should not avoid CRC check for any reason. Since the library already provides source codes, I suggest you read the source codes to learn details on the DFU process.
      Ok, thank you for letting me know. I will check it.
Children
No Data
Related