Node MCU
Posted: Fri Jan 27, 2023 11:49 am
I am trying to interface HLW8032 with NodeMCU. I uploaded the code from examples on to the microcontroller but i am getting the garbage values on serial monitor.
When i tried getting the data on hercules. I am getting Hexadecimal values. Can you guys please suggest me a few ways to get the required output.
The code i referred is :
#include "HLW8032.h"
HLW8032 HL;
void setup()
{
HL.begin(Serial,4);
Serial.begin(4800);
Serial.swap();
}
void loop()
{
HL.SerialReadLoop();
if(HL.SerialRead == 1)
{
Serial.println(HL.GetVol());
}
}
also, guys i used the module:
https://www.dnatechindia.com/hlw-8032-s ... odule.html
When i tried getting the data on hercules. I am getting Hexadecimal values. Can you guys please suggest me a few ways to get the required output.
The code i referred is :
#include "HLW8032.h"
HLW8032 HL;
void setup()
{
HL.begin(Serial,4);
Serial.begin(4800);
Serial.swap();
}
void loop()
{
HL.SerialReadLoop();
if(HL.SerialRead == 1)
{
Serial.println(HL.GetVol());
}
}
also, guys i used the module:
https://www.dnatechindia.com/hlw-8032-s ... odule.html