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

Voltage measurement up to 500 volts #113

Closed
amir-eshaqy opened this issue Jul 30, 2023 · 2 comments
Closed

Voltage measurement up to 500 volts #113

amir-eshaqy opened this issue Jul 30, 2023 · 2 comments

Comments

@amir-eshaqy
Copy link

Hello,
I managed to measure the voltage of 500 volts with the resistance value of R17 to 1.8 megaohm without error in the frequency, but I had a problem in setting the voltage multiplier to show the correct result on the display. The voltage conversion factor is 1333.33 in normal mode but with change The resistance value of R17 is 1.8 megaohm, this value is changed to 2400. How can I apply this coefficient change in the program?

@mandulaj
Copy link
Owner

mandulaj commented Aug 1, 2023

Hey,
The PZEM chip already returns the converted voltage directly in the response message. If you change the resistance value, you will have to manually scale the voltage by the appropriate coefficient. You could do something like this:

const float VOLTAGE_SCALE_FACTOR = <the scale factor>;
float voltage = pzem.voltage() * VOLTAGE_SCALE_FACTOR;

From what you say it sounds like the conversion factor should be 2400/1333 = 1.8 but you will have to double check that.

@amir-eshaqy
Copy link
Author

Hey, The PZEM chip already returns the converted voltage directly in the response message. If you change the resistance value, you will have to manually scale the voltage by the appropriate coefficient. You could do something like this:

const float VOLTAGE_SCALE_FACTOR = <the scale factor>;
float voltage = pzem.voltage() * VOLTAGE_SCALE_FACTOR;

From what you say it sounds like the conversion factor should be 2400/1333 = 1.8 but you will have to double check that.

Thank you, I will definitely check

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

2 participants