nrf_ble_dfu 0.0.17 copy "nrf_ble_dfu: ^0.0.17" to clipboard
nrf_ble_dfu: ^0.0.17 copied to clipboard

The Nordic DFU over BLE library helps enable firmware updates of BLE devices over Bluetooth Low Energy (BLE), for Windows, Android, iOS, Linux and macOS.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:nrf_ble_dfu/nrf_ble_dfu.dart';

Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();
  await NrfBleDfu().waitForCompletion();
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return const MaterialApp(
      debugShowCheckedModeBanner: false,
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key});

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  @override
  Widget build(BuildContext context) {
    const div = Divider(height: 0);
    const children = [
      DfuFileSelect(),
      BleEntrySetup(),
      AutoBleDfu(),
      BleConnectedDevice(),
      DfuProgress(),
      BleDeviceSelect(),
    ];
    return SafeArea(
      child: Scaffold(
        body: ListView.separated(
          itemCount: children.length,
          separatorBuilder: (_, __) => div,
          itemBuilder: (context, index) => children[index],
        ),
      ),
    );
  }
}
4
likes
120
points
108
downloads

Publisher

unverified uploader

Weekly Downloads

The Nordic DFU over BLE library helps enable firmware updates of BLE devices over Bluetooth Low Energy (BLE), for Windows, Android, iOS, Linux and macOS.

Repository (GitHub)
View/report issues

Topics

#nordic #nrf #ble #dfu

Documentation

API reference

License

MIT (license)

Dependencies

archive, file_picker, flutter, flutter_blue_plus_windows, flutter_mobx, mobx, path, path_provider, permission_handler, shared_preferences

More

Packages that depend on nrf_ble_dfu