|
|

楼主 |
发表于 2014-11-2 10:04:56
|
显示全部楼层
自己坐个板凳吧,把代码改了一下,用公共变量还是空
char val=0;
char run_0(char a,char b){
val=a+b;
return val;
}
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
}
void loop() {
Serial.print("runt=");
Serial.print(run_0(3,4));
Serial.print("runt2=");
Serial.println(val);
delay(500);
// put your main code here, to run repeatedly:
}
只能等高人指点了! |
|