2025-06-23 10:17 PM - last edited on 2025-06-24 12:37 AM by Peter BENSCH
I am working on a project using the STM32H743ZI microcontroller.
I want to implement SPI communication using the LL (Low-Layer) drivers instead of HAL.
:question_mark: Can you confirm whether the STM32H743ZI supports LL SPI driver APIs like LL_SPI_Init, LL_SPI_TransmitData8, etc.?
Also, are there any specific settings or header files (like USE_FULL_LL_DRIVER) required to enable these LL functions in STM32CubeIDE
Does STM32H743ZI support SPI communication using LL drivers? I’m using STM32CubeIDE.
SPI1 is enabled, but LL_SPI functions are disabled unless I define USE_FULL_LL_DRIVER.
Is this the correct way to enable LL SPI support?
2025-06-23 11:17 PM
How was the project code generated? By STM32CubeMX (.ioc file)?
2025-06-23 11:51 PM
I am using stm32h747bit6-DISO board in stm32cubeide 1.18.1 software
2025-06-24 12:34 AM - edited 2025-06-24 12:48 AM
You can switch between HAL and LL drivers (when available) in the Project Manager TAB (Advanced Settings).
This should enable USE_FULL_LL_DRIVER automatically.
2025-06-24 12:57 AM - edited 2025-06-24 12:59 AM
@mohitha wrote:Can you confirm whether the STM32H743ZI supports LL SPI driver APIs like LL_SPI_Init, LL_SPI_TransmitData8, etc.?
You have that question the wrong way around!
The STM32H743ZI neither knows nor cares what you use in your source code - all it sees are the binary instructions in its Flash.
The question, then, is whether the Firmware Pack provides these LL APIs.
You can find this on the 'Tools & Software' tab of the STM32H743ZI Product Page:
https://www.st.com/en/microcontrollers-microprocessors/stm32h743zi.html#tools-software
This links you to the STM32CubeH7 firmware package - see the 'Documentation' tab for documentation:
https://www.st.com/en/embedded-software/stm32cubeh7.html#documentation
The document you require is UM2217, Description of STM32H7 HAL and low-layer drivers:
2025-06-25 12:41 AM
Hello @mohitha ,
First let me welcome you to the STM32 Community.
Please don't repost the same question several times and ensure the continuity of this issue in this thread (Duplicate threads will be deleted).
If you still have issues, don't hesitate to come-back to the Community either as a continuity of this one (when it's related to same initial topic) or with new threads (when it's a new problem).
- The STM32H743ZI microcontroller supports SPI communication using LL drivers (which are part of the STM32Cube firmware package, this includes functions like LL_SPI_Init, LL_SPI_TransmitData8, and others)
- STM32H743ZI device is already supported in the STM32CubeH7 for HAL and LL drivers.
You can refer to the working application applicable for STM32H743ZI and available in this link:
https://github.com/STMicroelectronics/STM32CubeH7/tree/master/Projects/
- To enable LL SPI functions in STM32CubeIDE, you need to define the USE_FULL_LL_DRIVER macro. This directive ensures that the LL driver functionalities, including SPI-related functions, are included in your project. Without this definition, certain LL functions may not be available, leading to compilation errors.
- You can also use STM32CubeMx tool and ensure that the desired SPI peripheral is properly configured in STM32CubeMX before generating the code. Verify that the LL drivers are enabled in the STM32CubeMX configuration (Project Manager > Advanced Settings).
For that, you can refer to these sections: "4.11.3 Advanced Settings tab" and "6.2 STM32Cube code generation using Low Layer drivers", in the UM1718: STM32CubeMX for STM32 configuration and initialization C code generation - User manual
2025-06-25 1:16 AM
@Imen.D wrote:The STM32H743ZI microcontroller supports SPI communication using LL drivers
Again, to be pedantic, that's backwards:
The STM32H743ZI microcontroller itself neither knows nor cares what drivers - if any - the source code uses.
The "support" is not in the microcontroller - it's in the drivers.
The LL Drivers do provide functions like LL_SPI_Init, LL_SPI_TransmitData8, and others.
The LL Drivers are part of the STM32Cube firmware package, and can be enabled in the source code via CubeMX.
2025-06-25 4:12 AM
sorry, I am typing wrong MCU part number .
I am working on a project using the STM32H747BIT6-DISCO microcontroller.
I want to implement SPI communication using the LL (Low-Layer) drivers instead of HAL.:question_mark: Can you confirm whether the STM32H747BIT6-DISCO supports LL SPI driver APIs like LL_SPI_Init, LL_SPI_TransmitData8, etc.?Also, are there any specific settings or header files (like USE_FULL_LL_DRIVER) required to enable these LL functions in STM32CubeIDE 1.18.1 Does STM32H747BIT6-DISCO support SPI communication using LL drivers? I’m using STM32CubeIDE.SPI1 is enabled, but LL_SPI functions are disabled unless I define USE_FULL_LL_DRIVER. Is this the correct way to enable LL SPI support?
2025-06-25 8:34 AM - edited 2025-06-25 10:49 AM
@Andrew Neil You are right. Thanks for clarify the wording.
2025-06-25 8:36 AM
Hi @mohitha ,
There is a typo in the following sentence in "6.2 STM32Cube code generation using Low Layer drivers" section of UM1718:
"For all STM32 series except STM32H7 and STM32P1, STM32CubeMX allows the user to
generate peripheral initialization code based either on the peripheral HAL driver or on the
peripheral Low Layer (LL) driver."
The limitation for STM32H7 and STM32MP1 does not exist, the doc will be updated in the coming releases to remove "except STM32H7 and STM32P1".