How to introduce 90 degree phase shift to 555 timer?

Thread Starter

Gilsdank

Joined Jul 21, 2020
5
hello,
I need to generate 2 signals: a square wave of a pretty low frequency, say 10hz. Right now I'm using a 555 timer to generate the square wave. I also need another square wave 90 degrees out of phase.
How can I do this?
I've attached a picture of the signals I need.
Thank you in advance.
 

Attachments

WBahn

Joined Mar 31, 2012
30,045
Use the 555 to generate a signal at 4x the frequency and then use a finite state machine clocked by that signal generate your two quadrature waveforms. That way you don't have to worry about trying to get a 50% duty cycle from the 555.
 

Thread Starter

Gilsdank

Joined Jul 21, 2020
5
Use the 555 to generate a signal at 4x the frequency and then use a finite state machine clocked by that signal generate your two quadrature waveforms. That way you don't have to worry about trying to get a 50% duty cycle from the 555.
Ah yes, a finite state machine :p I know about those on a very basic level, but have no idea how I would implement that.

Would I use a series of latches?
 

Thread Starter

Gilsdank

Joined Jul 21, 2020
5
Use the 555 to generate a signal at 4x the frequency and then use a finite state machine clocked by that signal generate your two quadrature waveforms. That way you don't have to worry about trying to get a 50% duty cycle from the 555.
It actually looks like this might work?
If I had my 555 running twice the speed of my desired clock I can use the QA signal and the QB signal as my 2 clocks.
 

Attachments

Papabravo

Joined Feb 24, 2006
21,225
Yes -- that is precisely how you should do it. Bravo!
It is NECESSARY, the devices be clocked flip-flop of any flavor instead of latches. Latches are level sensitive rather than edge sensitive.
 

WBahn

Joined Mar 31, 2012
30,045
It actually looks like this might work?
If I had my 555 running twice the speed of my desired clock I can use the QA signal and the QB signal as my 2 clocks.
Look carefully at your (main) two waveforms that are in quadrature, namely Qa and Qb. The 555 is not running at twice those clock speeds, but at 4x those speeds.

You can get quadrature waveforms using a 555 running at just twice the clock frequency, but you have to use both edges of it and the result is that it is somewhat difficult to get true quadrature waveforms -- but they are close enough for most purposes. I don't know if they would be close enough for yours.
 

WBahn

Joined Mar 31, 2012
30,045
Yes -- that is precisely how you should do it. Bravo!
It is NECESSARY, the devices be clocked flip-flop of any flavor instead of latches. Latches are level sensitive rather than edge sensitive.
Sure you can use level-sensitive latches. You simply need to provide the needed combinatorial logic to control the signals to the latch inputs.
 

Papabravo

Joined Feb 24, 2006
21,225
Sure you can use level-sensitive latches. You simply need to provide the needed combinatorial logic to control the signals to the latch inputs.
Sure you can use level-sensitive latches. You simply need to provide the needed combinatorial logic to control the signals to the latch inputs.
The uninitiated might not be aware of that. I cannot remember a time or a situation where a choice had to be made.
 

Thread Starter

Gilsdank

Joined Jul 21, 2020
5
The uninitiated might not be aware of that. I cannot remember a time or a situation where a choice had to be made.
Yeah my bad on calling them latches, I said latches but in my head I was thinking of like a d flip-flop.

Ahh I see WBahn, you're right! Well thank you both for your help. I did a little circuit up in spice and it works great!
 
there is a simpler way too - as the 555 timer cap goes from 1/3 Vcc to 2/3 Vcc as it runs, if you use 2 resistors to give 1/2 Vcc and connect this to a comparator, and the timing cap signal to the other, you will get a 90 deg phase shifted square wave out of the comp ... - not quite as exact as going to 4 x freq and dividing down - but good for many apps ...
 

WBahn

Joined Mar 31, 2012
30,045
there is a simpler way too - as the 555 timer cap goes from 1/3 Vcc to 2/3 Vcc as it runs, if you use 2 resistors to give 1/2 Vcc and connect this to a comparator, and the timing cap signal to the other, you will get a 90 deg phase shifted square wave out of the comp ... - not quite as exact as going to 4 x freq and dividing down - but good for many apps ...
If everything worked perfectly that would give a phase shift of just under 75°. That MIGHT be good enough, but for most apps where a quadrature signal is needed, that's probably not.
 

Thread Starter

Gilsdank

Joined Jul 21, 2020
5
If everything worked perfectly that would give a phase shift of just under 75°. That MIGHT be good enough, but for most apps where a quadrature signal is needed, that's probably not.

I've created the wave form I need, and I'm fairly certain that 90° shift is important.
I've atrached the apuce screenshot of the signals im generating.
 

Attachments

WBahn

Joined Mar 31, 2012
30,045
I've created the wave form I need, and I'm fairly certain that 90° shift is important.
I've atrached the apuce screenshot of the signals im generating.
I take it the purple and green waveforms are what you need? If so, the you don't need two square waves that are 90° out of phase because that's not what those are.

If you want two square waves that are in quadrature, why not just use the Q outputs of your two FFs directly? The output of the right one follows the output of the left one by 90°. Just those two FFs form a synchronous state machine being clocked at 4x the frequency of the two output waveforms. Sound familiar?

https://forum.allaboutcircuits.com/...-phase-shift-to-555-timer.171489/post-1533835

Depending on what you are using those signals (the purple and green waveforms) for you need to be a bit careful in general. If they are being used as clocks (or any other edge/glitch sensitive circuit), then you are using what are known as "gated clocks" and there be lots of demons there. Fortunately, in this case, the state machine you are using is a two-bit gray code counter and one of the common applications for such a counter is for producing glitch-free gated clock signals.
 
Top