Feedback
Feedback

If you are having issues with the exercises, please create a ticket on DevZone: devzone.nordicsemi.com
Click or drag files to this area to upload. You can upload up to 2 files.

Bootloader basics

The first three topics on Bootloaders and DFU will cover general bootloader and DFU concepts.

To begin this step-by-step look at how a bootloader works, starting from non-volatile memory.

As a starting note, remember that while related, the Bootloader and Device Firmware Updates (DFU) are different.

Non-volatile memory

Memory that is not erased when a chip is power cycled is called non-volatile memory. This memory is ordered into 32-bit registers on nRF chips. We will illustrate this as such:

All Nordic Semiconductor chips are 32-bits(8 hex digits).

In previous courses here, we have programmed applications to chips. If the Development Kit running one of these samples is disconnected and reconnected to power, the application will start running again, because the application hex file is stored in non-volatile memory.

When an nRF chip powers on, it will start executing code from address 0x00000000 (Technically, it’s the Reset vector, which on Arm Cortem-M is 0x00000004, as 0x00000000 is reserved for the SP initial value. For simplicity, we will say its address 0x00000000). Because of this, applications without a bootloader are stored from address 0x00000000 and onward. Typically, the application does not fill up all of the non-volatile memory, so there is some space left.

Flash memory without a bootloader

Bootloader

A basic bootloader can be explained by the name: A bootloader starts at Boot and Loads your application. The bootloader is just a second application hex file running on the chip. When the bootloader is done running, it will point the CPU to continue running from the start of the Application.

Flash memory with a bootloader

Note

A bootloader is just a second application hex file running on the chip

Register an account
Already have an account? Log in
(All fields are required unless specified optional)

  • 8 or more characters
  • Upper and lower case letters
  • At least one number or special character

Forgot your password?
Enter the email associated with your account, and we will send you a link to reset your password.