12

I am trying to connect Apple homekit to nodemcu board, I found a tutorial which works on my computer, but I am wonder if there is any way to load and run Node.JS on a NodeMCU board (ESP8266)?

mpromonet
  • 11,326
  • 43
  • 62
  • 91
jezuz
  • 413
  • 2
  • 5
  • 13
  • Which OS are you running on it? – Dai Aug 30 '15 at 20:52
  • In the nodeMCU I´m running the following firmware http://nodelua.org/assets/uploads/2014/12/nodelua_8266.fw And my desktop is running MacOS10.9 – jezuz Aug 30 '15 at 21:00
  • I would like to implement this https://github.com/KhaosT/HAP-NodeJS on nodeMCU board – jezuz Aug 30 '15 at 21:03

2 Answers2

28

You can run Espruino on it. I have the HiLetgo NodeMCU ESP-12E Module and was easily able to load the firmware.

  1. Download and install flasher https://github.com/thingsSDK/flasher.js
  2. Press and hold the flash button press the reset button once. It will flash once.
  3. Open up flasher app and flash the firmware for Espruino.
  4. Unplug the esp8266 and plug it back in
  5. download the web ide for Espruino https://chrome.google.com/webstore/detail/espruino-web-ide/bleoifhkdalbjfbobjackfdifdneehpo?hl=en
  6. Change the baud rate Settings --> Communications --> Baud Rate 115200
  7. Connect and enjoy!

Some samples to try out

https://github.com/mertenats/NodeMCU-and-JavaScript

Jesse
  • 1,846
  • 2
  • 22
  • 32
6

I think you're confusing nodemcu, which is a firmware for the ESP8266 boards that interprets the language lua, with the javascript runtime node.js, which runs on computers.

So, the answer is you cannot run node.js on an ESP8266.

user1816847
  • 1,877
  • 3
  • 17
  • 29
  • I think you are right. I will try to use raspberry as a server and ESP8266 as client. Thanks! – jezuz Oct 05 '15 at 19:41