添加相应的头文件即可。IAR中使用printf()函数和允许位定义的方法⑴使用printf()函数:①包含头文件②编写putchar函数示例:int putchar(int c){while (!(UCSRA & 0x20));return (UDR=c);}③设置Option