stuff you would need to play with a nodemcu (ESP8266) iot device
$ git clone https://github.com/henrythasler/nodemcu.git
$ cd nodemcu
$ git remote add nodemcu https://github.com/henrythasler/nodemcu.git
// do something
$ git add .
$ git commit -a
$ git push nodemcu master
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash -
sudo apt install nodejs
init.lua- Main script. Handles Wifi connection and calls other modulesconfig.lua- all config data is stored in this file
flashdaemon.lua- lua-script to handle file uploads, commands. Run that file on your nodemcu after wifi is connected.flash.js- nodejs-script to upload files to nodemcustatus.lua- generate status.html on nodemcu.
$ nodejs flash.js ./../config.lua
Preparing ./../config.lua
Prepared 2 chunks. Connecting...
Connected to nodemcu
sending chunk with 634 Bytes...
ok
sending chunk with 35 Bytes...
ok
Finished upload
Disconnected from nodemcu
temperature.lua- convert reading from ADC0 to temperature value and send result to MQTT broker.
httpserver.lua- provides sensor data as JSON.