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
modbus: | |
- name: "HONEY_MODBUS_IO" | |
type: tcp | |
host: 192.168.1.180 | |
port: 502 | |
delay: 5 | |
timeout: 2 | |
switches: | |
- name: "Y0" | |
address: 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
#include <HONEYLemon.h> | |
#include <WiFiClientSecure.h> | |
#include <ArduinoJson.h> | |
#define WIFI_SSID "HONEYLab" // ตั้งค่าชื่อ WiFi | |
#define WIFI_PASS "@HONEYLab" // ตั้งค่ารหัสผ่าน WiFi | |
int Confirmed = 0,Recovered = 0,Hospitalized = 0,Deaths = 0,NewConfirmed = 0,NewRecovered = 0,NewHospitalized = 0,NewDeaths = 0; | |
String UpdateDate = ""; |
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
[ | |
{ | |
"id": "772c7624.918b58", | |
"type": "http request", | |
"z": "44982414.c5c8fc", | |
"name": "line notify", | |
"method": "POST", | |
"ret": "obj", | |
"paytoqs": false, | |
"url": "https://notify-api.line.me/api/notify", |
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
var message = "\nอับเดทล่าสุด: "+msg.payload.UpdateDate+"\n"; | |
message += "ผู้ติดเชื้อสะสม: "+msg.payload.Confirmed+" ( "+msg.payload.NewConfirmed+" )\n"; | |
message += "หายแล้ว: "+msg.payload.Recovered+" ( "+msg.payload.NewRecovered+" )\n"; | |
message += "รักษาอยู่: "+msg.payload.Hospitalized+" ( "+msg.payload.NewHospitalized+" )\n"; | |
message += "เสียชีวิต: "+msg.payload.Deaths+" ( "+msg.payload.NewDeaths+" )\n"; | |
msg.payload = message; | |
return msg; |
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
msg.headers = { | |
'content-type':'application/x-www-form-urlencoded', | |
'Authorization':'Bearer 0m1BK0Nn1KoFLG38vZG6RI9YoV9FZro5bYBWTH8yMDJ' | |
}; | |
msg.payload = { | |
"message":msg.payload | |
}; | |
return msg; |
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
var google_sheet_key = "1cKJitUdOQtGzUkurXhgsxY3_MON7wV9cguLGs5JC3hE"; | |
var google_sheet_name = "แผ่น1"; | |
function doGet(e){ | |
var sheet = SpreadsheetApp.openById(google_sheet_key).getSheetByName(google_sheet_name); | |
var temp = Number(e.parameter.temp); | |
var humi = Number(e.parameter.humi); | |
sheet.appendRow([new Date(),temp,humi]); | |
} |
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 <WiFi.h> | |
#include <iSYNC.h> | |
WiFiClient client; | |
iSYNC iSYNC(client); | |
String ssid = "HONEYLab"; | |
String pass = "@HONEYLab"; | |
String iSYNC_USERNAME = "admin"; |
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
/* | |
* By JackRoboticS | |
* www.jackrobotics.me | |
*/ | |
#include "Wire.h" | |
TwoWire WIRE(0); | |
byte ADDRESS_PCF8574 = 0B0100000 | 0B000; //address 000 | |
//byte ADDRESS_PCF8574 = 0B0100000 | 0B001; //address 001 |
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
/* | |
* By JackRoboticS | |
* www.jackrobotics.me | |
*/ | |
#include <Wire.h> | |
byte ADDRESS_PCF8574 = 0B0100000 | 0B000; //address 000 | |
//byte ADDRESS_PCF8574 = 0B0100000 | 0B001; //address 001 | |
//byte ADDRESS_PCF8574 = 0B0100000 | 0B010; //address 010 |
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
private void notifyPicture(string url) | |
{ | |
_lineNotify(" ", 0, 0, url); | |
} | |
private void notifySticker(int stickerID, int stickerPackageID) | |
{ | |
_lineNotify(" ", stickerPackageID, stickerID, ""); | |
} | |
private void lineNotify(string msg) | |
{ |
NewerOlder