cancel
Showing results for 
Search instead for 
Did you mean: 

Hello. I was trying to build my project and found a driver error. How to fix it?

ALeut.1
Associate II

0693W00000QM8OTQA1.png

8 REPLIES 8
KnarfB
Principal III

UART5 defined elsewhere in your code?

Work in a new generated project.

hth

KnarfB

ALeut.1
Associate II

UART5 is not defined in other parts of the program, only here.

JPeac.1
Senior

Where is UART5_BASE defined? At a guess you have included an STM32 port definition header that doesn't have the extra UARTs.

KnarfB
Principal III

Yeah. Check a freshly generated unaltered project and report exact chip type and tool versions. Works here for STM32F429VETX and the newest STM32CubeIDE. Looks like a mixup of prprocessor definitions.

hth

KnarfB

ALeut.1
Associate II

Chip: STM32F429ZIT6U;

Board: STM32F429I Discovery;

CubeIDE version: 1.5.0.

I tried building the generated project without making changes. Everything went well.

0693W00000QM8ixQAD.png

ALeut.1
Associate II

Using the elimination method, I realized that the error appears when trying to read the value from the data register.

0693W00000QM8pjQAD.png0693W00000QM8pyQAD.png

KnarfB
Principal III

int p[8] is an array declaration and therefore, the assignment of a value (UART5->DR) to an array makes no sense and causes errors/warnings. The compiler may not be intelligent enough to give the best error message here.

hth

KnarfB

ALeut.1
Associate II

Thank you very much for your help. I did not understand the dimension of the received data and made mistakes in the code.