(Attachment Link) Ok, drawn with mouse so SET mousestate == jerky
and my first attachment so anything could happen. (Attachment Link)
@Chris_Mr
Someone told me this circuit that you suggested would not be able to generate 90 degree phase shift.
However, I am not convinced yet.
I am planning to get it works with the D flip-flops hardware primitives in sky130 PDK since pure verilog coding would not be able to model your circuit.
By the way, when I research further, it seems that digital PLL might not be needed at all in this context. Please correct me if wrong
https://patents.google.com/patent/US9158873
https://patents.google.com/patent/KR20050101864A/en
https://patents.google.com/patent/US7443741B2/en
https://patents.google.com/patent/US9001595
This circuit doubles the clock rate, then produces a 90° phase shift by dividing by four. So in effect it halves the input clock rate to achieve the output clock rate using what is 180° phase shift relative to the incoming clock.
You can use the same logic without doubling the input clock rate and get an output clock rate that is a quarter of the input clock rate with 90° phase shifts.
You can also get the same result of 90° phase shifts at half the clock rate without doubling the input clock by having one of the FFs operate on the falling edge of the clock.
You can not get 90° phase shifts at the input clock rate by combining the clock rate doubling with the negative edge clocking because the frequency doubled clock does not have a 50/50 duty cycle or anything close to it. In fact, that circuit is not guaranteed to work in any logic family. It most likely is failing clock timing specifications and possibly voltage specifications.
Oh yeah, you can simulate this from HDL inferred logic. First simulate in a language simulator which will produce infinitely narrow clock pulses. You can also simulate after synthesis using the primitives generated rather then instantiating primitives.