int result = 0;
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
randomSeed(analogRead(0));
}
void loop() {
// put your main code here, to run repeatedly:
if(result == 0){
int i;
for(i=1; i<=10; i++){
delay(1000);
Serial.println( random(66,100));
}
result+=1;
}
}
'arduino_' 카테고리의 다른 글
sds011 - 먼지 센서 (0) | 2017.09.21 |
---|---|
데이터 사이즈 (0) | 2017.09.21 |
illumination_sensor (조도센서) (0) | 2016.02.13 |
아놀로그 핀 디지털 핀으로 대체 가능함 (0) | 2016.02.13 |
랜덤으로 30개의 숫자를 만들고 짝수일때 빨간 홀수일때 블루 (0) | 2016.02.13 |