alcar21 / WemosEM

Cheap power monitor (STC013) with Home Assistant Discover and Wemos D1 Mini / PRO (esp8266)
113 stars 23 forks source link

Monitor the Mains? #14

Closed rechena closed 3 years ago

rechena commented 3 years ago

Can I use this board code to monitor my house at the mains board? Thanks

alcar21 commented 3 years ago

yes of course.

Regards Alfonso C.

El dom., 20 sept. 2020 a las 18:55, Joao Rechena (notifications@github.com) escribió:

Can I use this board code to monitor my house at the mains board? Thanks

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSMKC4PGFUJUTTJCZTTSGYXYRANCNFSM4RTXPGLA .

rechena commented 3 years ago

Thanks for the reply. I had a old system using an arruino uno and Xbee but this makes it so much better :) One thing though on mine I was measuring using an AC/AC transformer for the current, would it be possible to do the same somehow on yours? Thanks

alcar21 commented 3 years ago

Yes, you can measure AC by putting the clamp on one phase. You only need a transformer to power the ESP8266

rechena commented 3 years ago

Thanks I was more asking about using this approach - https://learn.openenergymonitor.org/electricity-monitoring/ctac/how-to-build-an-arduino-energy-monitor. But That would need some changes on the board. Regardless, do you have any link to help with the calculation of the icalc? Thanks

alcar21 commented 3 years ago

Yes, please, visit this url: http://lechacal.com/wiki/index.php/Current_Transformer_Conditioner

Un saludo, Alfonso C.

El vie., 2 oct. 2020 a las 12:02, Joao Rechena (notifications@github.com) escribió:

Thanks I was more asking about using this approach - https://learn.openenergymonitor.org/electricity-monitoring/ctac/how-to-build-an-arduino-energy-monitor. But That would need some changes on the board. Regardless, do you have any link to help with the calculation of the icalc? Thanks

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-702640824, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSPDPI7FLTA2BQ2SBQDSIWQKRANCNFSM4RTXPGLA .

rechena commented 3 years ago

Hi, I'm a bit confused on whats happening, I finally got around to install this, ufortunately I had to install the CT on the Neutral since the Live is too short, regardless, from what I read it won't make a difference. The concern is, looking at the house in "standby" I'm reading around 146W, which I love it being so low, but.. when I turn on my kettle which is 2500/3000W, the Watts only increase to 568W... I have a SCT-013-030 and I've calibrated the iCalc to 30.0... I've measured my Voltage with a Multimeter and its giving me 233V.

Can you think if anything I might be doing wrong?

Thanks

alcar21 commented 3 years ago

yes, all ok. it's strange.

Please, Can you probe a toaster or a hair dryer?

Thank you.

El dom., 4 oct. 2020 a las 13:52, Joao Rechena (notifications@github.com) escribió:

Hi, I'm a bit confused on whats happening, I finally got around to install this, ufortunately I had to install the CT on the Neutral since the Live is too short, regardless, from what I read it won't make a difference. The concern is, looking at the house in "standby" I'm reading around 146W, which I love it being so low, but.. when I turn on my kettle which is 2500/3000W, the Watts only increase to 568W... I have a SCT-013-030 and I've calibrated the iCalc to 30.0... I've measured my Voltage with a Multimeter and its giving me 233V.

Can you think if anything I might be doing wrong?

Thanks

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-703244352, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSL4BGUXNC7RK5YZHALSJBOZNANCNFSM4RTXPGLA .

rechena commented 3 years ago

I would gladly but unfortunately it was so hard to had the CT to the main's board that if I remove it it will break :( need to order a new one and then I can test. I was just wondering if you noticed something similar... Guess I need to buy a new CT and test it... :(

alcar21 commented 3 years ago

it's not necessary. You connect the hairdryer o the toaster in a socket and test.

El lun., 5 oct. 2020 a las 9:54, Joao Rechena (notifications@github.com) escribió:

I would gladly but unfortunately it was so hard to had the CT to the main's board that if I remove it it will break :( need to order a new one and then I can test. I was just wondering if you noticed something similar... Guess I need to buy a new CT and test it... :(

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-703466644, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSJJREWP42Y7V64C3PLSJF3U3ANCNFSM4RTXPGLA .

rechena commented 3 years ago

I've just tested both ways, with the socket and directly with just the hairdryer, and its reporting only ~400W for a 1800-2200W hairdryer :(

IMG_6901

alcar21 commented 3 years ago

Please, Can you post images of your configuration?

rechena commented 3 years ago

Of the d1mini and all the components?

alcar21 commented 3 years ago

Only configuration calibration tab of wemos d1 mini. this:

[image: image.png]

El lun., 5 oct. 2020 a las 12:11, Joao Rechena (notifications@github.com) escribió:

Of the d1mini and all the components?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-703536612, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSNDVZ3XA2MAS57HCQ3SJGLVXANCNFSM4RTXPGLA .

alcar21 commented 3 years ago

image

rechena commented 3 years ago

Sure :) image

btw, I've measured the Voltage with a multimeter on a wall plug.

alcar21 commented 3 years ago

oook, CT is 0-1v or 0-5v?

rechena commented 3 years ago

It's the SCT-013-030...so from the specs its 0-1v? I did used in the past with a 5V Arduino, not sure if it helps.

alcar21 commented 3 years ago

Arduino works with 5v and ADC of ESP8266 work with 1v. This board is calibrated for the ADC of the Wemos D1 to range 0-1v.

image

rechena commented 3 years ago

That is the board I got, I got it from the eBay link you have on this page.. :( and I'm using it with a Wemos D1

alcar21 commented 3 years ago

It's all Ok. Can you post a photo of the connections with Wemos D1, board, and CT?

rechena commented 3 years ago

IMG_0403 IMG_0402 IMG_0401

rechena commented 3 years ago

I might be wrong, but I find the A/Current value way to low... Not sure if its relevant but noticed that you initialize the current twice on L51 and then some lines bellow. https://github.com/alcar21/WemosEM/blob/8c6dffaa4de2e2321face50fc18bc9d880691349/WemosEM-Mqtt-Power-Sensor/WemosEM/WemosEM.ino#L51

Looking at the Emon docs https://learn.openenergymonitor.org/electricity-monitoring/ct-sensors/how-to-build-an-arduino-energy-monitor-measuring-current-only it seems that only once needed?

alcar21 commented 3 years ago

yes is very low. Sure, this is not well.

I believe that it's the cable of CT (jack 3.5) that connects to the board. I have a friend that has the same problem but I am not sure.

El lun., 5 oct. 2020 a las 15:11, Joao Rechena (notifications@github.com) escribió:

I might be wrong, but I find the A/Current value way to low...

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-703621942, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSMAOCQQH3W32J5TLM3SJHAYXANCNFSM4RTXPGLA .

rechena commented 3 years ago

So you think I might have a bad CT? :(

alcar21 commented 3 years ago

yes, may be

rechena commented 3 years ago

Ok so not much to do but buy a new one. Any recommendations on the Amp? Should I keep the 30amp or go higher?

alcar21 commented 3 years ago

I recommend to you buying PZEM-004T. I have a firmware that it's compatible with PZEM-004T. This CT has more precession that SCT-013-30. The SCT-013 is best when it's smaller.

rechena commented 3 years ago

Does it work with the d1mini and the shield? Do you have a link?

rechena commented 3 years ago

Was just checking the eBay where o got the board and I think I've figure out the issue. This board is for use with the sct-013-000 so I'm guessing there's an extra burden resistor, I do recall when I was using the openenergy schematics that was the plan. I've just ordered one and will let you know.

alcar21 commented 3 years ago

Indeed, I had not noticed.

WARNING: If you use a calibrated clamp, remove resistance R1 from mains current sensor.

Un saludo, Alfonso C.

El mar., 6 oct. 2020 a las 9:11, Joao Rechena (notifications@github.com) escribió:

Was just checking the eBay where o got the board and I think I've figure out the issue. This board is for use with the sct-013-000 so I'm guessing there's an extra burden resistor, I do recall when I was using the openenergy schematics that was the plan. I've just ordered one and will let you know.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-704078659, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSLBQM24QYXMWWEG54TSJK7KZANCNFSM4RTXPGLA .

rechena commented 3 years ago

Don't think mine is calibrated... and wouldn't want to remove an R1.. so I might just wait for the 000 one to arrive :)

alcar21 commented 3 years ago

you remember that you must modify the ICAL value for STC-013-000. This current transformer has minor precision

El mar., 6 oct. 2020 a las 9:46, Joao Rechena (notifications@github.com) escribió:

Don't think mine is calibrated... and wouldn't want to remove an R1.. so I might just wait for the 000 one to arrive :)

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-704094170, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSJ7DN3SIARKU67OUZLSJLDLTANCNFSM4RTXPGLA .

rechena commented 3 years ago

Yep, will make the change which from this link: http://lechacal.com/wiki/index.php/Current_Transformer_Conditioner is 85.71... interesting number... :D

alcar21 commented 3 years ago

jejeje, perfect! I hope that it's will go fine.

Regards, Alfonso C.

El mar., 6 oct. 2020 a las 10:13, Joao Rechena (notifications@github.com) escribió:

Yep, will make the change which from this link: http://lechacal.com/wiki/index.php/Current_Transformer_Conditioner is 85.71... interesting number... :D

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-704108020, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSILSWS53QQTAQD3MFLSJLGSZANCNFSM4RTXPGLA .

rechena commented 3 years ago

After a chat with the board seller he confirmed that my CT already had a burden resistor, so I've just removed resistor 1 and now I have proper measures :)

Standby: image

Kettle: image

alcar21 commented 3 years ago

great!

El mar., 6 oct. 2020 a las 13:43, Joao Rechena (notifications@github.com) escribió:

After a chat with the board seller he confirmed that my CT already had a burden resistor, so I've just removed resistor 1 and now I have proper measures :)

Standby: [image: image] https://user-images.githubusercontent.com/3226822/95197348-60e34b00-07d1-11eb-91d7-1560ebf0cbee.jpeg

Kettle: [image: image] https://user-images.githubusercontent.com/3226822/95197385-6f316700-07d1-11eb-89a0-9c58ead795e7.jpeg

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alcar21/WemosEM/issues/14#issuecomment-704212477, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJBMSODOEGL3X6JLSCDPCLSJL7ERANCNFSM4RTXPGLA .

rechena commented 3 years ago

Thanks for all your help. I'm gonna close the issue :)