Loading...
 

STM32MP1 support available in SW4STM32

   With System Workbench for Linux, Embedded Linux on the STM32MP1 family of MPUs from ST was never as simple to build and maintain, even for newcomers in the Linux world.
And, if you install System Workbench for Linux in System Workbench for STM32 you can seamlessly develop and debug asymmetric applications running partly on Linux, partly on the Cortex-M4; you can download a short video showcasing this on the ac6-tools website (registration required).
Location : OpenSTM32 Community Site » Documentation » System Workbench for STM32 » User Guide » Using STM32-CoPro-MPU plugin Using STM32-CoPro-MPU plugin

Using STM32-CoPro-MPU plugin

STM32-CoPro-MPU is a plugin of System Workbench for STM32 addressing STM32MP1 MPU Family and focusing on its integrated MCU, ARM® Cortex®-M based.
This plugin is part of STMicroelectronics STM32 MPU EcoSystem as described at STMicroelectronics STM32 MPUQuestion.

Features

The following features are included in STM32-CoPro-MPU:

  • Mcu Project creation for STM32MP1 Familly
  • Coding and development by using usual source editors
  • Build the Mcu application from the standard Eclipse build mechanism
  • Debug the Mcu application in Engineering or Production modes
  • Mpu target management via dedicated Target Status Widget and Console Icon
  • Import of STM32MP1 project generated by STM32CubeMX

Specific help is available on Eclipse: Help => Help Contents, STM32 MCU USer Guide => Micro Processor Unit (MPU) Family - MCU support.

Installation

STM32-CoPro-MPU plugin is available in Linux and Windows 64bits all-in-one from version 2.8.0.
Note that updating a previous version of System Workbench for STM32 via Check for Updates will NOT install this new plugin.
Prefer Install New Software... from Ac6 update site, selecting STM32-CoPro-MPU category.


Creating and building a new project

Creating a new project is done selecting a device in STM32MP1 Family; for this STM32 Family no firmware is provided.
Creating a custom board is possible, SWD is supported.
Configuring build settings and building have nothing specific.

Mpu Target Management

STM32MP1 target can boot in two modes:

  • in Engineering Boot mode giving access to Cortex-M via SWD just like standard Mcu
  • in Normal Boot mode from various boot devices, typically booting from SD-Card a Linux Kernel.

Please visit STM32 MPU WikiQuestion for more details on boot modes.


The Engineering Boot allows to directly debug the ARM® Cortex®-M without taking care of ARM ®Cortex®-A side, this appears as Engineering Mode in ST’s STM32 MPU Debugging dedicated Debug Configuration.
AE-
The Normal Boot is used when debugging in Production Mode; ARM® Cortex®-M firmware is loaded and started from Linux on ARM ®Cortex®-A. For this Debug Mode, the Mpu target must run Linux and be network connected via Ethernet connector or Ethernet-over-USB.
Before using Production Mode it is important to know the status of the Mpu target.

Target Status Widget

This widget probes into found ST Virtual COM Port console to display Mpu target status:

  • no target seen from console
  • Linux console seen
  • target answering to IP address

Discovered IP address is used when creating / updating Debug Configuration in Production Mode, it can be copied.
Opening a console via Console Icon is stopping the widget probe & the IP address update.

Console Icon

A new Icon opens a Console if a ST Virtual COM Port console is discovered on the host PC.

This console is typically the Linux console when Linux is booted on Mpu target, but it can also be used for ARM® Cortex®-M debug purpose in Engineering Mode.

AE-AE-

Creating Mpu debug configuration

Creating debug configuration for STM32MP1 Family is made thanks to a dedicated Debug Configuration which follows the same approach but takes into account specificity: on STM32MP1 Family, ARM® Cortex®-A typically runs Linux and ARM® Cortex®-M is seen as a co-processor.

  • The “Production Mode” is proposed to debug with a download via network to ARM® Cortex®-A Linux which loads & starts the ARM® Cortex®-M image.
  • The “Engineering Mode” is targeting ARM® Cortex®-M preliminary debug, directly loading image via JTAG/SWD to internal memory.


To create a debug configuration, use the following procedure:
Within the Project Explorer, right-click on the project name and select Debug as > Debug Configurations.... from the menu.
Double left-click on ST’s STM32 MPU Debugging to create a new Debug Configuration. Its name (“Simple_Project Debug” in this example) and the path to the executable are provided by the project.


Engineering Mode & Production Mode

In Startup tab, a check box allows to choose in between Engineering Mode & Production Mode.
For Engineering Mode debug, Mpu target is booted in Engineering Mode.

The Production Mode requires the STM32MP1 target to run Linux and accessible through network: IP address is discovered by the Target Status Widget.


Debugging a Mcu project on STM32MP1

Debugging a project in Engineering Mode with STM32MP1 is very similar to standard STM32 MCU.
The Debug in Production Mode adds the cortex-M firmware transfer to the embedded Linux. This means also in case of network usage some specific pop-up appearing:

  • the SSH Password is to complete: the default one is root.

  • the RSA key is to be approved.



Importing a STM32CubeMX generated project

The STM32MP1 Family is supported in STM32CubeMX from version 5.1.0 selecting MPU.
So from this release, Importing a STCubeMX generated project is possible.

Please refer to ST Wiki Article Develop on Arm® Cortex®-M4Question for more information.



Newest Forum Posts

  1. Build fails when running through command line by rangpava, 2019-05-17 19:29
  2. SWD option gone by dangermouse, 2019-05-17 17:22
  3. syscalls and STM32CubeMX by CHAABANI Ameny, 2019-05-17 17:11
  4. Problem verifing and downloading code by elvarliiv, 2019-05-17 12:05
  5. Problem verifing and downloading code by asierdo, 2019-05-17 11:50
  6. STM32 System Workbench File Opening as Text File. by ArjunSingh, 2019-05-17 08:02
  7. Issue snprintf floats by ArminOonk, 2019-05-16 16:15
  8. Issue snprintf floats by ArminOonk, 2019-05-16 16:01
  9. Adding new Include files by Mohd Tanveer, 2019-05-16 07:51
  10. UNPLUGGED TARGET DURING DEBUG SESSION , ERROR IN FINAL LAUNCH SEQUENCE by dbdb, 2019-05-16 06:44

Last-Modified Blogs