# Phase shift just with a logic gates

Is it possible to shift the signal phase in the digital domain without the use of a microcontroller, only with the help of logic gates? I would like to have control and, for example, use a potentiometer to continuously variable phase shift of one clock signal in relation to the other - both of the same frequency. The phase shift range between 0-170 degrees. Thank you.

• How would you attach a potentiometer to "just logic gates"? It is an analog device. Other than that you are looking for delay circuit rather than "phase shift" Apr 22, 2021 at 21:36
• A microcontroller is just logic gates. Just lots and lots and lots of logic gates. So -- yes. You certainly could do this with "just logic gates" in the sense of a whole bunch of 7400-series logic on a really big, power-hungry board, but you'd be talking square feet of board instead of square inches. Tell us what you're really trying to do, and why you want to complicate things by not using a microcontroller. Apr 22, 2021 at 21:45
• Just as an example of the type of questions you need to answer: A potentiometer has near infinite resolution while digital circuits do not. What is the smallest increment of phase you want? Also is this for one frequency or a band of frequencies? What accuracy do you want? etc. Apr 22, 2021 at 21:54
• I don't want to use a microcontroller because I set myself such a task. It can be said that it is a form of exercise. I figured it out so that if I take two signals - one of which will have a phase shift - to the input of the XOR gate - the result will be a PWM signal with a variable, adjustable duty cycle. Thanks. Apr 23, 2021 at 6:35
• @EugeneSh. Yes, it could be a delay circuit, but is it not the same at the end? Apr 23, 2021 at 6:37