通过Arduino编译器查看串口数据。
hello world程序:
void setup(){
Serial.begin(9600);//打开串口,设置波特率为9600bps
}
void loop(){
Serial.println("Hello World");
delay(1000);
}
编译、上传,然后打开编译器的Serial Monitor,即可看到输出的“Hello World”
运行结果:
通过Arduino编译器查看串口数据。
hello world程序:
void setup(){
Serial.begin(9600);//打开串口,设置波特率为9600bps
}
void loop(){
Serial.println("Hello World");
delay(1000);
}
编译、上传,然后打开编译器的Serial Monitor,即可看到输出的“Hello World”
运行结果: