Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Power output not correct #2

Open
EvertDekker opened this issue Apr 18, 2021 · 2 comments
Open

Power output not correct #2

EvertDekker opened this issue Apr 18, 2021 · 2 comments

Comments

@EvertDekker
Copy link

Hi,

Thanks for you library.
I'm testing it with a very simple Arduino program on an Esp32.

#include <ATM90E32.h>

#define LINE_FREQ_DEFAULT 135 //(50Hz)
#define CURRENT_GAIN_DEFAULT 11131
#define PGA_GAIN_DEFAULT 0
#define VOLTAGE_GAIN 10692

ATM90E32 energy_meter1{};

void setup() {
  Serial.begin(115200);
  energy_meter1.begin(4, LINE_FREQ_DEFAULT, PGA_GAIN_DEFAULT, VOLTAGE_GAIN, CURRENT_GAIN_DEFAULT, CURRENT_GAIN_DEFAULT, CURRENT_GAIN_DEFAULT);
}

void loop() {
  Serial.print(energy_meter1.GetLineVoltageA());
  Serial.println(" V");
  Serial.print(energy_meter1.GetLineCurrentA());
  Serial.println(" A");
  Serial.print(energy_meter1.GetActivePowerA());
  Serial.println(" W");
  Serial.println();
  delay (3000);
}

After setting the calibration the V and A will be display correct, however the Active power is a way of.
With a 60W lightbulb connected this is my output:
228.78 V
0.26 A
1241.74 W

What's going wrong that the Active power is a factor 20 higher, but the Volt and Amp matches the expectations.

@swaraj835
Copy link

yess even i am facing same issue can someone help???

CircuitSetup added a commit that referenced this issue Sep 30, 2022
Merge circuit setup changes to upstream.
@RamyaDidde
Copy link

Are you able to read the Power @swaraj835 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants