element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Freedom development platform
  • Products
  • Dev Tools
  • Freedom development platform
  • More
  • Cancel
Freedom development platform
Documents Basics of Bootloader
  • Blog
  • Forum
  • Documents
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Freedom development platform to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Engagement
  • Author Author: bheemarao
  • Date Created: 21 May 2014 9:24 AM Date Created
  • Last Updated Last Updated: 8 Oct 2021 7:51 AM
  • Views 1294 views
  • Likes 0 likes
  • Comments 0 comments
Related
Recommended

Basics of Bootloader

What is a bootloader?


A bootloader is a program which is able to load another program (the application program). Typically, the bootloader program is not changed, and is kept in the microcontroller. That way the bootloader loads different program again and again.

The following figure-1 shows a typical diagram of a serial bootloader:

image

                                                                                                Figure 1: Serial Bootloader

 

Note: Depending on the architecture, there can be a mini or micro bootloader that can load the real bootloader. For example, the OpenSDA bootloader on the Freedom boards have this capability.


The Bootloader Code and the Bootloader Vectors are programmed into a new part (for example, with a debugger) or, a standalone flash programmer (for example, with USBDM). Then the bootloader can be used to load or change the Application Code and Application Vectors. With this, the bootloader remains the same, while the application can be updated.


What is Bootloader Sequence?

A typical bootloader has the following sequence:

  1. At the startup the bootloader either enters in a bootloader mode or in the application running mode. Typically, this is decided with a button or jumper set (or removed). If the bootloader starts in application running mode, it calls the required application and the system starts automatically.
  2. Otherwise, the bootloader reprograms the application with a new file. The S19 (S-Record) files are often used for this, as they are easy to parse and every tool chain can produce them.
  3. The bootloader needs to use a communication channel to read that file. That can be RS-232, USB or an SD card file system (e.g. FatFS).
  4. Using that file, the bootloader programs the flash memory. Special consideration has to be taken into account for the application vector table. When the bootloader runs out of reset, it uses its own (default) vector table, and needs to relocate the vector table if running the application.

 

Tip: It is possible to use the reset button on the FRDM-KL25Z board as a user. To keep things simple, you may use a dedicated bootloader push button on PTB8.

The following figure-2 shows the Bootloader System Block Diagram:

image

Figure-2: Bootloader System Block Diagram

 

The components of the Bootloader System Block Diagram are as follows:

  • Communication Channel
  • File Reader
  • Flash Programming
  • Vector Redirection
  • User Interface
  • freescale
  • kinetis
  • freedom
  • Share
  • History
  • More
  • Cancel
  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube