nordic_dfu_web 0.0.7 copy "nordic_dfu_web: ^0.0.7" to clipboard
nordic_dfu_web: ^0.0.7 copied to clipboard

Platformweb

Flutter Plugin to Update Device Firmware (DFU) of your nrf51 or nrf52 chip from Nordic Semiconductor

nordic_dfu_web #

This library allows you to do a Device Firmware Update (DFU) of your nrf51 or nrf52 chip from Nordic Semiconductor from Flutter Web

Getting started #

add this package to pubspec.yaml file

nordic_dfu_web: 0.0.7
copied to clipboard

add this script tag in web/index.html file inside of head tag (check example folder)

<script src="./assets/packages/nordic_dfu_web/assets/ble.js" defer></script>
copied to clipboard

Features #

To Start Dfu Pic a file by using any File Picker Plugin and convert File to buffer pass that buffer to this method and start DFU

Note: startDfu will open dialog to choose for a Device if , that device is already in Dfu mode , then it will start transferring firmware else ,first device will be booted to Dfu and and it will throw an error, and increase dfuDelay if getting any issue while transferring to add filters , pass a list of requestBuilderFilter object if passed an empty list , all devices will be shown in request builder

    await NordicDfuWeb.startDfu(
      uint8list: bytes,
      requestBuilderFilters: [],
      dfuDelay: 25,
      onProgress: (progress) {
        print(progress);
      },
      onComplete: (data) {
       print(data);
      },
      onError: (err) {
       print(err);
      },
      onLogs: (logs) {
        print(logs);
      },
    );
copied to clipboard

TODO #

Host example

Usage #

Added longer examples to /example folder.

Resources #

Additional information #

This is Just The Initial Version feel free to Contribute or Report any Bug!

5
likes
140
points
25
downloads

Publisher

verified publisherrohitsangwan.in

Weekly Downloads

2024.07.05 - 2025.01.17

Flutter Plugin to Update Device Firmware (DFU) of your nrf51 or nrf52 chip from Nordic Semiconductor

Repository (GitHub)

Documentation

API reference

License

MIT (license)

Dependencies

flutter, flutter_web_plugins, js

More

Packages that depend on nordic_dfu_web