This page describes an easy workaround for the flashing error you get in Keil uVision when you are using nRF5 SDK v16 on nRF52833 chips.
The assumption is that you have installed the latest versions of nRF MDK and nRF-Command-Line-Tools before applying this workaround.
When you configure/compile your project and try to flash your device using Keil on nRF52833, you will get the error below.
One reason to get this error could be because you have not configured the start address of your application in the IROM section. So please double check that you have the correct values which are shown below
If these are correct, then you can have two options.
Option 1)
- Download NordicSemiconductor.nRF_DeviceFamilyPack.8.27.1.pack and install this pack OR using pack installer like below
If you are familiar with Keil pack installer, then you can install this version 8.27.1 from the "Keil Pack Installer". - After you install NordicSemiconductor.nRF_DeviceFamilyPack.8.27.1.pack using either of the options mentioned above, then you need to change the project dependency on this pack as shown below
- click pack configurator
- Select the version 8.27.1 for the nRF_DeviceFamilyPack as shown below and click OK
- Now you should not get any error while flashing to nRF52833 in this SDK version.
- click pack configurator
Option 2) You can also do a small configuration change in the flash tool to use nrfjprog command-line tool to be used instead of the native Keil flashing tool.
- .Go to Project-> "Options for Target nRF528xx_xxaa"
- Then click the "Utilities" tab and select the "Use External Tool for Flash Programming"
- In the Command space, enter the full path of nrfjprog.exe.
- In the Arguments space, enter "--program #H --sectorerase -f nrf52 -r" without the quotes as shown below
- Click OK and flash the device using the flash button or Flash->Download. You will now see that nrfjprog is being used to flash to your nRF52833 based device.
Update
nRF MDK version 8.27.1 and 8.29.0 have this issue fixed. But the problem may still exist in MDK version 8.28.0.
We highly recommend you to use nRF MDK version 8.27.1 only when you are developing with SDKv16.0
Happy coding.