It's now time to finally test the project! You can of course grab the complete code from the GitHub repository of the project:
https://github.com/openhomeautomation/power-meter-esp8266
Make sure to modify the code to include your own WiFi name and password, and also your Adafruit IO credentials.
You can now upload the code to the board. Make sure that you selected the correct board (Adafruit HUZZAH ESP8266) inside the Arduino IDE.
You should observe the following result on the board:
Now, remember that the project is also sending data to Adafruit IO! To visualise the incoming data sent by the board, log into Adafruit IO, and navigate to the 'feeds' menu. You should see a feed called 'power', as this is the name we set inside the code.
If you visualise the feed from Adafruit IO, it should like the following graph, as the LED is switching on & off continuously:
Before ending this guide, I will show you how to actually display the current power consumption of the device inside a dashboard. For that, open a dashboard on Adafruit IO or create a new one, and create a text block:
After that, link this block to the 'power' feed:
You should now see the instant consumption of the device connected to your project. For example, you should see 0.00 when the LED is off:
This is the same text block, showing the power consumption when the LED is on:
Text editor powered by tinymce.