Skip to content

Commit

Permalink
Merge pull request #572 from Dygmalab/erase_just_program
Browse files Browse the repository at this point in the history
fix: erase only firmware program and not ble data
  • Loading branch information
alexpargon authored Feb 16, 2024
2 parents 802c574 + 522d955 commit 3c2902a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/api/flash/defyFlasher/NRf52833-flasher.js
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,8 @@ const NRf52833 = {

//ERASE device
func_array.push(function (callback) {
write_cb(str2ab("E" + num2hexstr(dataObjects[0].address, 8) + "#"), callback);
//Max addres of firmware program is 0x00072000
write_cb(str2ab(`E${num2hexstr(dataObjects[0].address, 8)},${num2hexstr(0x00072000-dataObjects[0].address, 8)}#`), callback);
});
func_array.push(callback => {
read_cb(callback);
Expand Down

0 comments on commit 3c2902a

Please sign in to comment.