Clock Recovery and Synchronization

แชร์
ฝัง
  • เผยแพร่เมื่อ 28 พ.ย. 2024

ความคิดเห็น • 145

  • @AllElectronicsChannel
    @AllElectronicsChannel  2 ปีที่แล้ว +2

    Support the channel becoming a Patreon: patreon.com/allelectronics

    • @andersonnobre5163
      @andersonnobre5163 2 ปีที่แล้ว

      I am a brazilian electronic tecnician. I have learned Telecom in yours electronic YOU TUBE Channel. THANK you my dear teacher Greg!!!!!😎😎😎

  • @abumufeed214
    @abumufeed214 วันที่ผ่านมา

    great video. i have been waiting for this for months. it sheds me the light. crystal clear. thank you.

  • @trappedinthefuture
    @trappedinthefuture ปีที่แล้ว +1

    Thanks so much for this! I've spent almost two weeks failing to do clock recovery on an NRZI signal using a CD4046 PLL chip. I just couldn't figure out why it loses lock as soon as any zeroes appear in the data stream. Analog is not my forte and I had a horrible time working with the 4046. I decided to try a digital solution and your Arduino method works flawlessly for NRZI with some small modifications. Absolutely brilliant!

  • @FanMaoyi
    @FanMaoyi 2 ปีที่แล้ว +2

    A great hand-on demonstration and explanation of the background theory! Thank yuo so much!

  • @raziehakhlaghi4116
    @raziehakhlaghi4116 ปีที่แล้ว

    Thank you so much, I have watched several videos to find out what a clock recovery is but didn't get any clue, and now I can find it out. Although I know nothing about electronics, your explanation makes it easy to understand. Thanks again.

  • @canadian_spaceman
    @canadian_spaceman 2 ปีที่แล้ว +6

    I had always wondered how this was accomplished. Thank you for making a video about it! Very informative, and the paper is excellent.

  • @umpoucosobreconhecimentos
    @umpoucosobreconhecimentos 2 ปีที่แล้ว

    The best channel of analog and digital signal ever.

  • @MIsam-fv9kb
    @MIsam-fv9kb 2 ปีที่แล้ว +7

    Great video 👌.I think you should advertise your channel in the bigger electronics channels because you deserve more subscribers and Electronics engineers out there are missing great stuff.

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว +1

      Thanks! The best way is you helping me spreading the content !

  • @YUNGeggFoo
    @YUNGeggFoo ปีที่แล้ว +1

    Thank you for the clear explanation

  • @_wave64_
    @_wave64_ 2 ปีที่แล้ว +1

    Interesting introduction and explanation of the digital PLL with the NCO. Instantly reminded me of the horizontal sync mechanism in old TVs, where sampling the horizontal deflection ramp by the sync pulse generated the error voltage for the horizontal oscillator. Pretty sure the digital PLL is the same idea. Great videos, great channel!

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว +1

      Really nice, I didn’t know that old TVs used this technique. Thanks!

  • @PanosKontogiannis
    @PanosKontogiannis 7 หลายเดือนก่อน

    great video, the best I have seen so far explaining the phase detector and bit recovery clock. You could implement the pulse edge detector in software by attaching two interrupts (a rising edge and a falling edge interrupt routine) performing the phase sensing.

  • @gabriele8339
    @gabriele8339 5 หลายเดือนก่อน

    awesome video. I’s been wanting to understand this exact process for months

  • @DeepaGouravaram
    @DeepaGouravaram 10 หลายเดือนก่อน

    Excellent video, crystal clear understanding.. thank you for putting this together,

  • @marcuslim3513
    @marcuslim3513 ปีที่แล้ว

    Awesome video! You are a great engineer and a brilliant communicator. Keep it up!

  • @abhiruplahiri1
    @abhiruplahiri1 11 หลายเดือนก่อน

    That’s a good one, essentially the use of low bandwidth PLL is equivalent to using a very high Q (Q>> no. of consecutive bits) band pass filter after the edge detector. Using such a band pass filter too, will help recover the clock.

  • @tishakalongi4934
    @tishakalongi4934 ปีที่แล้ว

    Thanks for the video! With all the visualizations and hands on it was way easier to understand! After this video the slides of my prof make way more sense haha

  • @pixiepaws99
    @pixiepaws99 ปีที่แล้ว +1

    EXCELLENT explanation!

  • @TheRemo176
    @TheRemo176 2 ปีที่แล้ว +2

    Excellent video !
    I have a question, why did you choose 9° as the phase lock target ? I understand that this allows the data signal to settle before taking a reading, but by that logic why not choose 180° so that the reading falls right "in the middle", furthest away from the rising and potential falling edge ?
    Thank you !

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว +1

      There not a reason.. I only chose 90 deg.
      90deg is also a common phase of equilibrium in hardware PLL, when using the XOR phase detector

  • @dan77ring3
    @dan77ring3 2 ปีที่แล้ว

    I want to thank you for your videos!, I Have thanks to them built a VCO and bought to many frequency counters :). Thanks for the inspiration!!

  • @ruhnet
    @ruhnet 2 ปีที่แล้ว

    Incredible explanation-thank you so much for this!

  • @lawrencenwaogo6658
    @lawrencenwaogo6658 2 ปีที่แล้ว

    Thank you so much for this great video, you have explained this topic very well.

  • @asherv.4332
    @asherv.4332 2 ปีที่แล้ว

    Very clear explanation. Thank you.

  • @rjordans
    @rjordans 2 ปีที่แล้ว +1

    Nice one again! Maybe another step could be to use the recovered clock and persistence on the data trace to make this into an eye diagram and check the quality of your data line 😀

  • @gammaleader96
    @gammaleader96 2 ปีที่แล้ว

    Very nice, my previous experience with clock recovery was mostly that it is a pain in the butt.
    I had to implement it in a FPGA for my Master thesis, where I didn't really have a spare PLL.
    I built a similar approach though, since the bitrate was known but could have some tolerance, I started with an edge detector, and counted the time between the pulses, I then took the minimum time and averaged it. I then took this to correct the expected bitrate. I works fine, however when there are VERY long bitstreams of only 1s or only 0s, it gets pretty inaccurate.
    To prevent this, very long pulse times get sorted out. This turned out to be very stable.

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว +1

      Nice!! I have used that technique I called feedforward clock sync.
      This technique also happened me when I made tesla coils, using a FPGA you can compensate the on/off delays of the IGBTs. It is safer because a closed loop pll could destabilize killing the power bridge !

    • @CSFitness1
      @CSFitness1 2 ปีที่แล้ว

      Aren’t long sections of 0’s/1’s avoided by using special coding schemes that create a more balanced bitstream?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      Yes !

  • @10lbslighter
    @10lbslighter ปีที่แล้ว

    Good one. Thank you for creating the video. Take a lot of effort - with lab setup etc. It is highly appreciated. My brain is 10 lbs heavier after this video - the burden of knowledge. :)

  • @francescoesco123
    @francescoesco123 ปีที่แล้ว +2

    That was amazing.

  • @Gaygurke
    @Gaygurke 3 หลายเดือนก่อน

    Thank you! That video was great!

  • @iPatroni
    @iPatroni 2 ปีที่แล้ว

    Very interesting and well explained. Thanks.

  • @Elektronik-1
    @Elektronik-1 2 ปีที่แล้ว

    Hallo! Habe ich da am Anfang "...and in DIESEM Video" gehört? Aufgrund deiner Aussprache hab ich immer angenommen, dass deine Muttersprache Englisch ist, stimmt das gar nicht? Wo wohnst du?

  • @amanuelnigatu4621
    @amanuelnigatu4621 ปีที่แล้ว

    Thank you for making this video...tnx man

  • @kb3khs
    @kb3khs ปีที่แล้ว

    Great explanation of the digital PLL. I'm just a simple hobbyist. I'm trying to recover a clock from an analog carrier signaling digital data via phase shift keying. I was curious. How could you recover a clock from that? It seems like edge detection is a different beast in this regard. I think delaying the signal and doing math on the samples is still applicable, but obviously XOR won't work. I tried simply dividing and that generate pulses on phase(edge) transition... but only if my delay signal was at a specific phase relationship to the realtime signal. Is this the wrong approach altogether?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      I have a video showing a squsting loop bpsk detector. Take a look. It is basically a PLL over the signal squared. Squaring removes phase information, pll locks to that and its output is a stable reference to further decode the bit stream

  • @lucasmarjona
    @lucasmarjona 2 ปีที่แล้ว +1

    Tardé 2 ns en saber que eran 90 grados y no 9 jaj. Muy buen video. Nice english too! Salut!

  • @shvansedeeq3776
    @shvansedeeq3776 3 หลายเดือนก่อน

    quick question. what are the consequence if you oversampling it even shifting the sync signal with 90 degree? like would the detector go on the edge?

    • @AllElectronicsChannel
      @AllElectronicsChannel  3 หลายเดือนก่อน

      Hi, I did not get. For the digital version I demonstrated, the system is running oversampled.

  • @ahyungrocks5509
    @ahyungrocks5509 6 หลายเดือนก่อน

    At the FFT waveform, there were peaks at 1.2KHz, 2.4, and 3.6. Why does 2.4 and 3.6KHz come from?

    • @AllElectronicsChannel
      @AllElectronicsChannel  6 หลายเดือนก่อน

      The frequency components of time domain pulses are also "peaks" in frequency, spaced by the 1 / T, where T is the repetition period of the pulse.

  • @abhishekshakya1250
    @abhishekshakya1250 ปีที่แล้ว

    excellent explanation

  • @SandeepKumar-jj7zi
    @SandeepKumar-jj7zi 2 ปีที่แล้ว

    Nice, quite useful to know of NCO, i think it can be used to used to implement a digital PLL for a grid connected inverter..

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว +1

      It is a perfect use! Replace the edge detector with a zero crossing detector and voala!

  • @dan77ring3
    @dan77ring3 2 ปีที่แล้ว

    I would like to ask you a question. Can a crystal filter "coulour" the output frequence due to the crystals oscilation? For example: imput 10mhz and get a frequency out that dont correspond exactly with the input frequency due to the crystals in the filter?

  • @HowlingDeath
    @HowlingDeath 3 หลายเดือนก่อน

    I'm CSE student, and trying to understand this PLL thing. Guys at 7:35 , "If we have bit rate of 1200 bits ...pulse will be of 1200 Hz.." My Question is :
    once we detected edges/pulse of input signal
    (which will have different widths/distance between pulses dependent on data for example 110001, so the pulse would be like **|***| (*=diff volt representing bits 1 or 0 , edges=|), right?) ,
    how do we get correct clock? . Also (7:35) why pulse repetition rate would also be 1200 Hz, which is dependent on data bits. for examples a data like 1001111100110 wouldn't have edges/pulse of same interval. would it?

    • @HowlingDeath
      @HowlingDeath 3 หลายเดือนก่อน

      @AllElectronicsChannel plsss help me understanding it

  • @shabeesatsangi
    @shabeesatsangi ปีที่แล้ว

    one the rare video _ thanks for sharing

  • @te9781
    @te9781 2 ปีที่แล้ว

    Great video have a question though..it might be long but bare with me.. to my understanding in ethernet UTP 100mbps we use 4b/5b coding with NRZI to increase the number of transitions (edges) so we don't loose the phase lock of the clock.. in fiber though we are using NRZ not NRZI so multiple 1s or multiple 0s in data can cause loosing the clock synch due to edges absence.. how this is solved in fiber ?

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว +1

      Thanks man!
      I don't know the exact case of fiber.. A common technique is called bitstuffing
      It is very simple: we force a transition when we have a long stream of zeros or ones.
      USB uses this technique. For example, we can add a transition always we have more tha 5 zeros/ones
      000000000 -> 0000010000
      The receiver knows this and ignores the bits inserted

    • @te9781
      @te9781 2 ปีที่แล้ว

      @@AllElectronicsChannel
      I think this is the correct answer ..thanks again for the great video

  • @seanbosse
    @seanbosse 2 ปีที่แล้ว

    This is awesome. Thank you!

  • @rangowang9432
    @rangowang9432 ปีที่แล้ว

    I have a question. From spectrum of the NRZ encoded signal, we can find that the bit rate is 1200Hz because the notch happens in 1200Hz. From 1200Hz, it's enough to get CLK. However, why do you still want to get 1200 from Spectrum of signal edges?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      Hi! You need information at 1200Hz to recover the phase of the clock. Seeing the notch is notch exactly knowing the phase!

    • @rangowang9432
      @rangowang9432 ปีที่แล้ว

      @@AllElectronicsChannel You means that from the notch we can get 1200Hz,but not the phase of CLK, so we still need to get signal and spectrum of the signal edge from which we can get the phase by PLL?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      Even more than that.. you are seeing the notch because you are a human... but there is not energy there, there is no way to "capture" the notch.. to "measure" the notch.
      When we detect the edges we are generating energy at 1200Hz. Energy that we can measure with the PLL, lock on it...

    • @rangowang9432
      @rangowang9432 ปีที่แล้ว

      @@AllElectronicsChannel Thanks so much! I totally understand my question. Really thanks, the funny thing is that my none of my teacher have ever taught me that and I always feel confused about the basic concept. Thanks!

  • @setitthen
    @setitthen ปีที่แล้ว

    Hi could you explain: the two characters ? : in the following syntax why are they there PORTB = (nco) ? (PORTB | (1

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว +1

      Search for Ternary operator

    • @setitthen
      @setitthen ปีที่แล้ว

      @@AllElectronicsChannel thank you for your prompt reply.

  • @lawrencenwaogo6658
    @lawrencenwaogo6658 2 ปีที่แล้ว

    Hi, thanks for the video, watching for the second time. I have a question, could this setup work using SFP, CPRI and optic fibre? Thanks once more in advance.

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว

      Of course! It is used

    • @lawrencenwaogo6658
      @lawrencenwaogo6658 2 ปีที่แล้ว

      @@AllElectronicsChannel Can you prepare a course on that, from basics to advanced, I am interested in that (if affordable or free), I want to capture the entire workflow. Thanks

  • @parasvaish3239
    @parasvaish3239 2 ปีที่แล้ว

    Beautifully Explained, fantastic work sir. I will be regularly following the channel for videos and spread the good word too. Keep up the good work. By the way which is the preferred method to support the channel via patreon or YT super thanks, I have heard that YT takes a cut at its end

  • @oqueeuseisobre
    @oqueeuseisobre ปีที่แล้ว

    Gregory! Sabe muito!!!!!

  • @industrialdonut7681
    @industrialdonut7681 ปีที่แล้ว

    Excellent video! I was able to implement in arduino and then on FPGA since actually for a 9600 baud rate, an arduino running at 8MHz may actually only get a signaling rate of like 40KHz since here you have to implement the NCO in software and the phase alignment logic. That's as fast as my main loop would run at least, so there's basically no fine control over the phase to be 9 degrees lol. My recovered clock WAS shifted properly for reading the UART but I believe the phase is entirely due to the mentioned slowness. It happens to make a good phase angle for the data signal to stabilize at 9.6KHz... but I wanna do faster shit like USB next.
    Oh also, yeah I did this on my FPGA too, and the difference was that it locked on 100% to the edges pretty much perfectly as soon as I could just get the verilog to compile. That's the difference from 100MHz and like (in the range of) 100KHz

  • @김성훈-r9c2q
    @김성훈-r9c2q 10 หลายเดือนก่อน

    선생님 감사합니다

  • @sheikmohamed6238
    @sheikmohamed6238 5 หลายเดือนก่อน

    What happens when continuous 1's or continuous 0's are sent ?

  • @gkamendje
    @gkamendje 2 ปีที่แล้ว

    Hello, how should the PLL design change when the frequency of the NRZ data is variable (varying for example from 40Khz to 640Khz)/

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว

      You need to vary the center frequency of the NCO to match the data rate.. So the PLL makes smalls adjusts to align the NCO.

    • @gkamendje
      @gkamendje 2 ปีที่แล้ว

      @@AllElectronicsChannel Thanks a lot. That's what I was thinking.

  • @sadlittlesinner
    @sadlittlesinner 3 หลายเดือนก่อน

    Forgive my dumbness, I was always confused by clocks and still am. Have a question:
    So If I for example. continuously have data 00110011... and PLL is locked thinking clock is actually 2x slower - and now I get data 01 - it won't be recovered correctly? Or did I get everything completely wrong?

    • @sadlittlesinner
      @sadlittlesinner 3 หลายเดือนก่อน

      Ok I think I found online that training sequence and type of encoding where each bit is represented by transition is what helps this?

    • @AllElectronicsChannel
      @AllElectronicsChannel  3 หลายเดือนก่อน

      Yes! And also: the PLL will not think the clock is 50% lower... The PLL is designed to correct for deviations.. like 5 ppm (100 * 5 / 1000000) %

  • @tejshah8197
    @tejshah8197 2 ปีที่แล้ว

    Thank you so much

  • @IW2MXP
    @IW2MXP 10 วันที่ผ่านมา

    12:17 9°? Maybe you mean "ninety" degrees? Anyway, very nice presentation. Thank you very much.

  • @syedtahaquadri7153
    @syedtahaquadri7153 11 หลายเดือนก่อน

    I dont understand when you say pulse repeatation rate will also be 1200HZ?? How can it be ?

  • @breedj1
    @breedj1 2 ปีที่แล้ว

    Cool. Well explained

  • @saneel1988
    @saneel1988 11 หลายเดือนก่อน

    Super awesome!

  • @sbybill3271
    @sbybill3271 ปีที่แล้ว

    Why is the baud rate edge visible?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      hum, I did not understand the questio, hehe

    • @sbybill3271
      @sbybill3271 ปีที่แล้ว

      @AllElectronicsChannel I think my question isn't very clear. Apologies for that. Please see that at 4:53 the spectrum shows dips (notch) at regular intervals at the baud rate. What causes these dips to appear (become visible) in the spectrum?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      It is a direct result of the phenomena of spectrum domain. The Fourrier transform of a pulse with finite width is a sin x/x with notches at the main frequency.

    • @sbybill3271
      @sbybill3271 ปีที่แล้ว

      @@AllElectronicsChannel That explains it well. Thanks ❤️

  • @matthewgilliam7720
    @matthewgilliam7720 ปีที่แล้ว

    I love your stuff

  • @electrotechelectrotech112
    @electrotechelectrotech112 2 ปีที่แล้ว

    Please help me I'm rf equipment repair work my requirement 22 ghz spectrum analyzer any old used

  • @KayOScode
    @KayOScode 2 ปีที่แล้ว

    Im not seeing how this works with oscillating or non constant clock frequencies. Very interesting though

  • @tenminutetokyo2643
    @tenminutetokyo2643 ปีที่แล้ว

    That’s nuts!

  • @nova0302
    @nova0302 ปีที่แล้ว

    Hey! Bro! It's a great video and really appreciate your effort.
    I'm looking into your arduino code but it's not that easy to match your code with the diagram.
    Could you add some comments on the arduino code and some math equations for the diagram.
    Thanks Bro again!!

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      Hi man, thanks! The code have many layers of tricks/simplifications... Which parts you want to understand better? I can help you here

    • @nova0302
      @nova0302 ปีที่แล้ว

      @@AllElectronicsChannel Thanks for quick reply! I manage to understand most of the code except for one thing, "delay equalizer", can you elaborate on that part? What if i remove the code?

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      @@nova0302 Nice!! The "delay equalize" is a trick used to make the run time of code be the same for different branches.
      In this way, we have less jitter on the overall loop, because different paths of the code will need more/less time to execute.
      So probably I added the "delay equalizer" in a fast section of the code, to make the execution time of that branch more even in respect to other branches of code

  • @rezafazli2005
    @rezafazli2005 9 หลายเดือนก่อน

    😍Thank you

  • @Marvin_Wang
    @Marvin_Wang ปีที่แล้ว

    It is great!!!

    • @AllElectronicsChannel
      @AllElectronicsChannel  ปีที่แล้ว

      Glad you liked!

    • @Marvin_Wang
      @Marvin_Wang ปีที่แล้ว

      @@AllElectronicsChannel Sorry, can't find a way to contact with you, but really like your videoes, and could you help to confirm, if I can post your video on my channel, to spread your great energy?

  • @wecw1996
    @wecw1996 2 ปีที่แล้ว

    can anyone give real world examples for coth a corporate level and personal use level of this concept

    • @AllElectronicsChannel
      @AllElectronicsChannel  2 ปีที่แล้ว

      Real world examples?? Your message arrived at my phone passing 500 levels of clock recovery through all digital media it traveled!! 😝😝😝

  • @-.-aaa
    @-.-aaa ปีที่แล้ว +1

    baud rate is the same as symbol rate and should be in symbols/sec instead of bits/sec...some information can be misleading, so I tend to take it with a grain of salt...

  • @ferashamdan4252
    @ferashamdan4252 5 หลายเดือนก่อน

  • @ayazar
    @ayazar 9 หลายเดือนก่อน

    Wow

  • @RandomPlayer007
    @RandomPlayer007 ปีที่แล้ว

    The best thing i did today is cmng across your channel, its our channel❤

  • @electrotechelectrotech112
    @electrotechelectrotech112 2 ปีที่แล้ว

    Hi sir

  • @dantesalvesdesantana2766
    @dantesalvesdesantana2766 2 ปีที่แล้ว

    👍🤗

  • @ahmednor5806
    @ahmednor5806 8 หลายเดือนก่อน

    🙏🙏🌹🌹🌹🌹