npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

rn-nordic-mcu-fs-manager

v1.0.4

Published

React Native Nordic MCU Filesystem Manager

Readme

React Native Nordic MCU Filesystem Manager

React Native Nordic MCU Filesystem Manager (currently supports only download functionality)

Table of Contents

Installation in managed Expo projects

For managed Expo projects, please follow the installation instructions in the API documentation for the latest stable release. If you follow the link and there is no documentation available then this library is not yet usable within managed projects — it is likely to be included in an upcoming Expo SDK release.

Installation in bare React Native projects

For bare React Native projects, you must ensure that you have installed and configured the expo package before continuing.

Add the package to your npm dependencies

npm install rn-nordic-mcu-fs-manager

Configure for Android

No configuration needed.

Configure for iOS

Run npx pod-install after installing the npm package.

Usage

1. Import the Module

import RnNordicMcuFsManager from "rn-nordic-mcu-fs-manager";

2. Using the Module

Here's an example of how you can use the module in your application:


const App = () => {
  const fsManager = RnNordicMcuFsManager;

  const onDownloadProgressChanged = (progress: number) => {
    console.log("Progress: ", progress);
  };
  const onDownloadFailed = (error: string) => {
    console.log("Failed: ", error);
  };
  const onDownloadCanceled = () => {
    console.log("Canceled");
  };
  const onDownloadCompleted = (bytearray: number[]) => {
    fsManager.destroy();
    const result = String.fromCharCode(...bytearray);
    console.log("Completed", result);
  };

  return (
    <View>
      <Button
        title="Download File"
        onPress={async () => {
          try {
            fsManager.initialize(deviceId);
            fsManager.fileDownload(
              "/lfs1/Lorem_1000.txt",
              onDownloadProgressChanged,
              onDownloadFailed,
              onDownloadCanceled,
              onDownloadCompleted,
            );
          } catch (error) {
            console.error(error);
          }
        }}
      />
    </View>
  );
};

export default App;

Make sure to check the documentation for all available functions and their expected usage.


API Documentation

Methods

Initialize

initialize(bleId: string)

Description: Creates a connection with the bluetooth device and initializes a filesystem manager module.

Parameters:

  • bleId (string): For Android the device's mac address, for iOS the device's UUID

Destroy

destroy()

Description: Closes the connection with the bluetooth device and releases all the native modules.


File Download

fileDownload(filePath: string, onDownloadProgressChanged: function, onDownloadFailed: function, onDownloadCanceled: function, onDownloadCompleted: function)

Description:
Initiates a file download operation from the specified filePath. The method provides various callbacks to handle download progress, failure, cancellation, and completion.

Parameters:

  • filePath (string):
    The path to the file that you want to download (e.g., "/lfs1/Lorem_1000.txt").

  • onDownloadProgressChanged (function):
    A callback function that will be called with the current download progress (e.g., onDownloadProgressChanged(progress)), where progress is a number between 0 and 100.

  • onDownloadFailed (function):
    A callback function that will be called if the download fails. It receives an error message as a parameter (e.g., onDownloadFailed(error)).

  • onDownloadCanceled (function):
    A callback function that will be called if the download is canceled. It receives no parameters (e.g., onDownloadCanceled()).

  • onDownloadCompleted (function):
    A callback function that will be called when the download is completed successfully. It receives the downloaded byte array and must be converted to string (e.g., onDownloadCompleted(byteArray)).

Contributing

Contributions are very welcome! Please refer to guidelines described in the contributing guide.

Run the module locally

git clone [email protected]:coded-lines/rn-nordic-mcu-fs-manager.git && cd rn-nordic-mcu-fs-manager && npm install && cd example && npm install && cd ios && npx pod-install && cd .. && npx expo prebuild

Credits

This project is heavily inspired by and takes code from react-native-mcu-manager