Crystal

Old Content - visit altium.com/documentation

Model Kind

General

Model Sub-Kind

Spice Subcircuit

SPICE Prefix

X

SPICE Netlist Template Format

@DESIGNATOR %1 %2 @MODEL #|PARAMS:| ?FREQ|FREQ=@FREQ| ?RS|RS=@RS| ?C|C=@C| ?Q|Q=@Q|

Parameters (definable at component level)

The following component-level parameters are definable for this model type and are listed on the Parameters tab of the Sim Model dialog. To access this dialog, simply double-click on the entry for the simulation model link in the Models region of the Component Properties dialog.

FREQ

the nominal output frequency of the crystal (in Hertz).

RS

the resistance exhibited by the crystal at the series resonant frequency (in Ohms).

C

shunt capacitance (in Farads). This value is the combination of the capacitance due to the electrodes on the crystal plate and stray capacitances arising from the crystal holder/enclosure.

Q

the quality factor of the equivalent electrical circuit model for the crystal. This essentially is the ratio of energy stored to energy dissipated for the circuit and can be further defined as the ratio of the reactance (series motional inductance and capacitance) to the series resistance at the resonant frequency.

Notes

A crystal is not one of the built-in SPICE engine models. It is a complex device and, as such, is defined using the hierarchical sub-circuit syntax.

All of the parameters will normally have a default value assigned. The default should be applicable to most simulations. Generally you do not need to change this value. Entering a value for a parameter on the Parameters tab of the Sim Model dialog will override its specified value in the sub-circuit file.

To check the default values of a crystal, open the appropriate sub-circuit (.ckt) file. You can view the content of this file for the model specified on the Model Kind tab of the Sim Model dialog, by clicking on the Model File tab at the bottom of the dialog. The default parameter values are listed in the .SUBCKT line.

Examples

Consider the crystal in the above image, with the following characteristics:

  • Pin1 is connected to net N1
  • Pin2 is connected to net N2
  • Designator is Y1
  • The linked simulation sub-circuit file is 3.5795MHz.ckt with the following content:

*Crystal Subcircuit Parameters
*FREQ = Fundamental frequency
*RS   = Series resistance
*C    = Parallel capacitance
*Q    = Quality Factor
*CTS Color Burst alias:XCRYSTAL {FREQ=3.58E6 RS=160 C=1.8E-11} pkg:HC49
.SUBCKT 3.5795MHZ 1 2 PARAMS: FREQ=3.58E6 RS=160 C=1.8E-11 Q=1000
LX 1 3 {((Q*RS)/(6.2831852*FREQ))} IC=0.5M
CX 3 4 {(1/(Q*6.2831852*FREQ*RS))}
C0 1 2 {C}
RS 4 2 {RS}
.ENDS

If no values are entered for the parameters in the Sim Model dialog, the entries in the SPICE netlist would be:

*Schematic Netlist:
XY1 N1 N2 3.5795MHZ
.
.
*Models and Subcircuit:
.SUBCKT 3.5795MHZ 1 2 PARAMS: FREQ=3.58E6 RS=160 C=1.8E-11 Q=1000
LX 1 3 {((Q*RS)/(6.2831852*FREQ))} IC=0.5M
CX 3 4 {(1/(Q*6.2831852*FREQ*RS))}
C0 1 2 {C}
RS 4 2 {RS}
.ENDS

 

If the following overriding parameter values were specified on the Parameters tab of the Sim Model dialog:

  • FREQ = 10MEGHz
  • Q = 10000

Then the entries in the SPICE netlist would be:

*Schematic Netlist:
XY1 N1 N2 3.5795MHZ PARAMS: FREQ=10MEGHz   Q=10000
.
.
*Models and Subcircuit:
.SUBCKT 3.5795MHZ 1 2 PARAMS: FREQ=3.58E6 RS=160 C=1.8E-11 Q=1000
LX 1 3 {((Q*RS)/(6.2831852*FREQ))} IC=0.5M
CX 3 4 {(1/(Q*6.2831852*FREQ*RS))}
C0 1 2 {C}
RS 4 2 {RS}
.ENDS

 

In this case, the Netlister will evaluate the formulae in the sub-circuit definition using the values for FREQ and Q (from the Sim Model dialog) and the default values for RS and C, as defined in the 3.5795MHZ.ckt file.

You are reporting an issue with the following selected text and/or image within the active document: