If you look at the .zip
file provided by ST, it includes a .lib
(models) and a .olb
(symbols). These are meant to be used with PSpice, and there is also a .pdf
file provided which shows you how to import the models and symbols into PSpice.
Since you are using LTspice, you can use the models since LTspice has a bunch of undocumented PSpice model compatibility. However, you cannot use the symbols. Like you found, LTspice provides a generic TRIAC symbol to use with subcircuits (i.e. has a prefix of X
) in the [Misc]
folder. Before you can use this symbol, you need to understand the pin order for it. The easiest way to do this is to put an instance of the symbol onto your schematic and right-click on it. Then you can click on Open Symbol:
.
This brings you to the symbol editor. Right-click on the top pin and you'll see this:
The important information here is the Netlist Order
; a fancy way of saying "pin order". Jot this down and repeat this for the remaining pins. You'll notice that the GATE pin has a netlist order of 2. This is important. Since a triac is bi-directional, the other two pins don't matter too much (in this specific instance).
Now, if you open up the .lib
file for the models and scroll through you can see the generic structure for ST's triac model library.
.subckt Triac_ST A K G PARAMS:
+ Vdrm=400v
+ Igt=20ma
+ Ih=6ma
+ Rt=0.01
+ Standard=1
They define a universal subcircuit called Triac_ST
with some default parameters. Then if you scroll down further you'll see that for each specific triac device, it simply instantiates a Triac_ST
with parameters that fit the device. For your BTA24-600CW:
.subckt BTA24-600CW A K G
X1 A K G Triac_ST params:
+ Vdrm=600v
+ Igt=35ma
+ Ih=50ma
+ Rt=0.016
+ Standard=0
* 1999 / ST / Rev 0
.ends
The main takeaway here is that the GATE pin (deduced from the G
) is the 3rd pin in all these definitions. So, how to fix this? Well, you can do it two ways (actually three, but the third is so similar). You can swap K
and G
within the .subckt BTA24-600CW
definition, such that it looks like this:
.subckt BTA24-600CW A G K
You'd have to do the above for each specific device, so this is the targeted approach. Since you're likely using this modified .lib
exclusively in LTspice, it's probably better to modify the Triac_ST
subcircuit definition instead so the swap will apply universally to all devices within the file, like such:
.subckt Triac_ST A G K PARAMS:
Triac_ST
subcircuit is A K G. The SPICE pin order for the built-in LTspice triac symbol is A G K. Did you make sure to modify the.subckt Triac_ST A K G PARAMS:
line into.subckt Triac_ST A G K PARAMS:
? \$\endgroup\$