Questions tagged [nodemcu]

NodeMCU is an open-source firmware that offers a Lua API for ESP8266, ESP8285, and ESP32. There is also a ESP8266 devkit with the same name. However, questions here should relate to writing Lua code on top of the firmware. Also if you need help understanding the NodeMCU API SO is the right place. Issues with firmware development are best addressed on GitHub. Hardware or general questions can be asked on esp8266.com.

The NodeMCU project is a Lua based firmware that runs directly on ESP8266, ESP8285, and ESP32 hardware, providing a easy and low cost solution. Build-deploy-test cycles are extremely short (contrary to e.g. Arduino) because you only build the firmware once and then simply update scripts on the device.

It provides access to almost all APIs in the Espressif C SDK. Hardware/SDK access is abstracted through close to 60 specific modules. The firmware comes with either integer or floating point support depending on your needs.

975 questions
3
votes
0 answers

Error when implement an nodemcu 8266 with DHT22

I implemented a nodemcu 8266 as a api rest server with a temperature sensor (DHT22) in a Mac with macOS Monterey, when I read the temperature and humidity in a simple loop I don't have any problem, the implementation looks like this #include…
Felipe Pincheira
  • 442
  • 1
  • 6
  • 21
3
votes
0 answers

Sending Deauthentication Packets by esp8266

I am trying to implement a simple WiFi deauther using my nodemcu but i can't see any disconnection b/w AP(my android's hotspot) & Station ( my second android device) But when i am using a third party tool like Wi-PWN ( available on GitHub ) , is…
Golu
  • 350
  • 2
  • 14
3
votes
1 answer

Analyze ESP32 backtrace on NodeMCU

I'm debugging some crashes on the dev-esp32 branch of the NodeMCU Lua firmware. How do you other NodeMCU devs analyze the backtraces? During normal ESP32 dev the idf monitor handles decoding the backtrace. I've tried to use the IDF monitor with my…
Kit Klein
  • 31
  • 3
3
votes
0 answers

ESP8266 DNS Lookup with Hostname ending in ".local"

Three or more years ago, I made an Arduino project for a NodeMCU (ESP8266) that connected to my MQTT server. I needed to make some changes to the code (unrelated), rebuilt, and was unable to connect to my MQTT server! After doing some…
Jaron
  • 133
  • 6
3
votes
1 answer

Understanding IR codes for Samsung TV

Can somebody help me to understand how could I use RAW IR data in an project using ESP8266-HTTP-IR-Blaster library ? I've created a NodeMCU board with an IR sender and receiver according to…
Zsolt Németh
  • 33
  • 1
  • 1
  • 4
3
votes
1 answer

Node mcu (1.0) ESP8266 12E doesn't respond after IDLE time in soft AP mode

I am trying to set up node mcu as Access Point with static IP. I am able to connect to the AP using tcp sockets and receive response from it. However, if the client is not connected to it for a certain amount of time, node MCU doesn't respond at…
zero
  • 150
  • 1
  • 16
3
votes
0 answers

How to fix "WiFi is not declared on the scope."?

In my code I am receiving a "Wifi is not declared in this scope" error when compiling to a NodeMCU board. The code has some customization, but regarding the WiFi and lines where it calls Wifi functions, it has the same structure to the source…
Vinicivs
  • 191
  • 1
  • 7
3
votes
2 answers

How to structure my sensor data when sending to Firebase from NodeMCU?

I have sent my DHT sensor data from my NodeMCU to Firebase with the following code. void loop() { if(timeSinceLastRead > 2000) { float h = dht.readHumidity(); float t = dht.readTemperature(); float f = dht.readTemperature(true); if…
3
votes
3 answers

CORS issue in nodemcu esp8266

Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://192.168.100.2:8100' is therefore not allowed access. The response had HTTP status…
Sachin
  • 2,627
  • 1
  • 19
  • 35
3
votes
1 answer

How to capture HTTPS requests with espconn?

The following code allows to capture all requests coming to my esp8266 (running NodeMCU) and show my own page: static int enduser_setup_dns_start(void) { state->espconn_dns_udp = (struct espconn *) c_malloc(sizeof(struct espconn)); esp_udp…
LA_
  • 19,823
  • 58
  • 172
  • 308
3
votes
3 answers

Lua SSL certificate and Azure Iot hub

I am trying to connect my NodeMCU ESP-12N to Azure IoT hub. I have created client with code like this: esp8266 = mqtt.Client(DEVICE, 240, USER, PASSWD) and receiving error on calling esp8266:connect PANIC: unprotected error in call to Lua API…
Alexej Sommer
  • 2,677
  • 1
  • 14
  • 25
3
votes
1 answer

I need help connecting an ESP8266 to a local Java server using websockets

I downloaded a simple Java websocket echo server running on my PC (Windows 10). The app runs on a local Tomcat server (my PC's IP address is 192.168.178.10). To start the app in a browser the command used is: http://localhost:8080/echochamber/ It…
Nico Verduin
  • 59
  • 1
  • 6
3
votes
2 answers

ESP8266 - PubSubClient - Message character limit

I am unable to send messages over a certain limit. I have looked at the docs and have already tried to redefine the max packet size: #define MQTT_MAX_PACKET_SIZE 512 I've even tried increasing the limit to ridiculous limits and still the message is…
Timmo
  • 2,266
  • 4
  • 34
  • 54
3
votes
2 answers

I2C scan with Micropython and NodeMCU 12E returns empty list

I'm trying to hook up a MPU6050 with my NodeMCU board with Micropython flashed in it. My current wiring is the following: MPU6050 Board Vcc 3.3v Gnd Gnd SDA D6 SCL D7 Through the command line, I've tried the…
magicleon94
  • 4,887
  • 2
  • 24
  • 53
3
votes
0 answers

secure websocket (wss) not working in nodemcu

I am trying to send data to cloud using secure websocket (wss). The cloud interface only allows secure websocket ( HTTP, non-secure websocket etc are not allowed) I tried the latest master,dev builds from nodemcu-build.com , but there SSL is…
Kiran
  • 119
  • 1
  • 9
1 2
3
64 65