User Tools

Site Tools


manual:microboot

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
manual:microboot [2016/10/12 11:29]
voorburg
manual:microboot [2022/02/10 11:23] (current)
voorburg [Building Microboot from sources]
Line 1: Line 1:
-====== ​Microboot ​Utility ======+====== ​MicroBoot ​Utility ======
  
-OpenBLT ships with download ulitity called Microboot ​for MS WindowsMicroboot ​is an easy-to-use program through which the user selects ​the file that is to be downloaded to the target. After that it handles all the communication with the microcontroller target ​that runs OpenBLT ​and provides ​status ​information to the user.+MicroBoot is graphical user interface (GUI) program ​for performing firmware updates on a microcontroller that runs the OpenBLT bootloaderIt is an easy-to-use program through which the user select ​the firmware ​file that is to be programmed on the microcontroller ​target. After that it handles all the communication with the microcontroller target and provides ​progress ​information to the user. For those that prefer a command line interface (CLI) program for handling firmware updates, there is [[manual:​bootcommander|BootCommander]].
  
 +MicroBoot was written in Object Pascal using the [[https://​www.lazarus-ide.org/​|Lazarus IDE]] and developed with cross-platform support in mind. It has been successfully tested on a Windows PC, Linux PC and even runs on a Raspberry PI.
  
 +{{:​manual:​olimex_stm32p405_download_can.png?​|}}
  
-What is special about Microboot is the fact that it provides a generic and and standalone user interface for  downloading softwarewhich is independent of the communication interface. The communication interface controls the communication and actual data flow between the PC and the microcontroller and is located in a dynamic linked ​library (DLLfile. This means that support ​for new communication ​interfaces can be added without having to modify ​the MicroBoot user interface.+Under the hoodMicroBoot relies on the OpenBLT host library ([[manual:​libopenblt|LibOpenBLT]]) for handling the actual ​communication ​with the bootloader.
  
 +{{:​manual:​microboot_architecture_75.png?​|}}
  
 +Thanks to the open source nature of the OpenBLT project, full source code is available for the MicroBoot program. This makes it a great reference and starting point for those that would like to develop their own firmware update tool.
  
-This part of the user manual explains how to use the Microboot utility. First a detailed overview of the user +===== User interface ​=====
- +
-interface is provided, followed by an explanation of the command line options that can be used when invoking the Microboot utility. +
- +
- +
- +
-===== User Interface ​=====+
  
 The illustration below provides an overview of the Microboot user interface. \\  The illustration below provides an overview of the Microboot user interface. \\ 
  
 +{{:​manual:​microboot_gui_explained.png?​|}}
  
 +(1) When starting MicroBoot for the first time, it is important to select and configure the communication interface. This is achieved by clicking the “Settings”-button,​ after which the dialog titled “Settings” appears. Start by selecting the desired communication transport layer from the “Interface selection”-dropdown box. After selecting the communication transport layer, the options on the dialog are updated accordingly,​ allowing you to further configure it.
  
-{{:​manual:​microboot_gui.png?​nolink&​500|}} +(2Once the communication interface is selected and configured ​in MicroBoot, you can start using it to perform firmware updates on your microcontroller, which has the OpenBLT bootloader ​in flash. To start the firmware update procedure, click the Browse-button and select the firmware ​file for your microcontroller. The firmware update ​will start automatically after you selected the file. If necessaryMicroBoot ​will request ​you to reset your microcontroller ​to active ​the OpenBLT bootloaderFor most demo programs, this happens automatically ​and no user action ​is required. The progress bar on the user interface allows ​you to keep track of the firmware update progress.
- +
- +
- +
-(1When starting Microboot for the first time it is important to select and configure ​the communication interface. This is achieved by clicking the "​Settings"​-button. The dialog titled "​Interface Settings"​ will appear. All the communication interfaces that were delivered with your version of Microboot will appear in the dropdown box. Select the one you intend to use. Next, click on the "​Options"​-button to further configure the selected ​communication interface. Your interface selection is stored in the MS Windows Register ​and therefore, this step only has to be done once. +
- +
- +
- +
-(2) Once the Microboot communication interface is configured, you can start using it to download software to your microcontroller. Make sure your microcontroller is in a state that it can receive and program the new software. To start the software download, click the "Browse"-button and select the software ​file that you want to download to the microcontroller. The download ​will start automatically after you selected the file. The text box on the user interface will change into a progress bar, allowing you to track the progress of your software download: +
- +
- +
- +
-{{:​manual:​microboot_session.png?​nolink&​400|}} +
- +
- +
- +
-(3) To close the Microboot utility, simply click the "​Cancel"​-button. If a download is in progressit will automatically be interrupted for you before the Microboot utility is closed. +
- +
- +
- +
- +
- +
-===== Command Line Options ===== +
- +
-There are several ways that you can start the Microboot utility using the supported command line options. This allows a flexible use of the utility. To give some examples, Microboot can be invoked directly from a Makefile or Batchfile allowing ​you to automatically download ​your software at the end of the build process. Another possibility is to create a shortcut in MS Windows, customized for the desired command line options, and once double-clicked,​ the software download will start right away with the correct communication interfaceThe following options can be used: +
- +
- +
- +
-**-p** Invoking the Microboot utility with this option will display the "​Select file for download"​-dialog. This option simulates the "​Browse"​-button click. +
- +
- +
- +
-**-i<​interface>​** Using this optionyou can specify what communication interface to use. <​interface>​ should be replaced with the *.dll filename of the communication interface. Without ​this option, the Microboot utility will use the communication interface that was last used. +
- +
- +
- +
- +
- +
-**-l** When this option is specified, the Microboot utility will generated the logfile called "​log.txt"​ during the download process. The logfile contains details about the download process ​and is especially helpful when resolving download problems. The logfile is stored in the same directory as where "​Microboot.exe"​ is located. +
- +
- +
- +
-**<​filename>​** At the end of the command line you can specify the software file that should be downloaded. This way you don't have to manually specify this file every time you start the Microboot utility. When Microboot detects this <​filename>​ option, it will start the download right away for you using the specified file, +
- +
-allowing you to fully automate the download sequence. +
- +
- +
- +
-Example command line: **Microboot.exe –l –iopenblt_uart.dll c:​\my_files\test_app.s19**+
  
-===== Building Micrboot from sources =====+(3) To close MicroBoot, simply click the “Exit”-button. If a firmware update is in progress, it will be automatically interrupted.
  
 +===== Command line options =====
  
 +It is possible to start MicroBoot from the command line. At this point the only command line argument that is supports is the firmware file itself, including its full absolute (or relative) path. When MicroBoot is started this way, it automatically starts the firmware update procedure using the specified firmware file. This feature enables the integration of MicroBoot into your integrated development environment (IDE), such that for example a firmware update is automatically started after building your firmware.
  
 +===== Building Microboot from sources =====
  
 +The free and open source [[https://​www.lazarus-ide.org/​|Lazarus IDE]] was used to develop MicroBoot. To install the Lazarus IDE, point your browser to its project page on [[https://​sourceforge.net/​projects/​lazarus/​files/​|SourceForge]]. ​
  
 +For Linux users, DEB and RPM packages are provided. However, it is recommended to install the version of the Lazarus IDE that is offered in the package repositories of your Linux distribution. Here are the installation instructions for most popular Linux distributions:​
  
 +  * **Debian**: <​code>​sudo apt install make gdb fpc fpc-source lazarus</​code>​
  
 +  * **Ubuntu**: <​code>​sudo apt install make gdb fpc fpc-source lazarus lcl</​code>​
  
 +  * **Fedora**: <​code>​sudo dnf install make gdb fpc fpc-src lazarus</​code>​
  
 +  * **openSUSE**:​ <​code>​sudo zypper install make gdb fpc fpc-src lazarus</​code>​
  
 +Note the starting OpenBLT version 1.14, the included Windows binaries are 64-bit (MicroBoot, BootCommand and LibOpenBLT). Windows users should therefore download and install the [[https://​sourceforge.net/​projects/​lazarus/​files/​Lazarus%20Windows%2064%20bits/​|64-bit Lazarus version]]. When using OpenBLT from before version 1.14, download and install the [[https://​sourceforge.net/​projects/​lazarus/​files/​Lazarus%20Windows%2032%20bits/​|32-bit Lazarus version]] instead.
  
 +To build MicroBoot, start the Lazarus IDE by selecting it from the start menu of your desktop environment. Next, select //​Project->​Open//​ from the program menu. Browse to the **./​Host/​Source/​MicroBoot/​** directory and select the **MicroBoot.lpi** file. Build, run and debug MicroBoot by simply clicking the green play-button in the toolbar or by selecting //​Run->​Run//​ from the program menu.
  
  
manual/microboot.1476264590.txt.gz · Last modified: 2019/09/24 22:07 (external edit)