Skip to main content
Rafael Bachmann
Associate II
Sep 4, 2019 10:05 AM UTC
Question

USE_HAL_UART_REGISTER_CALLBACKS is overwritten by CubeMX. What if I want to set it to 1?

The old weakly linked callbacks are documented as legacy in the HAL source code. Yet if I want to register callback functions, the corresponding preprocessor define is overwritten by CubeMX. Is there a way to set this flag permanently (and not in the build settings, as I would like my IDE to not complain)? Setting a User Defined Constant in CubeMX does not suffice.

This topic has been closed for replies.

3 replies

SWill.11
Associate II
Mar 17, 2020 1:09 AM UTC

I have the same question. Hopefully there's a positive answer to this.

EStua.1
Associate
Mar 22, 2020 12:25 AM UTC

Same here.

angus schmaloer
Associate III
Feb 10, 2021 10:32 AM UTC

Hello, i found your awnser.

In CubeMX, go to "Project manager", in the left side you will see "Advanced Settings".

if you go over there, you can see all Register Callbacks on the right side. They are all disabled my default, you can eable them there.

GL ^^

Angus