What do I need?

  • 1 NodeMCU-compatible board with ESP8266 (e.g. NodeMCU 1.0 devkit)
  • 1 MPU6050 accelerometer
  • 3 LED (red, yellow, blue)
  • 3 resistors (100~180 Ohm)
  • Some “dupont jumper” cables
  • 1 breadboard

A shopping list?

Here it is! Attention: some sellers offer multiple items in packages, but quantities needed are those indicated above

How to assemble everything?

This is the wiring:


Steps are:

  1. Place the NodeMCU on top of the breadboard straddling the two zones (the breadboard has two “zones”, separated by a groove)
  2. Place the MPU6050 sensor in an area of the breadboard so that its pins are on different lines than those occupied by the NodeMCU pins
  3. Position the three LEDs on three different lines (which are not already used by the NodeMCU or MPU6050 sensor), across the breadboard deck. Remember that in the LEDs the shortest pin is the negative (and therefore must be put, as in the diagram, towards GND) while the longest pin towards the positive (i.e.D5, D6 or D7 depending on the color.
  4. Insert the three resistors (no matter the direction) with a pin on the same row and same area of the negative of the LEDs (one for each LED), and with the other on the same row of one of the GND pins of the NodeMCU
  5. Insert the dupont cables to connect D5, D6 and D7 to the respective colored LEDs in the area and in the row of the breadboard corresponding to the longest pin of the LED in question (e.g. a dupont cable between D5 and the row with the positive pin of the green LED)
  6. Insert the dupont cables to connect VCC, GND, SDA and SCL of the MPU6050 to pins 3V3, GND, D1 and D2 of the NodeMCU respectively

The software

Now you need to load the software: follow the instructions according to your platform!

Windows

  1. Download the tool “NodeMCU Flasher”: 64 bit version or 32 bit version.
  2. Download the NodeMCU driver from this link, decompress the ZIP and launch the installer
  3. Download the sensor firmware from this link
  4. Plug your NodeMCU in your PC
  5. Open the software “NodeMCU flasher” and choose the NodeMCU serial port
  6. Open the “Config” tab and choose the firmware file that you just downloaded
  7. Go back to the “Operation” tab and press “Flash”. At the end of the procedure you can unplug your device and place it wherever you want!
  8. Once powered on, the device will create a WiFi network named “SeismoCloud”. Join this WiFi network, a configuration panel will appear where you can configure the WiFi settings for your WiFi network (e.g. add SSID and password). Once saved, the device will reboot and it will connect to the WiFi.
  9. Connect the mobile phone to the same WiFi network as the sensor, open the SeismoCloud app and press the button with the “+” symbol: the app will find the new sensor and allow you to configure its position and name :-)

Done!