Hardware Reference
In-Depth Information
Note
The code for this part can be found on the GitHub repository of the topic on the following
web page:
https://github.com/openhomeautomation/arduino-home-automation/tree/master/chapter5
You can now test the sketch. Please make sure that the device connected to the project is
completely off, so the initial zero current measurement can be done correctly by the Ardu-
ino board. Upload the code to your Arduino board and open the serial monitor. The fol-
lowing is what you should see:
Current amplitude (in mA):
0.8
Current effectivate value (in mA)
0.6
Effective power (in W):
0.1
You can also try to connect the device to your project now, turn it on, and launch the
sketch again. You should see the power measurement changing instantly:
Current amplitude (in mA):
17.8
Current effectivate value (in mA)
12.6
Effective power (in W):
28.9
Search WWH ::




Custom Search