Synchronicity of two signals
Using cross-correlation and finding the peak is one way of finding the time delay between two signals.
This assumes that the two signals are periodic and have the same fundamental frequency.

When the two signals have close, but not equal fundamental frequency, the lag position of the maximum cross correlation value will change in time.  If the lag of the maximum does not change (and some thresholds are satisfied so you're not just cross-correlating two very weak signals with the same 60 Hz hum in the background), the two signals are synchronous.  If it changes slowly, that indicates the degree that the two signals have different frequencies.  If the lag requires T seconds for the lag to slide one period (which would be the distance between lags of maximum correlation) in one second, the two signals differ in frequency by 1 Hz.