2019-12-03 06:57 AM
Hi,
I'm using the STM32H750 Discoveryboard.
When running my code from TouchGFX Designer, everything works fine.
But when running with Keil IDE, something strange is happening:
-Flashing the application and loading with the debugger -> hard fault occurs in funtion crc_lock
If I unplug and replug the board, the application starts just fine. Only when connected to the debugger, the hard fault occurs.
Do you have any hints?
__HAL_RCC_CRC_CLK_ENABLE is being called, so that shouldn't be a problem
Thanks.
Solved! Go to Solution.
2019-12-05 06:06 AM
What do you mean by "The examples" ?
/Martin
2019-12-05 06:12 AM
The Application templates which come with the designer.
2019-12-05 06:15 AM
@Community member,
What goes wrong here is actually that the Device ID of the Chip is not read properly with a Keil project (in debug mode using some particular version of ST-Link,) and thus the lock defaults to checking a CRC on the wrong address.
Probably related to DBGMCU not being readable at all.
/Martin
2019-12-05 06:20 AM
Just to rule it out: Please make sure that the CRC is actually activated.
2019-12-05 06:24 AM
Yes it is activated. Think wouldn't work at all if it's deactivated.
2019-12-05 06:25 AM
Can you read anything from DBGMCU at all? 0x5C001000
2019-12-05 06:26 AM
The application templates contain no libraries or headerfiles - The application is bootstrapped by the particular verison of the designer you're using.
2019-12-05 06:33 AM
Then what's the library called touchgfx_core.lib found in C:\TouchGFXProjects\I2CTouchGfx\Middlewares\ST\TouchGFX\touchgfx\lib\core\cortex_m7\Keil
2019-12-05 06:39 AM
It's the library copied by the designer when you generated code. Coincidentally located in Middlewares/ST/TouchGFX/
/Martin
2019-12-05 06:41 AM
Ok, that's what I mean by "is this library correct to use" in Keil?
Not that I'm using the wrong library...