2024-05-21 12:16 AM
Hi,
i wanted to export this Project:
https://github.com/mirzafahad/nucleo_stm32f429zi_lwip_examples/tree/master/UDP_Echo_Client
to CMake, so i can import it via the STM32 VSCode extension.
I was following this short Video: https://www.youtube.com/watch?v=DDVdq47Dd94
Unfortunately when i click on "GENERATE CODE", most of the code written in main.c is lost. How can i prevent this?
Thanks for any help!
2024-05-21 12:47 AM
"Unfortunately when i click on "GENERATE CODE", most of the code written in main.c is lost. How can i prevent this?"
Only write code in user code sections "USER CODE BEGIN x" and "USER CODE END x". Sometimes it can be tricky if you want to change some code outside of these sections, but you can use pre-processor tricks to solve that. Let me know how it works out.