Skip to content
Snippets Groups Projects
Commit 198ffb44 authored by Eunchae Lee's avatar Eunchae Lee
Browse files

Update DHT11.c

parent 97684016
No related branches found
No related tags found
No related merge requests found
......@@ -9,7 +9,7 @@
#include <sys/socket.h>
#include <math.h>
#define MAX_READING 85 // 안정적으로 데이터를 읽기 위해 타이밍 85로 정의
#define MAX_TIME 85 // 안정적으로 데이터를 읽기 위해 타이밍 85로 정의
#define PIN 2 // PIN number for DHT11
// 서버 정보 정의
......@@ -118,7 +118,7 @@ void read_data()
pinMode(PIN, INPUT); // 센서로 부터 데이터를 받기 위한 준비가 되었음을 PIN을 input으로 설정
// 데이터 읽기
for (int i = 0; i < MAX_READING; i++)
for (int i = 0; i < MAX_TIME; i++)
{
count = 0;
// count the duration of each state
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment