Skip to main content
Hrishikesh
Associate III
June 25, 2018
Question

CubeMX deleted all my custom includes and libraries :(

  • June 25, 2018
  • 3 replies
  • 941 views
Posted on June 25, 2018 at 17:16

I have configured CubeMX to backup files before generating any new code and now not only has it not backed up anything but it deleted all my custom libraries as well! Also all the code under the 'USER CODE' delimiters is also gone. The only change I made was enable the ADC and it just wiped everything off resetting it to its original creation state. Is there any way to get my code back? That is almost a week's work. I use TrueStudio and I've attached the project folder here.

#cubemx-4.26
This topic has been closed for replies.

3 replies

Tesla DeLorean
Guru
June 25, 2018
Posted on June 25, 2018 at 17:54

Unless you've taken specific steps outside of CubeMX to archive your work, then it is likely lost.

You can check the recycle bin, and use a file manager to navigate the associated directories.

Iterative tools that rework files repeatedly are prone to failure, sandbox and plan accordingly.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
Pevy.Andy
Associate III
June 26, 2018
Posted on June 26, 2018 at 10:20

I always do a git commit before I run CubeMX.

Houda GHABRI
ST Employee
July 5, 2018
Posted on July 05, 2018 at 15:06

Hello 

hrishikesh

Thanks for your feedback.

Issue will be resolved in next STM32CubeMX release (4.27.0).

Best regards,

Houda