---
description: >-
  Instructions for defining crystal oscillator constraints, covering detection
  criteria, configuration fields, and current limitations.
---

# Crystal Oscillators

This constraint is designed to position oscillators near their drivers, minimizing phase noise and startup problems.

### Automatic Detection

Crystal oscillators are automatically detected if they meet the following criteria:

* A crystal oscillator component with a reference designator begins with an `X` or `Y`&#x20;
* Both pins of the crystal oscillator are directly connected to the same parent component or driver.

{% hint style="warning" %}
**Load-limiting Resistors**\
This constraint currently does not detect or function on crystals with load-limiting resistors
{% endhint %}

### Constraint Details

<figure><img src="https://1761213452-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL9R6Vsa5jGn27oTws0tG%2Fuploads%2Fte0E8Vzw5R1WcuBWKgCd%2Fimage.png?alt=media&#x26;token=1e1c7b47-dc33-4432-9062-a24e4c951ff8" alt=""><figcaption></figcaption></figure>

Set up crystal oscillator constraints in the "Crystal Oscillators" section of Circuit Comprehension.&#x20;

To add a crystal oscillator constraint, enter the following information:

* Crystal (reference designator)
* Parent component
* Parent pin 1
* Parent pin 2

If Quilter did not automatically detect your Crystal Oscillator, you can add it manually by pressing the `Add` button.&#x20;



### Physics Rule Checks

The PRCs that validate this constraint after compile are:

**Pin Distance** calculates the Euclidian distance between the closest edges of two pins.

**Layer Switch Count** finds the number of times there is a layer switch in a trace path between two pins

**Trace Path Length** calculates the trace length between two pins of interest.

**Ground Plane Overlap** determines if the ground plane below net traces overlaps at all relevant points.
