kkeeley
Member level 3
Hi,
I am still learning how to use LTspice for simulation. I wish to create my own sub circuit for a diode brdge created by using 4 seperate diodes . I can do this with the following Spice commads. This is then saved as a .lib file and referenced from my main scchematic via my own symbol.
I have been able to create and use other SUBCKT's that allow me to pass a numerical value that is then used to set something like a resistor value.
What I would like to do is be able to pass a string to the SUBCKT that will allow me to change the type of Diodes being used without having to create multiply subckts.
Can this be done in LTspice and if so how.
Thanks
Kenneth
I am still learning how to use LTspice for simulation. I wish to create my own sub circuit for a diode brdge created by using 4 seperate diodes . I can do this with the following Spice commads. This is then saved as a .lib file and referenced from my main scchematic via my own symbol.
.SUBCKT DiodeBridge 1 2 3 4
D1 1 3 1N4001
D2 3 2 1N4001
D3 1 4 1N4001
D4 4 2 1N4001
.ENDS
I have been able to create and use other SUBCKT's that allow me to pass a numerical value that is then used to set something like a resistor value.
What I would like to do is be able to pass a string to the SUBCKT that will allow me to change the type of Diodes being used without having to create multiply subckts.
Can this be done in LTspice and if so how.
Thanks
Kenneth