Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Firmware File not found - iOS #182

Open
suryakant-patil opened this issue Mar 3, 2023 · 3 comments
Open

Firmware File not found - iOS #182

suryakant-patil opened this issue Mar 3, 2023 · 3 comments

Comments

@suryakant-patil
Copy link

HI,
I am getting the error after starting the DFU process for firmware file not found.
I have confirmed the firmware file is attached to the process.
Please help me to resolve above issue on iOS

React Native version: 0.63.3

@Nickolans
Copy link

@suryakant-patil Did you find a solution to this?

@suryakant-patil
Copy link
Author

@Nickolans, not yet. Sometimes it works, and sometimes it does not.

@Devojha408
Copy link

Devojha408 commented Sep 12, 2023

@suryakant-patil try like this:

const destination = `${RNFS.DocumentDirectoryPath}/installationFile.zip`;
const exists = await RNFS.exists(destination);
exists && (await RNFS.unlink(destination));
const response = await ReactNativeBlobUtil.config({
  fileCache: true,
  appendExt: 'zip',
}).fetch('GET', firmwareUrl);

const downloadPath = response.path();
await RNFS.copyFile(downloadPath, destination);
response?.flush();

NordicDFU.startDFU({
  deviceAddress: device.id,
  name: device.advertising.localName,
  filePath:
    Platform.OS === 'ios'
      ? `file://${destination}`
      : destination
      });

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants