Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


You are viewing a reply to How to C++ project for dummies  

How to C++ project for dummies

There’s a few tutorials kicking around here; I followed them and am working with C++ and CubeMX generated projects just fine.

Here’s a couple of points you’re not going to get until you do some reading.

(1) C and C++ link differently. C++ uses a thing called name mangling. You need to be careful in keeping your C and C++ code in separate sources files if you can manage it. Google for the exact phrase ‘extern “C” and calling C from C++’ and you will get hours of relevant reading material.

(2) if you’re using CubeMX, don’t fight the code generator; note the “user code goes here” sections, put your C++ code in a different folder and add that folder to your includes in the compiler settings. You’ll have much more success if you do that because then you can regenerate your code with CubeMX without mangling all the work you did to get the C++ linkage working.

I will see if I can do a simple “hello world” c++ example at some point because I have a project template that’s working well for me now.