Questions tagged [nodemcu]

For questions about NodeMCU, an open source IoT platform which includes firmware for running on the ESP8266.

Filter by
Sorted by
Tagged with
21
votes
3answers
116k views

NodeMCU - Vin pin as 5V output?

I know that Vin can be used to power the board but have also been reading that it can be used as a 5V output. Is it possible to assign Vin as an output as I would any other GPIO? If I want to power ...
15
votes
4answers
27k views

ESP8266, Arduino IDE vs Lua?

I'm planning to buy an ESP8266. Do I really need to learn Lua to play with it? I have seen some people using it with the standard Arduino IDE. Do you need a custom firmware to use the Arduino IDE ...
14
votes
3answers
43k views

Does the Node MCU v3 (LoLin) not have a builtin led?

Trying a simple led blinking program I could not get the builtin led on a LoLin Node MCU v3 working. The LED_BUILTIN constant is set to pin 16 / GPIO16 / D0. Reading several articles and QA I think ...
13
votes
2answers
28k views

Difference between these two NodeMCU boards?

I recently received a NodeMCU (identical to the one shown in the first picture below) and originally, I was unable to connect it to my computer which eventually turned out to be driver issues; however,...
10
votes
5answers
24k views

NodeMCU - use flash button as input in loop()

I couldn't find a proper answer on the net so I came here as a last resort. So I want to use the FLASH button as an input in the loop() method. Is there a way the check if it's pressed or not?
9
votes
1answer
17k views

In ESP-12E NodeMCU, what's the pin number of A0?

In ESP-12E NodeMCU, all digital pins can be called with a number. Here is the list: static const uint8_t D0 = 16; static const uint8_t D1 = 5; static const uint8_t D2 = 4; static const uint8_t ...
8
votes
2answers
12k views

What is difference between NodeMCU and esp8266?

Since I have no previous experience in electronics I'm getting quite confused while coming across these two terms ..I'd like to know whether they're the same or different.
5
votes
2answers
32k views

How to determine Flash size?

I need to determine the flash size of my ESP8266 on my NodeMCU module in order to flash the AT firmware onto the board. Apparently different boards come with differently-sized flash memories. Can ...
5
votes
5answers
70k views

How to make a 5-volt relay work with NodeMCU?

I have hooked up 2 channel 5-volt relays with NodeMCU v1.0 as shown in the fritzing below. Relay are powered with a different power source than NodeMCU. As of now, I am powering the NodeMCU from my ...
5
votes
2answers
21k views

Simple GET request with ESP8266HTTPClient

I am trying to do a simple GET request. But I always get status code -1. Here is my complete code. #include <Arduino.h> #include <ESP8266WiFi.h> #include <ESP8266HTTPClient.h> ...
4
votes
2answers
7k views

Multiple libraries were found for “WiFiClient.h” using nodemcu

I am trying to send HTTP requests from nodemcu so I started by uploading the esp8266 library but when I run the following code #include <ESP8266HTTPClient.h> #include <ESP8266WiFi.h> ...
4
votes
1answer
849 views

NodeMCU wiring for Serial1?

I'm trying to get telemetry data to be sent out Serial1 on the NodeMCU board. I read that TX is (by default) mapped to pin D4. Ultimately, there will be a Raspberry that will be listening for ...
3
votes
4answers
32k views

ESP8266 not connecting to WiFi

I am trying to send the temperatures from an DS18B20 to ThingSpeak, using an ESP8266. You can see the code I am using for that. When I run the code I do not get any errors. In serial monitor it just ...
3
votes
1answer
5k views

NodeMCU does not boot up when GPIO pin is high

I have a NodeMCU board connected to a door and there is a micro switch that makes one GPIO pin (GPIO15 - D8 in this specific case) go high when the door opens. My problem is if I lose power while the ...
3
votes
3answers
23k views

Use 5V pH sensor with 3.3V NodeMCU

I'm trying to use a pH probe with NodeMCU, the problem is that NodeMCU is 3.3V and the pH analog sensor requires 5V, at first I thought using the VIN pin but didn't work, then I used the VU pin from ...
3
votes
1answer
2k views

Why Smart Plugs don't require setting port forwarding on router and how to accomplish this with NodeMCU (ESP8266)

I have a NodeMCU (ESP8266) board that I use to control some devices over the internet. To be able to access it I have to enable port forwarding on my router and set the port manually like in the image ...
3
votes
1answer
90 views

Correct way of having loop end when required?

I'm brand new to Arduinos. I'm currently trying to modify a script from here which at the moment, simply turns an LED on or off depending on which HTTP GET request it receives. However, I want to ...
3
votes
1answer
585 views

Why do ESP boards break out the SPI flash pins?

I have an ESP32 development board and a NodeMCU board here. Both breaking out the pins for the SPI flash of the ESP. These pins are mentioned in standard pinout descriptions as must/should not connect....
3
votes
1answer
4k views

Vin & VU pins of NodeMCU V3

Can we use the vin pin of the lolin v3 nodeMCU as a 5V supply. If yes, i checked mine with a multimeter. At max, it gives a voltage of 2V. Is my pin blown out? Also, can use the VU pin as a 5V supply? ...
3
votes
1answer
884 views

Flashing an ATtiny85 with a NodeMCU?

I recently purchased a Digispark for some of my smaller electronics projects. After it initially being a great little board, I soon found myself unable to flash the board in the same way I had done ...
3
votes
1answer
139 views

How to program Esp8266 remotly via wifi?

I hope it's not a sci-fi for arduino. But I saw that dual system with two MCU can program each other via radio connection. It has been done in experimental space cube projects. It is theoretically ...
3
votes
1answer
7k views

Turn off the second builtin Nodemcu 0.9 led

I'm making a low energy consumption device so I'd like to turn off all the led when I'm idle. Unfortunately the nodemcu turn on a blue led while I'm idle (during delay(ms)) Here is my code: #define ...
3
votes
1answer
111 views

Ultrasonic Sensor(HC-SR04) recording random distance

I am am trying to make a code which automatically controls relay on basis of ultrasonic sensor measurements. I am using a nodeMCU as a microcontroller rather than an arduino. The relay and the ...
3
votes
1answer
13k views

powering Nodemcu using Vin

Forgive me for this really dumb question. I am an amateur in electronics, and im trying to wrap up my head around this question and im not able to do so. Need your help. Im trying to power up a ...
3
votes
0answers
50 views

ESP8266 requires two resets to wake up from deep sleep

I'm working with the following circuit using a NodeMCU: I have the solder jumper bridged between RST and BTN. In addition to what's in the schematic, pins 2, 3, and 4 of J1 are connected to the ...
3
votes
0answers
4k views

How to flash pre-compiled bin files into NodeMCU using Ardunio IDE

How to flash pre-compiled binary into NodeMCU using Ardunio IDE. Since every time it require to compile and flash it. Is there way to flash binary alone to nodeMCU via Arduino IDE ? One can export ...
3
votes
0answers
325 views

Program nodeMCU Over the Air (OTA)

I have a Lolin NodeMCU V3 with a broken USB port: no power, no data. It does show up on WIFI as AI-thinker_xxx, I can connect, but what can I do next? Is there a way to program the NodeMCU Over the ...
2
votes
4answers
21k views

ESP8266 NodeMCU first WS2812 LED lights up green

I'm trying to power some WS2812 LEDs from my ESP8266 ESP-12E NodeMCU board (circuit here). I'm simply trying to use the NeoPixel Strandtest which works perfectly on my Arduino UNO with the same LED ...
2
votes
4answers
22k views

How to change the default name of ESP8266-12E module

Is there any way to change the default name (ESP_xxxxx) that the module generates?
2
votes
2answers
9k views

NodeMCU (Arduino IDE) 'DynamicJsonBuffer' was not declared in this scope

#include <Arduino.h> #include <ESP8266WiFi.h> #include <ESP8266WiFiMulti.h> #include <ArduinoJson.h> #include <ESP8266HTTPClient.h> #define USE_SERIAL Serial ...
2
votes
4answers
21k views

EEPROM put and get not working on ESP8266 (NodeMCU)

The Arduino documentation provides two examples to store data in the EEPROM. https://www.arduino.cc/en/Reference/EEPROMPut stores data in the EEPROM and the EEPROMGet example reads the data back and ...
2
votes
3answers
3k views

How to connect MPU9250 with NodeMCU using SPI or I2C Slave?

I want to connect 3 MPU9250 sensors, but since there is just one I2C bus, so there are another 2 sensors I want to connect through SPI. Library used - https://github.com/bolderflight/MPU9250/blob/...
2
votes
2answers
1k views

Setting pinMode(pin,input/output) as per user requirement

I am working on arduino IDE and esp8266 nodemcu. As i am going through the IDE I saw that there is a structure of void loop() and void setup() and all examples in the internet included defining the ...
2
votes
1answer
5k views

NodeMCU serial port - use with computer and device at the same time

I'm trying to understand how serial communication for ESP8266 in NodeMCU actually works. I found a quote saying that normal Serial is mapped to ports GPIO 1 (TX) and GPIO 3 (RX). They are even labeled ...
2
votes
2answers
93 views

esp2866 powered externally not working

I got a beginner level problem. I got two esp2866 nodeMCU, they both work with the usb cable and I can get the blink program to run though it. Running them with external power doesn't seem to work ...
2
votes
3answers
1k views

I2C interference SENSOR(SCL+SDA) and MasterSlave comm

I am building a weather station with an Arduino slave (dedicated to a rain gauge - depicted below as a reed switch) and a NodeMCU master with some additional sensors. One such sensor, a BMP280 uses ...
2
votes
3answers
6k views

Convert byte* to int in Arduino

I am trying to convert byte* value to int here is how I have it. void mqttCallback(char* topic, byte* payload, unsigned int length) { String topicStr = topic; int* payload_value; int ...
2
votes
1answer
5k views

nodeMCU - Millis() - Simple Counter - How long is LED on?

PROGRESS, now I have this (WITH GREAT HELP): void setup() { Serial.begin(9600); // initialize digital pin 13 as an output. } uint32_t timer_start = 0; int timer_running = false; void loop() { // ...
2
votes
1answer
5k views

ESP.deepSleep() - over and over?

Important note: the esp.deepsleep function uses microseconds, not milliseconds. I posted another question here asking for clarification on how an RTC can be used to put a NodeMCU 12 to sleep for a ...
2
votes
1answer
4k views

How to post JSON data from Arduino?

I want to post data that I'm getting from the sensor every 5 seconds to my application in JSON format. Initially, I'm getting data as int and converting into String. For example: if data=15, it is ...
2
votes
3answers
1k views

NodeMCU NeoPixel

I am attempting to control a single NeoPixel with a NodeMCU, but I'm not having any luck. Even just loading the default Adafruit NeoPixel library sketch yields unsuccessful results. I've tested the ...
2
votes
4answers
17k views

NodeMCU espcomm_sync failed

I have a NodeMCU ESP12E DevKit V2 from Geekcreit. I had it working some months ago, but now I cannot upload to it. I am using the arduino IDE and I've set the "Additional Boards Manager URLs"...
2
votes
1answer
1k views

ESP8266 Nodemcu create custom PWM with 1.25us resolution

I am trying to control some SMD LEDs WS2812B with the ESP8266-Nodemcu. I am using Arduino environment for coding. Actually I am trying to accomplish a PWM that is precisely able to: Go High for ...
2
votes
1answer
120 views

use Nodemcu to program Attiny85

I have a dev board for my attiny85. when connecting it to the computer I get "unknown USB device(device descriptor request failed)" although I have the needed drivers, so I thought of trying ...
2
votes
1answer
911 views

Lolin NodeMCU V3 and 5V sensors

I am new to Arduino and electronics so please correct me if I made a mistake. Many sensors and actuators require 5V. The Lolin NodeMCU V3 has outputs of 3.3V. I want to have them working together. ...
2
votes
1answer
2k views

NodeMCU second HARDWARE serial TX as a debug port

I'm using a NodeMCU board to send commands to my home electricity switching box - using RS485 communication. For that, I've connected MAX485 TTL-to-RS485 converter module to my TX and RX pins. ...
2
votes
1answer
82 views

I2C protocol doesn't work properly

I am trying to make I2C Communication between NodeMCU and arduino Uno boards. However it is not working properly. It makes communication for once time when i uploaded code. Master Device Code(NodeMCU ...
2
votes
1answer
64 views

Latency in Websocket

I am using Websocket, for a communication from my mobile phone to a NodeMCU, and transmitting 4 channel, data, through 4 different Websocket Ports. the NodeMCU control code is here: // ============ By ...
2
votes
1answer
174 views

Receiving garbage value when sending a Json object from Arduino Uno to NodeMCU using SoftwareSerial

I am trying to send a Json Object from Arduino UNO to NodeMCU using SoftwareSerial. I am using Arduino IDE. I am getting garbage value on Serial monitor of NodeMCU. Tried it with different garbage ...
2
votes
1answer
148 views

I am facing a problem of firing multiple interrupts on nodemcu 1.0 on single rising edge pulse.what is problem and what are the solutions?

I am working on a project which involves counting the drops falling in a drip chamber of a IV fluid gravity based therapy bottle(saline bottle).I am using IR trans-receiver at the drip chamber to ...

1
2 3 4 5
12