Skip to content

Conversation

simonbothen-radinn
Copy link

In some cases it is more convinient to use a binary or hex file directly instead of using a zip file.

We can check the extention and do the appropriate action.

@manualexSP
Copy link

I will have a look and do some tests in the next period. Thank you for contributing

@@ -38,7 +38,13 @@ public void startDFU(String address, String name, String filePath, Promise promi
starter.setDeviceName(name);
}
starter.setUnsafeExperimentalButtonlessServiceInSecureDfuEnabled(true);
starter.setZip(filePath);

if (filePath.endsWith(".bin") || filePath.endsWith(".hex")) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On iOS the extension check is case insensitive, but on Android it isn't. Wouldn't it be better to check against the filePath's toLowerCase()?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, fixed.

@mmesarosiuSP
Copy link

I've added your repo's branch as npm dependency, however on my Android 12 device it was crashing with your branch. I'm assuming because you don't have the Android 12 updates from this PR.
Instead I applied these changes on our repo and installed it as a local npm package and it was working properly.

@simonbothen-radinn
Copy link
Author

I've added your repo's branch as npm dependency, however on my Android 12 device it was crashing with your branch. I'm assuming because you don't have the Android 12 updates from this PR. Instead I applied these changes on our repo and installed it as a local npm package and it was working properly.

Thanks for the feedback. Will look into the above next week.

In some cases it is more convinient to use a binary
or hex file directly instead of using a zip file.

We can check the extention and do the appropriate action.
@simonbothen-radinn
Copy link
Author

I've added your repo's branch as npm dependency, however on my Android 12 device it was crashing with your branch. I'm assuming because you don't have the Android 12 updates from this PR. Instead I applied these changes on our repo and installed it as a local npm package and it was working properly.

Rebased to remotes HEAD.

@manualexSP manualexSP closed this Jun 28, 2023
@manualexSP
Copy link

Moved your implementation on this MR #6

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

Successfully merging this pull request may close these issues.

3 participants