This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <hellomake.h> | |
int main() { | |
// call a function in another file | |
myPrintHelloMake(); | |
return(0); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC=gcc | |
CFLAGS=-I. | |
DEPS = hellomake.h | |
%.o: %.c $(DEPS) | |
$(CC) -c -o $@ $< $(CFLAGS) | |
hellomake: hellomake.o hellofunc.o | |
gcc -o hellomake hellomake.o hellofunc.o -I. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC=gcc | |
CFLAGS=-I. | |
hellomake: hellomake.c hellofunc.c | |
$(CC) -o hellomake hellomake.c hellofunc.c -I. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC=gcc | |
CFLAGS=-I. | |
hellomake: hellomake.o hellofunc.o | |
$(CC) -o hellomake hellomake.o hellofunc.o -I. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC=gcc | |
CFLAGS=-I. | |
DEPS = hellomake.h | |
OBJ = hellomake.o hellofunc.o | |
%.o: %.c $(DEPS) | |
$(CC) -c -o $@ $< $(CFLAGS) | |
hellomake: $(OBJ) | |
gcc -o $@ $^ $(CFLAGS) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IDIR =../include | |
CC=gcc | |
CFLAGS=-I$(IDIR) | |
ODIR=obj | |
LDIR =../lib | |
LIBS=-lm | |
_DEPS = hellomake.h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "ThingSpeak.h" | |
#include <ESP8266WiFi.h> | |
#include <DHT.h> | |
//---------------- Fill in your credentails --------------------- | |
char ssid[] = "xxx"; // your network SSID (name), tên wifi | |
char pass[] = "xxxxx"; // your network password, password | |
unsigned long myChannelNumber = 1; // Replace the 0 with your channel number, channel của bạn | |
const char * myWriteAPIKey = "xxxxx"; // Paste your ThingSpeak Write API Key between the quotes, write API key | |
//------------------------------------------------------------------ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Chương trình đọc nhiệt độ, độ ẩm từ cảm biến DHT | |
Thêm chức năng đọc cảm biến ánh sáng | |
Thêm chức năng đọc cảm biến độ ẩm đất | |
Thêm hiển thị LCD | |
Thêm chức năng điều khiển tưới tiêu với bơm và điều khiển nhiệt với đèn | |
HocARM NDTR BOT for ESP8266 by hocARM.org | |
------------------------------------------------- | |
// Chương trình đọc nhiệt độ, độ ẩm từ cảm biến DHT | |
// Thêm chức năng đọc cảm biến ánh sáng | |
// Thêm chức năng đọc cảm biến độ ẩm đất |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Chương trình đọc nhiệt độ, độ ẩm từ cảm biến DHT | |
Thêm chức năng đọc cảm biến ánh sáng | |
Thêm chức năng đọc cảm biến độ ẩm đất | |
Thêm hiển thị LCD | |
Thêm chức năng điều khiển tưới tiêu bằng tay 2 bơm | |
HocARM NDTR BOT for ESP8266 by hocARM.org | |
// Kết nối | |
// DHT | ESP8266 | |
//--------------------------- | |
// VCC(1) | 3.3V |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Chương trình đọc nhiệt độ, độ ẩm từ cảm biến DHT | |
Thêm chức năng đọc cảm biến ánh sáng | |
Thêm chức năng đọc cảm biến độ ẩm đất | |
Thêm hiển thị LCD | |
Thêm chức năng điều khiển tưới tiêu bằng tay 2 bơm | |
HocARM NDTR BOT for ESP8266 by hocARM.org | |
------------------------------------------------- | |
// Chương trình đọc nhiệt độ, độ ẩm từ cảm biến DHT | |
// Thêm chức năng đọc cảm biến ánh sáng | |
// Thêm chức năng đọc cảm biến độ ẩm đất |