This file contains hidden or 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 <ESP8266WiFi.h> | |
void setup() { | |
Serial.begin(115200); | |
String clientMac = ""; | |
unsigned char mac[6]; | |
WiFi.macAddress(mac); | |
clientMac += macToStr(mac); | |
Serial.println(); | |
Serial.println(clientMac); |
This file contains hidden or 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 <ESP8266WiFi.h> | |
#include <PubSubClient.h> | |
#include <DHT.h> | |
// DHT settings | |
#define DHTTYPE DHT11 | |
const int buttonPin = 14; | |
int buttonState = 0; | |
const int DHTPIN = 12; | |
DHT dht(DHTPIN, DHTTYPE); |
This file contains hidden or 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
let sum_x: number = 0; | |
let sum_y: number = 0; | |
let sum_xy: number = 0; | |
let sum_xx: number = 0; | |
let count: number = 0; | |
/* | |
* We'll use those variables for faster read/write access. | |
*/ | |
let x: number = 0; |