Forums › Devices › OSD32MP15x › stm32mp15-mx.h
With CubeMX 5.6.1 and OSD32MP15x_MinimalConfig.zip from https://octavosystems.com/files/osd32mp15x_minimalconfig/ I get the dts and dtsi files for tf-a and u-boot as expected in the U-Boot device tree generated by CubeMX:
/tf-a/stm32mp157c-osd32mp157c-512m-baa_minimalconfig-mx.dts
/u-boot/stm32mp157c-osd32mp157c-512m-baa_minimalconfig-mx-u-boot.dtsi
But stm32mp15-mx.h is missing for both tf-a and u-boot.
What do I need to do to generate stm32mp15-mx.h?
Have you cloned the corresponding git repos?
Arm Trusted Firmware
https://github.com/STMicroelectronics/arm-trusted-firmware
48 forks.
30 stars.
0 open issues.
For example this one I used to compile the tf-a.
I used tf-a-stm32mp-2.2.r1-r0 from en.SOURCES-tf-a-stm32mp1-openstlinux-5-4-dunfell-mp1-20-06-24.tar.xz, applied the patches and the dts file frmo CubeMX. That is where I was missing stm32mp15-mx.h – in the tutorial under 7.0 (https://octavosystems.com/app_notes/stm32mp1-cubemx-tutorial-for-osd32mp15x/) it says to also copy the Custom TF-A Device Tree source files.
So I can compile the tf-a, but when I flash it, it gets stuck running the program and then errors out:
Memory Programming …
Opening and parsing file: tf-a-stm32mp157c-ev1-trusted.stm32
File     : tf-a-stm32mp157c-ev1-trusted.stm32
Size     : 212104 Bytes
Partition IDÂ : 0x01
Download in Progress:
100%
File download complete
Time elapsed during download operation: 00:00:00.548
RUNNING Program …
PartID:Â Â Â :0x01
Error: an error occured while uploading data from the virtual partition 0xF1
Start operation done successfully at partition 0x01
CubeMX prior to version 6 seems to be incompatible to openstlinux-5-4-dunfell-mp1-20-06-24.
What I did is using CubeMX 6.0 install the SDK and the mentioned sources.
After that I extracted the compressed tarballs in the source folder.
Then I cloned the git projects from st and copied the files to the source folder.
Added the board filename to the Makefile and compiled it.
That worked with the exception of das U-Boot which will not boot if I exchanged the original one.
EDIT: I use Linux and the dd command to directly write the stm32 files to sd card
I think stm32mp15-mx.dtsi is the header file! So when they mention stm32mp15-mx.h in the readme it should be stm32mp15-mx.dtsi.
I upgraded the CubeMX project to 6.0 and generated the code again.
Now when I execute:
1 | make -f $PWD/../Makefile.sdk TFA_DEVICETREE=stm32mp157c-osd32mp1-mx TF_A_CONFIG=trusted ELF_DEBUG_ENABLE='1' all |
I get the following error:
fdts/stm32mp157c-osd32mp1-mx.dts:14:10: fatal error: dt-bindings/soc/st,stm32-etzpc.h: No such file or directory
14 | #include <dt-bindings/soc/st,stm32-etzpc.h>
I copied the files from /CA7/DeviceTree/OSD32MP1/tf-a/ to /tf-a-stm32mp-2.2.r1/fdts
You forgot to copy the github repo!
Arm Trusted Firmware
https://github.com/STMicroelectronics/arm-trusted-firmware
48 forks.
30 stars.
0 open issues.
you can find the file in the directories:
include/dt-bindings/soc
Ah yes, I missed that in step 4 of /tf-a-stm32mp-2.2.r1-r0/README.HOW_TO.txt. I compiles the custom CubeMX board now.
Thanks Tobias!
Octavo Systems LLC all rights reserved
OCTAVO is registered in the U.S. Patent and Trademark Office. OSD, C-SiP, and the Octavo Logo are trademarks of Octavo Systems LLC.
"*" indicates required fields
"*" indicates required fields
"*" indicates required fields
"*" indicates required fields