cancel
Showing results for 
Search instead for 
Did you mean: 

Different hard faults on STM32H562

lors
Associate II

I have a problem here:
When calling strcat() on a target string with odd length and odd source, the controller goes into hardfault, SCB_UFST_UNALIGNED is set. 

If I deactivate the unaligned trap (SCB_CCR_UNALIGN_TRP == 0), the following happens.

The controller goes into hardfault on calling putchar(), SCB_BFSR_IBUSERR set. Many previous calls to putchar() work fine.

I use CUBEide with GNU Tools for STM32 12.3rel1.
The code has already been compiled for other STM32 derivatives and other versions of GNU Tools, and works fine on these systems.

1 ACCEPTED SOLUTION

Accepted Solutions
lors
Associate II

I can't say exactly which action solved the problem, in this code some timers are used, the corresponding interrupt service routines were installed. I deactivated all these timers for the time being. So the problem was elsewhere.

View solution in original post

3 REPLIES 3
lors
Associate II

The Problem is solved.

Hello,

Please, put the description of the solution and mark it as solution.

Thanks.

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.
lors
Associate II

I can't say exactly which action solved the problem, in this code some timers are used, the corresponding interrupt service routines were installed. I deactivated all these timers for the time being. So the problem was elsewhere.