Skip to main content
Associate
October 8, 2024
Solved

CubeMX CANBUS LL Library Support

  • October 8, 2024
  • 3 replies
  • 1781 views

I have an STM32F407G discovery development kit. I activate CANBUS while doing pin configuration via CubeMX. Then in project manager > advanced settings > driver selector tab, I can select both LL library and HAL library in all options such as GPIO, DMA, USART, ADC. But when I want to select LL library for CANBUS, I see that only HAL library is available. Why is there no LL support for CANBUS in CubeMX? Is there any way to add it? I would appreciate if you can help me.

Best answer by Andrew Neil

@embeddedguy1 wrote:

Why is there no LL support for CANBUS in CubeMX? .


Because there is no support for CAN in LL at all - CubeMX cannot add support that does not exist!

The available HAL & LL support is documented in UM1725Description of STM32F4 HAL and low-layer drivers:

https://www.st.com/resource/en/user_manual/um1725-description-of-stm32f4-hal-and-lowlayer-drivers-stmicroelectronics.pdf

via: https://www.st.com/en/embedded-software/stm32cubef4.html#documentation 

You can see that there is no LL CAN support

 


@embeddedguy1 wrote:

 Is there any way to add it?


No - because it does not exist.

 

See also:

https://community.st.com/t5/stm32-mcus-products/simulink-code-generation-support-for-stm32f407g-disc1-can-bus/m-p/728438/highlight/true#M262690 

3 replies

mƎALLEm
Technical Moderator
October 8, 2024

Hello,

Not all peripherals have LL driver including CAN.

"To give better visibility on the answered topics, please click on ""Accept as Solution"" on the reply which solved your issue or answered your question."
Associate
October 8, 2024

That's what I'm talking about, why do you answer just to answer?

mƎALLEm
Technical Moderator
October 8, 2024
"To give better visibility on the answered topics, please click on ""Accept as Solution"" on the reply which solved your issue or answered your question."
Andrew Neil
Andrew NeilBest answer
Super User
October 8, 2024

@embeddedguy1 wrote:

Why is there no LL support for CANBUS in CubeMX? .


Because there is no support for CAN in LL at all - CubeMX cannot add support that does not exist!

The available HAL & LL support is documented in UM1725Description of STM32F4 HAL and low-layer drivers:

https://www.st.com/resource/en/user_manual/um1725-description-of-stm32f4-hal-and-lowlayer-drivers-stmicroelectronics.pdf

via: https://www.st.com/en/embedded-software/stm32cubef4.html#documentation 

You can see that there is no LL CAN support

 


@embeddedguy1 wrote:

 Is there any way to add it?


No - because it does not exist.

 

See also:

https://community.st.com/t5/stm32-mcus-products/simulink-code-generation-support-for-stm32f407g-disc1-can-bus/m-p/728438/highlight/true#M262690 

A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.