Difference between revisions of "HANcoder/STM32/Installation Manual"

From OpenMBD
Jump to: navigation, search
 
(19 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 +
{{HANcoder}}
 
[[File:HANcoderLogo.png|right|200px|HANcoder Logo]]
 
[[File:HANcoderLogo.png|right|200px|HANcoder Logo]]
  
 
==Introduction==
 
==Introduction==
  
This document is for the user who wants to make a software program using Simulink and the HANcoder blockset for the Olimexino STM32 development board. It contains installation tutorials for the programs necessary to work with the blockset. It will also explain the template model, building a model in Simulink and flashing the software to the Olimexino. Furthermore, it will explain how you can view signals and edit parameters while the software runs on the Olimexino. This is done with a program called HANtune. So HANcoder is used to build the software program from a Simulink model and HANtune is used to view and edit (tune) the program once the program is running on the hardware.<br/>
+
This page is for the user who wants to make a software program using Simulink and the HANcoder blockset for one of the STM32 development boards. It contains the installation steps necessary to work with the blockset. It will also explain the template model, building a model in Simulink and flashing the software to the Olimexino. Furthermore, it will explain how you can view signals and edit parameters while the software runs on the Olimexino. This is done with another program called HANtune, HANtune is used to view and edit (tune) the program once the program is running on the hardware.<br/>
Click [http://openmbd.com/wp-content/uploads/2016/11/HANcoder-STM32-Target-v0.5.zip| here]to download HANcoder and click [http://openmbd.com/wp-content/uploads/2017/02/HANtune2.0.zip| here] to download HANtune.<br/>
 
If you encounter problems with the blockset or with HANtune, please contact the developer Jason van Kolfschoten: Jason.vanKolfschoten@han.nl
 
  
==Matlab Installation==
+
Before you start make sure you have the latest version of HANcoder and HANtune:<br/>
 +
[[Downloads/HANcoder]] and unzip all files into a directory of your choice.<br/>[[Downloads/HANtune]] and unzip all files as well.<br/>
 +
Attention: You can only flash the controllers with a flash tool like the ST-Link or when you have a controller with the bootloader from HANcoder. The boards are normally shipped with an incompatible bootloader installed, so to use a board first the right bootloader should be installed, this can only be done with a flash tool.<br/>
 +
If you encounter problems with the installation of HANcoder or HANtune please visit the [[HANcoder/STM32/Troubleshooting|troubleshooting section]] or the [http://openmbd.eu/?forum=hancoder forum]
  
A step by step guide on how to install Matlab Simulink and the necessary toolboxes.
+
==MATLAB&reg; Installation==
[[HANcoder/STM32/Getting_Started_Guide_Matlab_Installation|Learn more.]]
+
 
 +
The first step is to install MATLAB&reg; Simulink with the necessary toolboxes.
 +
[[HANcoder/STM32/Getting_Started_Guide_MATLAB_Installation|Learn more.]]
  
 
==GNU ARM Toolchain Installation==
 
==GNU ARM Toolchain Installation==
Line 19: Line 23:
 
==Test the build process==
 
==Test the build process==
  
After installing Matlab and the GNU ARM Toolchain it is time to test the code generation from the template model.
+
After installing MATLAB&reg; and the GNU ARM Toolchain it is already possible to generate code for your STM32 hardware. The first test is to build the template model and which only blinks an LED.
 
[[HANcoder/STM32/Getting_Started_Guide_Build_Test|Learn more.]]
 
[[HANcoder/STM32/Getting_Started_Guide_Build_Test|Learn more.]]
  
Line 31: Line 35:
 
[[HANcoder/STM32/Getting_Started_Guide_Flashing_With_The_ST_Link|Learn more.]]
 
[[HANcoder/STM32/Getting_Started_Guide_Flashing_With_The_ST_Link|Learn more.]]
  
==Installing the Virtual COM port driver==
+
==Installing the Virtual COM port driver (not needed in Windows 10!)==
  
 
To be able to connect over USB with HANtune a special driver must be installed. The installation of this driver and other relevant knowledge to be able to use HANtune can be found here. [[HANcoder/STM32/Getting_Started_Installing_The_Virtual_COM_port|Learn more.]]
 
To be able to connect over USB with HANtune a special driver must be installed. The installation of this driver and other relevant knowledge to be able to use HANtune can be found here. [[HANcoder/STM32/Getting_Started_Installing_The_Virtual_COM_port|Learn more.]]
Line 46: Line 50:
  
 
Please check this section if you encounter any problems.
 
Please check this section if you encounter any problems.
[[HANtune/TroubleShooting|Learn more.]]
+
[[HANcoder/STM32/Troubleshooting|Troubleshooting]]

Latest revision as of 15:00, 7 November 2019


HANcoder Logo

Introduction

This page is for the user who wants to make a software program using Simulink and the HANcoder blockset for one of the STM32 development boards. It contains the installation steps necessary to work with the blockset. It will also explain the template model, building a model in Simulink and flashing the software to the Olimexino. Furthermore, it will explain how you can view signals and edit parameters while the software runs on the Olimexino. This is done with another program called HANtune, HANtune is used to view and edit (tune) the program once the program is running on the hardware.

Before you start make sure you have the latest version of HANcoder and HANtune:
Downloads/HANcoder and unzip all files into a directory of your choice.
Downloads/HANtune and unzip all files as well.
Attention: You can only flash the controllers with a flash tool like the ST-Link or when you have a controller with the bootloader from HANcoder. The boards are normally shipped with an incompatible bootloader installed, so to use a board first the right bootloader should be installed, this can only be done with a flash tool.
If you encounter problems with the installation of HANcoder or HANtune please visit the troubleshooting section or the forum

MATLAB® Installation

The first step is to install MATLAB® Simulink with the necessary toolboxes. Learn more.

GNU ARM Toolchain Installation

The GNU ARM Toolchain is necessary to build code for generating code for the STM32 series microcontrollers Learn more.

Test the build process

After installing MATLAB® and the GNU ARM Toolchain it is already possible to generate code for your STM32 hardware. The first test is to build the template model and which only blinks an LED. Learn more.

Flashing the controller with the bootloader

Putting the with Simulink generated software on the micro controller is called flashing. This can be done using the flash program Microboot when the micro controller has a bootloader program on it. Learn more.

Flashing the controller with the ST-Link

Flashing can also be done with an ST-Link, this is a special tool from ST to flash their micro controllers. Learn more.

Installing the Virtual COM port driver (not needed in Windows 10!)

To be able to connect over USB with HANtune a special driver must be installed. The installation of this driver and other relevant knowledge to be able to use HANtune can be found here. Learn more.

Installing PEAK PCAN driver

To be able to connect over CAN with HANtune a PEAK CAN to USB dongle is used.Learn more.

Installing the ST-Link

When there is no bootloader on the microcontroller (yet) it is necessary to use the ST-Link to flash the micro controller. The installation procedure for this tool is described in this chapter. Learn more.

Troubleshooting

Please check this section if you encounter any problems. Troubleshooting