-
Notifications
You must be signed in to change notification settings - Fork 7
/
NodeMCU-notes.txt
41 lines (33 loc) · 1.1 KB
/
NodeMCU-notes.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
--------------------------------------------------------------------------------
+++ ESP8266 ESP-12E NodeMCU notes
+ Version I'm using:
++ ESP8266 ESP-12E NodeMCU Lua V3 CH340G WIFI Lua Wireless Development Board Module.
++ Bought from eBay
https://en.wikipedia.org/wiki/NodeMCU
--------------------------------------------------------------------------------
+++ Infrared reader for ESP8266 NodeMCU
https://www.instructables.com/id/Universal-Remote-Using-ESP8266Wifi-Controlled/
+ Select "Include Library" from there select "Manage libraries"
++ Search for "IRremoteESP8266" and install it. I installed version 2.6.3.
------------------------
// Infrared settings
#include <IRremoteESP8266.h>
#include <IRrecv.h>
#include <IRutils.h>
int IR_PIN = 13; // Pin D7
IRrecv irrecv(IR_PIN);
decode_results results;
------------------------
void setup() {
...
irrecv.enableIRIn();
}
void loop() {
...
if (irrecv.decode(&results)) {
serialPrintUint64(results.value, 16);
irrecv.resume();
}
}
------------------------
--------------------------------------------------------------------------------