Difference between revisions of "How to debug a user space application with STM32CubeIDE"

[unchecked revision] [quality revision]
(Merge articles)
m
 

This article is a guideline to user space project support, which is fully integrated from release 1.6.0 of STM32CubeIDE.

It covers executable, static or shared libraries support from project creation to debug. It also gives some tracks to easily use the GTK library or start a new project from the standard Eclipse® CDT™ project wizard.

1 Prerequisite[edit]

Minimum hardware

  • STM32MP15xx-based board
  • Linux® console
  • Ethernet (or Ethernet over USB) for connection to Linux® Cortex®-A

Minimum software

2 STM32CubeIDE ® user space[edit]

From STM32CubeIDE release 1.6.0 it is possible to enrich an STM32MP15xx hierarchical project with User Space type project.

STM32MP15 project enriched with Linux user space projects


3 Eclipse® CDT™ STM32 Linux® user space[edit]

From STM32CubeIDE release 1.6.0, it is also possible to easily create an STM32MP15xx user space project from the standard CDT™ Eclipse® wizard.

In that case, the user space project is not part of any STM32MP15xx hierarchical project and appears as a standalone project in Eclipse® project explorer view: myCdtProject below:

CDT™ Linux® user space project


This article is a guideline to user space project support, which is fully integrated from release 1.6.0 of STM32CubeIDE. 

It covers executable, static or shared libraries support from project creation to debug. It also gives some tracks to easily use the GTK library or start a new project from the standard Eclipse<sup>®</sup> CDT™ project wizard. 

==Prerequisite==
'''Minimum hardware'''
* STM32MP15xx-based board
* Linux<sup>®</sup> console
* Ethernet (or Ethernet over USB) for connection to Linux<sup>&reg;</sup> Cortex<sup>&reg;</sup>-A 

'''Minimum software'''
* STM32CubeIDE v1.6.0 installed and
** [[How_to_get_started_with_STM32CubeIDE_from_scratch|STM32MP15 project created]]
** [[How to install the Yocto Project SDK in STM32CubeIDE |Yocto SDK installed]] through the "Setup OpenSTLinux" Cortex<sup>®</sup>-A contextual menu

==STM32CubeIDE <sup>®</sup> user space==
From STM32CubeIDE release 1.6.0 it is possible to enrich an STM32MP15xx hierarchical project with '''''User Space''''' type project.

[[File:CubeIDEUserSpaceTree.png|250px|thumb|center|'''STM32MP15 project enriched with Linux user space projects''' ]]
{{ReviewsComments | [[User:Ludovic Bergonzi|Ludovic Bergonzi]] ([[User talk:Ludovic Bergonzi|talk]]) 13:38, 28 May 2021 (CEST) <br /> Highlight in pink (R 230 G 0 B 126) instead of red<br> LRa Done}}

* [[How to debug a user space application with STM32CubeIDE/User space project|executable]] project support - myExe

* [[How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_static_library_project|static library]] project support - myStaticLib

* [[How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_shared_library_project|shared library]] project support - mySharedLib

* [[How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_GTK_library_project|GTK library]] usage example - GtkHelloWorld

==Eclipse<sup>®</sup> CDT™ STM32 Linux<sup>®</sup> user space==
From STM32CubeIDE release 1.6.0, it is also possible to easily create an STM32MP15xx user space project from the standard CDT™ Eclipse<sup>®</sup> wizard.

In that case, the user space project is not part of any STM32MP15xx hierarchical project and appears as a standalone project in Eclipse<sup>®</sup> project explorer view: ''myCdtProject'' below:

[[File:CDTExeTree.png|250px|thumb|center|''CDT™ Linux<sup>®</sup> user space project'' ]]
{{ReviewsComments | [[User:Ludovic Bergonzi|Ludovic Bergonzi]] ([[User talk:Ludovic Bergonzi|talk]]) 13:38, 28 May 2021 (CEST) <br /> Highlight in pink (R 230 G 0 B 126) instead of red<br> LRa Done}}
* [[How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_CDT_project|STM32MP15xx Linux<sup>®</sup> user space executable from CDT™ wizard]] project support - myCdtProject
<noinclude>

[[Category:STM32CubeIDE|15]]
{{PublicationRequestId | 19680 (LudovicB)  |2021-04-20 }}</noinclude>
Line 19: Line 19:
 
[[File:CubeIDEUserSpaceTree.png|250px|thumb|center|'''STM32MP15 project enriched with Linux user space projects''' ]]
 
[[File:CubeIDEUserSpaceTree.png|250px|thumb|center|'''STM32MP15 project enriched with Linux user space projects''' ]]
   
{{ReviewsComments | [[User:Ludovic Bergonzi|Ludovic Bergonzi]] ([[User talk:Ludovic Bergonzi|talk]]) 13:38, 28 May 2021 (CEST) <br /> Highlight in pink (R 230 G 0 B 126) instead of red
 
<br> LRa Done}}
 
   
 
* [[How to debug a user space application with STM32CubeIDE/User space project|executable]] project support - myExe
 
* [[How to debug a user space application with STM32CubeIDE/User space project|executable]] project support - myExe
Line 36: Line 34:
   
 
[[File:CDTExeTree.png|250px|thumb|center|''CDT™ Linux<sup>®</sup> user space project'' ]]
 
[[File:CDTExeTree.png|250px|thumb|center|''CDT™ Linux<sup>®</sup> user space project'' ]]
 
{{ReviewsComments | [[User:Ludovic Bergonzi|Ludovic Bergonzi]] ([[User talk:Ludovic Bergonzi|talk]]) 13:38, 28 May 2021 (CEST) <br /> Highlight in pink (R 230 G 0 B 126) instead of red
 
<br> LRa Done}}
 
   
 
* [[How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_CDT_project|STM32MP15xx Linux<sup>®</sup> user space executable from CDT™ wizard]] project support - myCdtProject
 
* [[How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_CDT_project|STM32MP15xx Linux<sup>®</sup> user space executable from CDT™ wizard]] project support - myCdtProject