cancel
Showing results for 
Search instead for 
Did you mean: 

Step by step guidance how to create a linux application for STM32MP157C-DK2

MSele.1
Associate III

I have been looking for step by step guidance on how to create a linux application for STM32MP157C-DK2, but I end up being unsecssuful all the time. The only help I seem to get is to import an existing project, which does not help me. I want my application to be the one running on startup instead of the current demo application that is on the SD card.

Your help on this matter is really appreciated.

Sel.

5 REPLIES 5
Eldam
Senior

Hello , did you have a look on this?

https://wiki.st.com/stm32mpu/wiki/How_to_cross-compile_with_the_Developer_Package#Adding_a_.22hello_world.22_user_space_example

First write helloworld c program

verify execution on linux classic system

2nd compile it with cross compilater

copy to target (dk2)

run it on target

You could use file myprogramname to have infiormation about it ( compiled for arm or x86)

Welcome to the black hole learning curve to linux !

follow ST wiki / tutorial step by step

MSele.1
Associate III

Do I need to have a distribution package or the developer package is enough. Most of the what I read keep using the word distribution, but early in wiki there was a warning that for most applicvations the developer packagae is enough. The Wiki seems to be confusing

LudovicR
ST Employee

Hello MSele.1,

If you are not familiar with Linux it may worth to use STM32CubeIDE which provides from release 1.6.0 support for user space application: https://wiki.st.com/stm32mpu/wiki/How_to_debug_a_user_space_application_with_STM32CubeIDE

It will give you some guidelines to develop and debug your own user space project.

If you want to stay in with the demo graphical environment you can try GTK example https://wiki.st.com/stm32mpu/wiki/How_to_debug_a_user_space_application_with_STM32CubeIDE/User_space_GTK_library_project which implements a graphical Hello World.

The demo is based onto weston so, in order to run your application on MP1x startup you can:

. update current launcher: /usr/local/demo/demo_launcher.py

. or create your own launcher and update /etc/xdg/weston/weston.ini file

Hope this help,

Ludovic

Thanks Ludovic

This is the very good guidance I have been looking for; I start to see light at the end of the tunnel. Do you have additional information on how to:

. update current launcher: /usr/local/demo/demo_launcher.py

. or create my own launcher and update /etc/xdg/weston/weston.ini file

LudovicR
ST Employee

Hello MSele.1,

You will find some information about demo launcher here: https://wiki.st.com/stm32mpu/wiki/GTK_demo_launcher

Best Regards,

Ludovic