Look at the effect first
Start teaching
Since this is my first time writing this configuration tutorial, I will try to be as detailed as possible.
Open a Keil project
Remove local core Add online core
There will be no errors when compiling the code for the first time.
Modify main.c file type to C++
Click the magic wand to change the ARM compiler to V6
The second compilation will report an error syntax incompatibility.
I shielded these codes in the assembly part (no need for lazy ovo)
Added redirect code
After the modification, the error was resolved after compiling for the third time.
Link C functions (C++ cannot call C functions directly)
Write a test code and send it to the serial port assistant for viewing
C++ syntax test class
Configure printf output
Use cout output
expand
If you use cout, it will not be too good for the memory of the microcontroller. Compile the two codes and see the memory size.
Data acquisition
Click below~