# Phase control up to 40A with TRIAC and DIAC (Optocoupler)

I'm projecting a phase control to control the power given to a resistive load of 6 Ohms using a PLC, TRIAC (BTA40-400), DIAC (Optocoupler MOC3023) and a zero crossing detector (4N25).

I've simulated the circuit on Proteus Isis (circuit bellow) and I get an error. This error disappears if I set the resistor R2 upper to 5k Ohms but I did not get the expected current and voltage at the load (around 37A and 220V).

simulate this circuit – Schematic created using CircuitLab

After that I realised maybe the answer is: The current through DIAC is higher than supported by it. (Is it?)

What's the current passing through this DIAC when the TRIAC is disabled? (37A?)

How could I make it working at the simplest way?

• @Transistor, I dont have reputation here to add more than 3 links so I added only 2. But the 3th device (4N25) isnt so important for this question. Tks! – Cleber Marques Aug 28 '16 at 0:15
• What error? And what does the documentation say it means? We're not mind readers. Data sheet says the MOC301 gate current to trigger is 50 to 100 mA, which explains why 5k doesn't work. Also look carefully at the sample circuit which you used to get 180 ohms. Notice that the AC voltage is 120, not 220, so you need a bigger resistor - but not 5k. – WhatRoughBeast Aug 28 '16 at 0:16
• Also, your optocoupler is a diac. Your part shown as 4N25 is in fact your MOC301 (not MOC3013). You may well have a 4N25 as well in order to isolate your logic from the power, but it won't work as you have drawn it. – WhatRoughBeast Aug 28 '16 at 0:19
• @WhatRoughBeast, the error is: "Timestep too small; timestep - 1.25e-019:". It is not specific error with only one cause so study it isnt the point. And yes, this optocoupler is a diac. It triggers the triac and also isolates the AC circuit of control circuit. The 4N25 isnt placed yet. Note the 4N25 is for zero-crossing detection only. It isnt required for this step. – Cleber Marques Aug 28 '16 at 0:30

The device inside the MOC3023 is an opto-triac, not a diac. A diac is triggered by voltage across it, whereas the opto-triac is triggered by light from the LED.

The maximum current in the opto-triac should not exceed 50mA (except very briefly) since above that the triac is guaranteed to turn in in the relevant quadrants (I/III).

I am not familiar with your simulator, but in general for SPICE-based simulation you must have a ground reference in all subcircuits for simulation to work. The opto provides isolation so the circuit on the right is floating unless there are some fudges in the simulator or models. You can try grounding one side of the mains (for simulation purposes only) through a resistor such as 100K.

I don't know where you got the 200 ohm value from- that will allow almost 120mA of LED current to flow, far in excess of the 50mA absolute maximum. It only takes 5mA to trigger at 25 degrees C- check your calculations. 10 or 15mA nominal would allow it to trigger even in a Siberian winter, and after years of aging.

The only purpose of R2 is to limit the peak opto-triac current for the few tens of microseconds while the main triac is turning on. At a peak mains voltage of 311 volts that will be about 1.7A, then will rapidly drop to about zero. If you disconnect the triac MT2 the resistor will, of course, go up in flames. 180 ohms is okay.

One thing that may be confusing you is that the opto datasheet you linked has at least one error - the Itsm Y axis in Fig 4 (what determines the minimum value of R2) should be amperes, not mA! The maximum value is limited by how much voltage drop you can tolerate. If the opto triac and triac gates drop 2.5V total, the triac won't turn on until the mains exceeds Igt*R2 + 2.5V in magnitude or +/- 11.5V for 180 ohms. Too high and you limit the maximum output power, introduce asymmetry into the output voltage, cause unnecessary EMI at 100% power, and unnecessary heating in R2, so it is a trade-off.

• note that the current through the load is 37A (too high). You said while the main triac is turning on the peak mains voltage of 311 volts that will be about 1.7A. How did you realise 1.7A? Does not the load interfere in this value? – Cleber Marques Aug 28 '16 at 14:44
• 6 ohms should give you 37A RMS. I = 220*sqrt(2)/180 = 1.7A peak , but only if you trigger it exactly at the AC line peak. No the load doesn't matter hardly at all (in fact I ignored it) because 6 << 180. It only adds 3%, probably less than your resistor tolerance. – Spehro Pefhany Aug 28 '16 at 14:54

Spehro said more than enough to get you going. I had got as far as the left side of the opto-isolator:

Figure 1. For 5 mA your R1 should be $\frac {V}{I} = \frac {24}{5m} \approx 4k7$. Go for 2k7 to give nearly 10 mA for reliability.