ModeMCU + ADS1115 + 3xSCT-013-030

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

ModeMCU + ADS1115 + 3xSCT-013-030

#1 Post by wojtek_gtx » 09 Jan 2020, 10:55

538/5000
I uploaded the latest version of ESPEasy to NodeMcu, I connected the ADS1115 to this, of course, I connected the loop with resistors according to the scheme.
Only I have a problem with the indications, I can't calibrate it because the indications from the loop SCT-013-030 float very much under load and after calibration there are indications once 1.5A and then the indication is in minus ...

I do calibration for the first point with a 100W bulb - value 0.432A, the second point on a 2000W vacuum cleaner - value 8.695A.

I connected the butane gas sensor or LUX sensor and the measurements are good and they don't jump.

I2C Interface
GPIO-SDA GPIO-4
GPIO-SCL GPIO-5

GPIO boot states
Pin mode GPIO-4 Default
Pin mode GPIO-5 Default

Image
Image

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#2 Post by Shardan » 09 Jan 2020, 21:18

Did you realize that the SCT-013-030 is a transformer?
The output is AC, not DC.

The ADS1115 isn't able to work with AC. It will measure at a random point of the
sine wave resulting in changing values.

The Circuit you showed is made for AC capable sensing.

I'd use a bridge rectifier made from Schottky diodes (BAT48 or similar).
Connect the SCT to the AC inputs of the bridge rectifier.
The negative output should be grounded, the positive output of the bridge needs
at least a capacitor to egalize the voltage. Maybe 10µF?

I've found a similar circuit for this:
Stromwandler_Verstaerker.png
Stromwandler_Verstaerker.png (3.72 KiB) Viewed 30578 times
You may omit the R1 as it's built into the SCT-013-030
The OpAmp is not necessary for the ADS1115 either.

This circuit isn't originally made for current converters with built-in load resistor as the SCT-013-030 is.
But it might be a good base for going on further.

You need the diodes, R2, R3 and C1/C2.
The connection point R3/C2 goes to the ADS1115.
It might be necessary to ad a resistor from ADS1115 input to ground to discharge the capacitors
as the load resistor is ommited... I'd start trying with 100KOhm resistor.
Regards
Shardan

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#3 Post by wojtek_gtx » 09 Jan 2020, 22:44

Oooo, you surprised me and it's very, I don't know much about electronics but I will try. I just wonder how these projects that are shown on the internet work, no one has straightened this tension in the projects shown. They also show that they measure alternating current. Thank you very much.

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#4 Post by wojtek_gtx » 09 Jan 2020, 23:27

I will ask you, are the diodes alone enough and plug them into my circuit just to straighten the voltage from the transformer?

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#5 Post by Shardan » 10 Jan 2020, 18:40

Nope, that won't work. The two resistors from your circuit will give a huge offset from zero.
Regards
Shardan

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#6 Post by wojtek_gtx » 10 Jan 2020, 18:59

it's a pity because I have to make such arrangements for 3 entries. The housing is starting to get big.

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#7 Post by wojtek_gtx » 11 Jan 2020, 13:25

Shardan wrote: 09 Jan 2020, 21:18 Did you realize that the SCT-013-030 is a transformer?
The output is AC, not DC.

The ADS1115 isn't able to work with AC. It will measure at a random point of the
sine wave resulting in changing values.

The Circuit you showed is made for AC capable sensing.

I'd use a bridge rectifier made from Schottky diodes (BAT48 or similar).
Connect the SCT to the AC inputs of the bridge rectifier.
The negative output should be grounded, the positive output of the bridge needs
at least a capacitor to egalize the voltage. Maybe 10µF?

I've found a similar circuit for this:
Stromwandler_Verstaerker.png

You may omit the R1 as it's built into the SCT-013-030
The OpAmp is not necessary for the ADS1115 either.

This circuit isn't originally made for current converters with built-in load resistor as the SCT-013-030 is.
But it might be a good base for going on further.

You need the diodes, R2, R3 and C1/C2.
The connection point R3/C2 goes to the ADS1115.
It might be necessary to ad a resistor from ADS1115 input to ground to discharge the capacitors
as the load resistor is ommited... I'd start trying with 100KOhm resistor.
I am very surprised that you wrote that the ADS1115 cannot handle AC, but the analog input in the NodeMCU A0 also cannot handle such AC. I changed the analog input to A0 and there are such crazy readings.

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#8 Post by Shardan » 11 Jan 2020, 19:45

Honestly I'd be surprised if any standard ADC would be able to handle AC.
I'm doing a lot with electronics but never saw an ADC that was able to
handle AC directly.

May i suggest to take a look at the ESPeasy wiki:
https://letscontrolit.com/wiki/index.ph ... Converters

I've written that text to explain the basics of how an ADC works.
The way an ADC works will unavoidably result in strange random values.
The circuit you suggested is obvously made for an Arduino or AVR CPU with a
specialized software that can even detect phase shifting between voltage and
current to calculate effective power and the power factor (cos phi).
ESPEasy ahndles a lot of things internally and will be far too slow to handle
such a project.

Another hint:
To make things easier I'd avoid the SCT013-030 converters with built-in resistor.
Use a similar type with a current output like "20A/20ma" or similar, not with
an output voltage like "20A/1V"
Types like this: https://www.aliexpress.com/item/1900375496.html
or maybe the SCT006: https://www.aliexpress.com/item/32681520192.html
The SCT006 has the advantage of easy mounting, but the disadvantage of a very low.

Why is that better?
The voltage output types give a defined AC voltage that must be rectified for measurement.
The diode rectifiers have a voltage drop of at least 0,3..0,4 V so measuring low current will
give bad or no result at all. For exact measurement it needs e rectifier electronic using a
precision OpAmp and some parts around it.
If you use a current type transformer, it's the current that counts. The current goes through the
diodes and a resistor giving a rectified but still pulsing voltage. The two resistor-capacitor circuits
R2/c1 and R3/C2 build a low pass filter to give a "straight" DC for measurement.

Nonestly it's not the best way in a scientific sense, but the easiest way to handle pure current
measurement with a DIY circuit.

I've created a circuit for this.
Warning! This is not tested and might need further tweaking!
.
Rectifier Circuit.jpg
Rectifier Circuit.jpg (188.17 KiB) Viewed 30507 times
.

As you said the space in the compartment is small, here's an example design:
.
Rectifier_PCB.jpg
Rectifier_PCB.jpg (210.53 KiB) Viewed 30507 times
It's about 6 x 3 cm² and just a fgew millimeters high.
Regards
Shardan

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#9 Post by wojtek_gtx » 11 Jan 2020, 23:36

Thank you very much for your help and what do you think about buying 3 pieces:
https://a.aliexpress.com/fmQn2vB91
I would break out loops that are there and connect my ones only remove the resistor that is in my loop?

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#10 Post by Shardan » 12 Jan 2020, 12:03

I can't say anything about that module as i don't have any schematics.
Even basic data is missing.. Output DC or AC?
Withhout schematic it's difficult to even say if it is possible to use your SCT's.
Regards
Shardan

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#11 Post by Shardan » 12 Jan 2020, 14:28

Didn't find a schematic but a very informative offer on AliExpress:
https://www.aliexpress.com/item/4000109096239.html

Look at the picture from that offer:
HW670_DurrentSensor_Output.jpg
HW670_DurrentSensor_Output.jpg (40.48 KiB) Viewed 30460 times
.
Sorry to say: That module just amplifies the AC output but does not rectify it.
Regards
Shardan

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#12 Post by wojtek_gtx » 12 Jan 2020, 20:48

However, I will test your schematic, 10Kohm resistors, BAT diodes and 4.7uF capacitors, I already have only thought about using my loops, I will only remove resistors from them because it is possible. what should I mount a resistor on Load ??

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#13 Post by Shardan » 13 Jan 2020, 13:25

I'd suggest to re-use the removed resistors or new resistors with same value.
Every sensor coil has it's specific value for the burden resistor (or load resistor, same),
so using the original manufacturer value seems best idea to me.
Regards
Shardan

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#14 Post by wojtek_gtx » 17 Jan 2020, 18:55

the system is built and is very good compared to what I had to fight with the selection of R load. My one loop up to 100A has 105 ohm and the other and the other loop up to 30A has 33 ohm. When I connected this 100A and connected the 5W led bulb, I have indication 3-4 and when I connected the 100W bulb, the indication is 73, these are indications without calibration. How to power a multiplexer with 3 or 5V? The readings do not jump and swim ;-)

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#15 Post by Shardan » 17 Jan 2020, 19:25

What do you mean with "How to power a multiplexer with 3 or 5V?" ?

Nice to hear it works better now.
Regards
Shardan

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#16 Post by wojtek_gtx » 18 Jan 2020, 14:33

I am asking for ADS1115 power supply because I do not know if the readings are getting stronger. When I connected SCT-013-030 0-1V it shows nothing when I connect SCT-013-100 0-50mA it shows readings.

wojtek_gtx
Normal user
Posts: 19
Joined: 01 Oct 2019, 23:38
Location: Poland
Contact:

Re: ModeMCU + ADS1115 + 3xSCT-013-030

#17 Post by wojtek_gtx » 18 Jan 2020, 14:40

Load resistor I chose at 330 ohm and the indications are quite good ;-) though it combines if anyone would make this circuit with an amplifier.

Post Reply

Who is online

Users browsing this forum: No registered users and 23 guests