

For example, use SPI2 for SPI interface in MEMS sensor.By clicking on it, you will have an option to align sensor middleware with physical hardware available in MCU. Move to Configuration tab where you should see new tab for additional software.In the pinout tab, select SPI or I2C and enable it in standard way.Now that sensors are added, we have to link physical SPI/I2C interface with sensor middleware itself.You may choose I2C or SPI interface for each of them and once you are ok, confirm and close the window. By selecting your sensors, they are automatically added to the project.Here we will focus on X-MEMS where you can select your Application or you go with accelerometer/gyro/humity/temperature or pressure sensors, supported by X-CUBE-MEMS1. You have different installed software packages listed.Start a new project and select part or board, for example STM32L476RG and start the project.Now that we have our important software installed, we can try to start a new project Check for Documentation folder and open instructions PDF file which will guide you in details how to use this specific software in CubeMX.You can find all installed sources in (default folder for Windows, replace username): C:\Users\\STM32Cube\Repository\Packs\STMicroelectronics\X-CUBE-MEMS1\5.1.0.CubeMX will automatically download sources from st.com and install it to STM32Cube Repository folder.Find X-CUBE-MEMS1 and install it (by time of writing this post, latest version was 5.1.0).Find tab STMicroelectronics and you will see list of currently available integrated libraries for CubeMX.Embedded software manager windows will open.Go to Help -> Manage embedded software libraries or press Alt+U.Install STM32CubeMX 4.27.0 or newer and open it.To enable embedded libraries to be added to CubeMX, please follow steps, explained below: You will notice them with X-CUBE-library_name name format, like X-CUBE-MEMS1 which is complete solution for ST MEMS sensors. Starting with STM32CubeMX version 4.27.0 ST added an option to manage embedded software libraries directly into CubeMX and have fully integrated graphical tool to configure project into very details before building application in final toolchain ( Keil, IAR, TrueSTUDIO, …).Įmbedded software libraries are libraries (also) provided by STMicroelectronics.
