
AT32 Printf Debug Demo
2019.08.05
19
Rev 1.0.2
2.5.4.4 Printf function supports code addition
#pragma import(__use_no_semihosting)
struct __FILE
{
int handle;
};
FILE __stdout;
_sys_exit(int x)
{
x = x;
}
2.5.5 Debug and download
Compile the code and download it into the MCU, and run the code at full speed, you can find that
the
“Hello World” is displayed in the terminal interaction window. (Figure 9)
Figure 9. Serial port interaction window