Specialist Supplier of Crystals & Frequency Control Componentssales@mecxtal.com.cn0755-26500570
MERLIN home / Rednote / System Validation and Replacement

Choosing Pulse Width for FPGA Clock-Domain Crossing Into a 50 MHz Oscillator Domain

One pulse from the event generator should add one count at the destination. If two oscillators measure correctly yet the count sometimes falls short, first check whether the destination clock samples each pulse. A two-register synchronizer reduces sampling risk. It does not guarantee delivery of every event.

Consider an FPGA development board where events originate in a fast clock domain and the counter uses an independent one. A clock domain is a set of logic driven by one timing reference. Equal oscillator frequencies or an integer frequency ratio do not by themselves establish shared clock edges. Clock sources, actual division and timing constraints determine whether the logic can be treated as synchronous. This example counts synthetic events on a development board without controlling equipment or carrying safety signals.

A synchronizer cannot recover a pulse it never samples

A signal high for one source cycle can be shorter than the spacing between destination edges. If it rises and falls between two destination sampling edges, the first register never sees high and the second has no high to forward. A separate case occurs when a pulse edge is close to a sample edge and setup or hold may be violated. Suitable synchronization stages reduce the risk of metastability propagating. They do not stretch the input. Adding more stages does not fix missed pulses caused by insufficient width.

Single-bit level synchronization can suit a persistent status such as startup readiness. An event that must count once needs a delivery contract. For sparse events with both clocks continuously active, use a pulse transfer block with defined input width and spacing. If closely spaced events must stay distinct, consider acknowledgment and whether the source can wait. If the source cannot wait and events can arrive in bursts, use a queue or counting protocol and define full, overflow and reset behavior. Synchronizing the individual bits of a multibit value does not guarantee a coherent word.

Worked examples: pulse capture and minimum spacing

For an ideal timing example, use a 100 MHz source clock with a one-cycle high pulse of 10 ns. The 50 MHz destination samples every 20 ns. If it samples at 0 and 20 ns and the source is high from 4 to 14 ns, neither edge sees high. A missed count can occur with perfect nominal frequencies. The example omits setup and hold margins, and it does not predict that random timing loses half the pulses.

Suppose a pulse transfer block requires a low gap at least twice the longer clock period and an input state the destination can sample at least twice. The nominal low gap is 2 × 20 ns = 40 ns, measured from the first pulse's falling edge to the next pulse's rising edge. If rising edges are 45 ns apart with a 10 ns pulse, the low gap is 35 ns, below the requirement. If the source works in integer clock cycles, use the widths and gaps it can actually generate. A synchronous 100 MHz generator cannot be assumed to produce a 45 ns interval. For release, recalculate with the slowest possible clocks, the specific block rules and margin.

Capture consistent evidence from both domains

Keep a local count in each domain, then read snapshots through a timing-verified debug interface. Directly sampling every bit of the source counter with the destination clock can create an apparent jump in the captured value. An external instrument can compare clocks and markers, while software counts still need to match the recorded test run. Fix the event total and wait for both sides to drain before comparing. Events still in the crossing pipeline are not missing.

Establish a baseline with widely spaced events. Vary the start and relative phase in controlled sequences to cover events near sampling edges. Then run a dense sequence with only pulse spacing changed. Keep the same oscillators and count window. If misses occur only for narrow or dense pulses, investigate the crossing and buffering. If widely spaced pulses also go missing, check the source count, destination enable and reset, interface levels, actual clock tree and operating mode.

CheckEvidence to keepWhat it helps rule out
Clock treeActual sources, derivation, slowest clock and allowed stopped statesWrong clock or asynchronous paths treated as synchronous
Source eventMinimum high width, minimum low gap and maximum burst lengthEvents outside the transfer block's contract
Destination countLocal snapshot, read time, reset and overflow statusPending events or incoherent reads mistaken for losses
Debug regressionCrossing method, sparse and burst cases, and their resultsA pass based on a single error-free log

An immediate snapshot can show a one-count difference while the destination is still draining. Define reset-to-zero, start, source completion, destination drain and snapshot. If the design starts a new count after each reset instead of keeping pending events from before reset, document the rule and avoid comparing counts from different reset periods. If the destination clock can stop, specify whether source events pause, queue or are discarded in each state. Continuous-clock results do not cover stopped-clock modes.

What does engineering need to specify for procurement?

Japan's NDK NZ2520SH family includes CMOS active quartz oscillators covering the example's 50 MHz range. This is a candidate reference for the hypothetical board, without identifying an existing fitted part or order code. Specify actual clock destination, supply, input thresholds, footprint, control pin states, load, temperature range and overall frequency tolerance. Verify the required conditions against the complete part identity. Check output timing for cold start, resume and steady operation and retain actual receiver waveforms for timing analysis.

“Low jitter” and “high accuracy” on a quote do not establish those conditions. If a candidate changes output edges, load or control pin logic, retest at the receiver even if frequency matches. If misses already reproduce in digital simulation and follow from an ideal edge diagram, the logic path has the stronger evidence. Keep procurement candidates pending until substitution qualification is complete.

Frequently asked questions

Can the crossing protection be removed if one oscillator supplies both modules? Check actual clock derivation, phase, gating and reset behavior, and confirm the paths through timing analysis. Use an appropriate crossing method if the relationship cannot be guaranteed.

Will stretching every pulse prevent losses? It can help a receiver detect a sparse event, but two close events can merge into one high level. For a one-for-one count, show that events remain distinct, peak load does not lose them and recovered counts follow the agreed reset and ownership rules.

WeChat

MERLIN · TIMING COMPONENTS

Scan with WeChat to contact Sales

Add our WeCom contacts from your usual WeChat app.

On desktop, scan with your phone. On mobile, save the QR image and select it from your album in WeChat Scan.