Author Topic: Custom Variac build  (Read 4134 times)

0 Members and 1 Guest are viewing this topic.

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Custom Variac build
« on: September 18, 2023, 04:52:32 pm »


This Variac on my desk is eating dust for too long, hopefully it's time to design and build a proper box with some circuitry around it.

What I have in mind is a digital meter using an MCU with 16bit ADC showing voltage, current, wattage and watt-hour.

Over-current and short circuit protection.

I'm thinking to add a soft start with a relay because the Variac has two cores.

And of course an old lamp as current limiter.

I'm gonna update this post as the project progress.

Latching comparator for short circuit protection:


The current transformer:
« Last Edit: September 18, 2023, 04:57:25 pm by ElectronSurf »
 

Offline Hydron

  • Super Contributor
  • ***
  • Posts: 1146
  • Country: gb
Re: Custome Variac build
« Reply #1 on: September 18, 2023, 05:12:26 pm »
Take a look at panel power meters on ebay/aliexpress. Could dramatically simplify the measurement side of things - I found one that displays real/reactive power, power factor, voltage and current (switching mode via a button on the front) and have built it into a couple of different variacs. The trick with these (other than finding the right one - there are a few options available) is to open them up to identify the input to the capacitive dropper power supply (it only runs down to some tens of volts, not zero), lift the connection and feed the PSU bit full mains voltage. The measurement side (connected to variac output) will still run down to 0V so you bypass the typical 40-80V minimum AC voltage limitation and get a much more useful meter.

Can still use a simple CT for things like OC and SC protection, with the bonus that the MCU can be easily isolated if you're not doing voltage monitoring etc.

As for soft-start a MCU will make it easy (just need a timer, plus some appropriate NTCs and a bypass relay), though there are also methods that don't need one (I was lucky enough to find a small 12V plugpack that had an appropriate soft start delay when mains was applied, and drove a bypass relay direct from it).
 
The following users thanked this post: ledtester, ElectronSurf

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custome Variac build
« Reply #2 on: September 18, 2023, 05:43:49 pm »
Take a look at panel power meters on ebay/aliexpress. Could dramatically simplify the measurement side of things - I found one that displays real/reactive power, power factor, voltage and current (switching mode via a button on the front) and have built it into a couple of different variacs. The trick with these (other than finding the right one - there are a few options available) is to open them up to identify the input to the capacitive dropper power supply (it only runs down to some tens of volts, not zero), lift the connection and feed the PSU bit full mains voltage. The measurement side (connected to variac output) will still run down to 0V so you bypass the typical 40-80V minimum AC voltage limitation and get a much more useful meter.

Can still use a simple CT for things like OC and SC protection, with the bonus that the MCU can be easily isolated if you're not doing voltage monitoring etc.

As for soft-start a MCU will make it easy (just need a timer, plus some appropriate NTCs and a bypass relay), though there are also methods that don't need one (I was lucky enough to find a small 12V plugpack that had an appropriate soft start delay when mains was applied, and drove a bypass relay direct from it).

TBH I was going to buy one of those power meter modules but what's the fun in that, decided to build one myself. I have the CT, I just need to feed it to a precision rectifier and read the value. hopefully it will be as simple as that! :-DD
 
The following users thanked this post: schmitt trigger

Offline Terry Bites

  • Super Contributor
  • ***
  • Posts: 2706
  • Country: gb
  • Recovering Electrical Engineer
Re: Custom Variac build
« Reply #3 on: September 18, 2023, 05:47:37 pm »
I got me a "Nashone Tuya Energy Meter Wifi 2P 63A Electric Power Meter Din 170-270V Electric Consumption Mete Kwh Meter Voltmeter Ammeter" for £15
Bloody marvelous!
 
The following users thanked this post: ElectronSurf

Offline schmitt trigger

  • Super Contributor
  • ***
  • Posts: 2500
  • Country: mx
Re: Custom Variac build
« Reply #4 on: September 18, 2023, 07:30:11 pm »
A genuine General Radio Variac!
Wooooooow! That thing is old, a legitimate antique.
 
The following users thanked this post: ElectronSurf

Offline schmitt trigger

  • Super Contributor
  • ***
  • Posts: 2500
  • Country: mx
Re: Custom Variac build
« Reply #5 on: September 18, 2023, 08:38:18 pm »
I can see you have a two gang unit. Depends whether you require a higher voltage or current, there are a couple of wiring configurations.
 
The following users thanked this post: ledtester, ElectronSurf

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #6 on: September 19, 2023, 07:38:55 am »
I can see you have a two gang unit. Depends whether you require a higher voltage or current, there are a couple of wiring configurations.

It's really useful, thank you.
 

Offline RJSV

  • Super Contributor
  • ***
  • Posts: 2936
  • Country: us
Re: Custom Variac build
« Reply #7 on: September 20, 2023, 12:27:19 am »
(Casual bystander, but amazed!)
   Why couldn't the thing be intended for Dual Output purposes; Two legs of a 3-phase system...although that could mean some phase sensitive windings. ( ? ).
I remember something about obtaining full 3-phase waveforms, from a source having 2-phases.
 

Offline schmitt trigger

  • Super Contributor
  • ***
  • Posts: 2500
  • Country: mx
Re: Custom Variac build
« Reply #8 on: September 20, 2023, 02:37:12 am »
That is called the Scott-T transformer connection.

It requires two different secondary-voltage transformers.
And the input source must be a true two phase, i.e. 90 degrees out of phase.
« Last Edit: September 20, 2023, 02:39:04 am by schmitt trigger »
 
The following users thanked this post: RJSV

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #9 on: September 21, 2023, 06:32:50 pm »
I had some progress with analog section, I'd appreciate any suggestion/correction.

Since I've the MCU in there, I want to use that to trigger soft start relay.
 
The following users thanked this post: TERRA Operative

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #10 on: October 16, 2023, 02:47:43 pm »
I'm still working on this whenever I have the chance. I decided to make the control section isolated from the main, winded a voltage transformer that gives me 1:500 ratio:



And plus so many changes in the schematic, hopefully I can one day design the PCB!
 

Offline TizianoHV

  • Regular Contributor
  • *
  • Posts: 122
  • Country: it
    • My Website
Re: Custom Variac build
« Reply #11 on: October 16, 2023, 06:16:51 pm »
Hi,
nice to see some projects with mains!
I'm not so convinced by the soft start relay K1. Using the make/break contact could cause a lot of wear and make the soft start useless. You should connect K1 and K2 in parallel so to avoid switching transients. That would reduce contact resistance too.
Adding a variable series impedance (ballast) could be a useful feature to limit short circuit current when testing broken stuff (I have that on my PS -> https://tiziano-bielli-ee.github.io/projects/ac-power-supply.html and it's super useful).

I don't know if I'm reading the schematic correctly, to me seems that K1 is not controlled by the micro. Why are you using those analog comparators when the micro could do everything?

Are those opamps needed? I'm building a power meter too (https://tiziano-bielli-ee.github.io/projects/pk-rms-wattmeter.html), and I opted for a more simplistic design. The less stuff you use, the less stuff can break!

Offline jonpaul

  • Super Contributor
  • ***
  • Posts: 3740
  • Country: fr
  • Analog, magnetics, Power, HV, Audio, Cinema
    • IEEE Spectrum
Re: Custom Variac build
« Reply #12 on: October 16, 2023, 09:12:02 pm »
Transformer is ferrite must be lam or tapewound silicon steel

Bad design.

My power mains setuo has been

Mains>>1:1 isolation trsf 1..5 KVA>>Variac>>Analog meters.

See GenRad and Staco for commercial metered variacs.

Digital meters are not as useful to monitir faults and fluctuations

Jon
The Internet Dinosaur..
passionate about analog electronics since 1950s
 

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #13 on: October 16, 2023, 09:31:58 pm »
Hi,
nice to see some projects with mains!
I'm not so convinced by the soft start relay K1. Using the make/break contact could cause a lot of wear and make the soft start useless. You should connect K1 and K2 in parallel so to avoid switching transients. That would reduce contact resistance too.
Adding a variable series impedance (ballast) could be a useful feature to limit short circuit current when testing broken stuff (I have that on my PS -> https://tiziano-bielli-ee.github.io/projects/ac-power-supply.html and it's super useful).

I don't know if I'm reading the schematic correctly, to me seems that K1 is not controlled by the micro. Why are you using those analog comparators when the micro could do everything?

Are those opamps needed? I'm building a power meter too (https://tiziano-bielli-ee.github.io/projects/pk-rms-wattmeter.html), and I opted for a more simplistic design. The less stuff you use, the less stuff can break!

Hi, paralleling of the relays has a problem, so based on your drawing; K1 first should close then after a delay it should open and K2 should close. we have a moment there with no power to the Variac and the only way to solve this is to keep K1 closed until K2 closes too and then open K1. it's just beyond simple analog that I'm after.

I was going to use a micro for the soft start at first but then I thought comparators are way way more faster, analog wins in this scenarios...

The op amps are not really needed but the programing and math is easier with DC (or at least for me).

I really liked your build, how did you mount the Variac inside that box?

 

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #14 on: October 16, 2023, 09:36:43 pm »
Transformer is ferrite must be lam or tapewound silicon steel

Bad design.

My power mains setuo has been

Mains>>1:1 isolation trsf 1..5 KVA>>Variac>>Analog meters.

See GenRad and Staco for commercial metered variacs.

Digital meters are not as useful to monitir faults and fluctuations

Jon

Hi Jon, The transformer is not a ferrite! it's good old EI core.

Appreciate your input.
 

Offline TizianoHV

  • Regular Contributor
  • *
  • Posts: 122
  • Country: it
    • My Website
Re: Custom Variac build
« Reply #15 on: October 16, 2023, 09:51:10 pm »
Why do you want to open K1? First you close K1, you wait 1-2 secs, and then you close K2 (K1 stay closed, no need to open it while K2 is closed).

Don't worry about speed, your electromechanical relays will be way slower than any microcontroller. Anyway, everyone does what he likes more, I'm scared of analog electronics ;).

Thank you! The mounting is just some wood, screws and hot glue, nothing fancy but it's still solid after 7 years.


Edit: For some reason photos are rotated.. tried reuploading
« Last Edit: October 16, 2023, 09:53:32 pm by TizianoHV »
 
The following users thanked this post: ElectronSurf

Offline jonpaul

  • Super Contributor
  • ***
  • Posts: 3740
  • Country: fr
  • Analog, magnetics, Power, HV, Audio, Cinema
    • IEEE Spectrum
Re: Custom Variac build
« Reply #16 on: October 17, 2023, 07:49:05 am »
ElectronSurf: A potential measurement transformer is usually a tapewound toroid, not EI.
The photo seems to be a ferrite EI
Number of turns Pri/Sec seems very low.
At 120 or 240V mains 50/60Hz the magnetizing current and Bsat flux will be VERY HIGH.
lam size and thickness?  Winding sheet?


Jon

PS: See any good transformer design text on the formulas and design of mains transformers.
# Turns depends on Bmax, core CX area, integrated product of V over time.
The Internet Dinosaur..
passionate about analog electronics since 1950s
 

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #17 on: October 17, 2023, 01:41:40 pm »
ElectronSurf: A potential measurement transformer is usually a tapewound toroid, not EI.
The photo seems to be a ferrite EI
Number of turns Pri/Sec seems very low.
At 120 or 240V mains 50/60Hz the magnetizing current and Bsat flux will be VERY HIGH.
lam size and thickness?  Winding sheet?


Jon

PS: See any good transformer design text on the formulas and design of mains transformers.
# Turns depends on Bmax, core CX area, integrated product of V over time.

It's not ferrite:


The core size is 3.5x3x1.2 CM.
It was a 9V transformer that I removed the secondary and to increase the coupling I winded the secondary on top of primary.

I tried to wind the common mode choke myself (right) but then found a proper one with datasheet and gonna use that (left):
 

Offline p.larner

  • Frequent Contributor
  • **
  • !
  • Posts: 690
  • Country: gb
Re: Custom Variac build
« Reply #18 on: October 18, 2023, 02:39:40 am »
make a psu like photonic induction. :-DD
 

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #19 on: November 17, 2023, 07:35:54 am »
The final schematic with last changes, built the PCB and tested it. now I just have to do the software and build the box.
 

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #20 on: December 10, 2023, 05:01:30 pm »
While I was working on the project I came across PZEM-004 module that outputs the data isolated to a micro-controller. So I decided to re-build the project around this module, after all my 16bit ADC was no match for the in-chip 20bit ADC of V9888.

The module couldn't read down to 0V so I had to modify it a little, other than that everything is fine.

After 500+ lines of coding the software is ready to use, calculations of all the values:
Code: [Select]
void calculateValues() {
  voltage = pzem.voltage();
  // Calibration
  voltage *= 1.0144;
  current = pzem.current();
  // 10 Turns around the CT
  current /= 10;
  frequency = pzem.frequency();
  pf = pzem.pf();
  energy = (pzem.energy()) / 1000;
  activeP = (voltage * current * pf) / 1000;
  apparentP = (voltage * current) / 1000;
  reactiveP = sqrt(pow(apparentP, 2) - pow(activeP, 2));
  phaseAngle = acos(pf) * (180 / 3.14159265359);
  resistance = activeP / pow(current, 2);
  impedance = apparentP / pow(current, 2);
  reactance = reactiveP / pow(current, 2);
}

Two minute video of the UI:


Now I just have to design a box for this.
« Last Edit: December 10, 2023, 05:03:05 pm by ElectronSurf »
 

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #21 on: December 27, 2023, 07:29:48 am »
It's done, I only need to design the cover...
 

Offline TizianoHV

  • Regular Contributor
  • *
  • Posts: 122
  • Country: it
    • My Website
Re: Custom Variac build
« Reply #22 on: December 28, 2023, 12:19:11 pm »
Good job! Yes, these PZEM-004 modules are really the easiest way to get good accuracy power measurement. The thing that I don't like about them is the speed. 1 rdng/sec is a bit too slow for my taste. Are you using its readings for the overcurrent protection? It may be too slow for that.
For overload protection you don't need all that accuracy. You could use the internal ADC of the micro to monitor the peak value of the current (no need for RMS) and check if the peak value is higher than the limit for more than a time limit.

What is the minimum current you can measure with the PZEM-004?

Offline ElectronSurfTopic starter

  • Regular Contributor
  • *
  • Posts: 104
  • Country: aq
Re: Custom Variac build
« Reply #23 on: December 28, 2023, 12:39:27 pm »
Good job! Yes, these PZEM-004 modules are really the easiest way to get good accuracy power measurement. The thing that I don't like about them is the speed. 1 rdng/sec is a bit too slow for my taste. Are you using its readings for the overcurrent protection? It may be too slow for that.
For overload protection you don't need all that accuracy. You could use the internal ADC of the micro to monitor the peak value of the current (no need for RMS) and check if the peak value is higher than the limit for more than a time limit.

What is the minimum current you can measure with the PZEM-004?

Yeah it is slow, annoying tbh and the module itself is not slow but it's the library...

I turned 10 turns around the CT so it's accurate down to mA range, didn't tested it below that.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf