Transformer works on PWM at 50Hz

pwmtransformer

I have an ardunio setup which is giving me output of 5V and 1A at 50Hz with pulse width modulation. I want to use this as input to the step up transformer and generate output of 60V. considering transformer formula Vp/Vs=Np/Ns I will need to have Ns=12*Np.

My questions:

1.Will the transformer will work on PWM at 50Hz?(if yes,will there be power loss?)

2.Can I use 60V as input to other step up transformer and generate output of 120V?Or would it be better to add just one another transformer?

Best Answer

I looked at the code reference and, as the comments say, it's going to generate a kind of sawtooth - not a sinewave.

void loop() {
    for(up=-1; up <= 255;up++) {
        analogWrite(out,up);
        if(up==255) {
            up=-1;
        }
    }
    delay(20);
}

Non-sine.

What you are expecting is the blue sine-wave. What that Arduino code will give is a short sawtooth (ramping up to 255 and back to -1) followed by 20ms of nothing. It won't even give 50 Hz correctly.

  1. If you did get a sine wave out it would give you a 2.5 V DC output with a 5 V peak-to-peak sinewave on top of it. The DC will bias the transformer which expects the input voltage to be symetrical about 0 V (and not 2.5 V).

  2. 5 V p-p = 1.7 V RMS so even if you got rid of your DC you still have a very low voltage to work with.

  3. (You think) you have \$5V \times 1A = 5 W\$ to work with but \$5 V_{p-p} = \frac {5}{2 \cdot \sqrt 2} = 1.7 V_{rms}\$ and \$1 A \cdot 1.7 V_{rms} \to 1.7 W\$. Be aware that even if you got this to work efficiently and stepped up the voltage to 120 V the absolute maximum output would still be 1.7 W which is about 14 mA at 120 V.

I suspect that you hope to use your Arduino to power something that would normally run at 50 Hz. I think the answer is "no".

What you are trying to make is an inverter. Have a look on the web for inverter designs. You will find some very cheap designs but they will have terrible non-sine waveforms and poor voltage regulation. Anything better will require specialist and more expensive components.

Edit after Arduino code update.

void loop() {
    for(up=0; up <= 255;up++) {
        analogWrite(out,up);
        delay(20);
    }
    for(down=255; down>=0;down--) {
        analogWrite(out,down);
        delay(20);
    }
}

Your updated code will give an output like this.

Arduion code version 2 result.

The updated code result.

Now your code now steps up by 1 step and waits 20 ms before doing the next step. It will take \$255 \times 20ms = 5.1s\$ to get to 255 and another 5.1 s to come back down to zero. That's one full cycle in 10.2 s or < 0.1 Hz.

  • No it won't work in a transformer.
  • As stated, even if it worked and was 100% efficient it could only give 14 mA. You're looking for 44 mA so there is no chance of it working.
  • It's still not AC. It's a rising and falling DC. The current never changes direction.

It still has a DC offset in it.