hi
as maybe you have already tried, the latest proteus versions allow you to simulate some stm32F cores, most of the time with the gcc compiler and folders internally generated ...
So i was wondering if some code on stmcube would be simulated in order to verify some i2c stuff i've already tried on pic mcu...
The problem is that the default compiler config doesnt generate the correct elf file.
So, go to your project properties.
Select the C/C++ build item
Go to settings
In the "Tool Settings" part, set no debug and add at the end of the "Command" line: -gdwarf-2
After compiling, you will be able to simulate step by step on proteus.
Best regards and sorry if this is not new to you