MCLK at 24.576MHz: how bad is the signal integrity? - Page 1
Forum section: electronics / projects

author: hitech95
author_rank: Regular Contributor
timestamp: January 21, 2022, 12:11:57 am
content: Hi,I've desiged an audio board a year ago, but until recently due to chip shortage I was not able to assemble it.I've finally received all the parts but it is not working as intended.I've assebled one but the digital Amplifier IC have a flag about a bad MCLK, BCLK, LRCLK clock.That said with a logic analyzer cature everything seems fine, so I've asked a friend to take a capture with a scope:(Yes the photos are what they are... he is a SW guy like me and borrowed the scope at work during launch break)MCLK:BCLK:LRCLK:These clocks are generated by a PCM9211, it have a 24.576Mhz OSC and with internal dividers it generate the various clocks.The quartz clock seems fine to me, but the MCLK is really noisy.On the board I have impedance matched traces set at 50Ohm, it is a 4 layer board with GND planes in the middle.The amplifier IC and the PCM9211 (Digital MUX and ADC) are only 2cm apart. so no long traces that might introduce a lot of delay.Any idea on why this is happening? Any suggestion on what I could try to solve this?

author: fourfathom
author_rank: Super Contributor
timestamp: January 21, 2022, 01:38:14 am
content: Can you show us the layout?It's hard to tell what's going on, since the ringing shown on the scope could easily be due to scope probe ground lead placement, but assuming that the signal is really as shown here are some comments:* 2cm is quite short, and I wouldn't expect a lot of ringing -- but depending on the actual trace length and edge rate I suppose it's possible.* There's nothing wrong with 50 Ohm trace impedance, but it's unlikely that you have either 50 Ohm driver Z or 50 Ohm input Z so you still need to take steps to get a good clock signal. We commonly put a series resistor at the driver output to help match the trace Z, slow down the edge, and absorb reflections from the virtually unterminated end of the trace (a typical input pin Z is a very high R and small C to ground). There are other ways to get good signal shape, but this method usually works well. The series resistor method gives a full swing at the output.

author: T3sl4co1l
author_rank: Super Contributor
timestamp: January 21, 2022, 01:47:03 am
content: FYI, imagebb doesn't allow embed images. (They may show on your end due to browser cache.)Seconding the above.Tim

author: fourfathom
author_rank: Super Contributor
timestamp: January 21, 2022, 01:51:23 am
content: Quote from: T3sl4co1l on January 21, 2022, 01:47:03 amFWIW, I saw the image thumbnails. When clicked they opened up in a new "ibb" tab. Using Chrome.

author: T3sl4co1l
author_rank: Super Contributor
timestamp: January 21, 2022, 01:54:40 am
content: Up-to-date Chrome here too.Interesting. On closer inspection, they flash for one frame, then disappear. An ibb script loads but doesn't seem to be tracking. (Maybe. Now I don't see it?) It's uBlock cosmetic filter that's doing it but there's NO rule for those objects, and the logger agrees.Tim

author: hitech95
author_rank: Regular Contributor
timestamp: January 21, 2022, 07:51:40 am
content: Quote from: fourfathom on January 21, 2022, 01:38:14 amI have series resistors, I've put 33ohm in series since I already had that value in the BOM.How can I calculate a more valid value?I'll attach the layout, left chip is the amplifier (TAS5731M) and the right one is the PCM9211 (Dac and Input Mux). The schematics are basically the EVM ones. Initially I've thought that the problom was my crystal beeing bad; I've forgot to put a series resitor on OSC_IN so it might had components. But the scope capture seems clean to me. (It is a cheap one from LCSC)To probe I've soldered a debug connector for my friend, there is some flying wires for it. but they are also short and are connected after the 33Ohm series resistors.The scope was connected to one of those pins at a time, the one at the sides are GNDs (the connector has been soldered down to the PCB to give some stifness and to provide ground reference)I'm including a simplified schematic since the original one is divided into multiple pages.MCKO is an auxiliary clock out of the PCM9211 that I've configured with a divider of 2.

author: jonpaul
author_rank: Super Contributor
timestamp: January 21, 2022, 02:38:45 pm
content: Hello: Terrible ringing looks like artifact of measurement.Exactly how did you probe the MCLK?What is setting on scope?Schematic of entire design?Jon

author: hitech95
author_rank: Regular Contributor
timestamp: January 21, 2022, 02:53:18 pm
content: The amplifier section:https://e2e.ti.com/cfs-file/__key/communityserver-discussions-components-files/6/pastedimage1641852424770v1.pngThe PCM9211 section is mostly the same of the EVM board (I have no coax, and no optical inputs I only use th MPIOs and the ADC):https://www.ti.com/lit/ug/sbau174/sbau174.pdf?ts=1642776354790The difference are the 33Ohm resistors between the TAS5731m and the PCM9211 main output port.Probin has been done on the soldered on additional connector. It have both GNDs and clock signals.The scope configuration should be visible in the pictures.

author: jonpaul
author_rank: Super Contributor
timestamp: January 21, 2022, 03:26:09 pm
content: For 24.576 MHz you need a termination or the stray L/C IC....wires....scope will ring.No photo show entire setup, IC....connections...probe...scope.Jon

author: hitech95
author_rank: Regular Contributor
timestamp: January 21, 2022, 03:48:18 pm
content: Quote from: jonpaul on January 21, 2022, 03:26:09 pmCan you provide more information on what you mean?

author: jonpaul
author_rank: Super Contributor
timestamp: January 21, 2022, 04:03:28 pm
content: Rebonjour:At these frequencies, accurate wave shapes demand a system BW ~ 10X clock or 250 MHz.The systems or holistic approach Draw a diagram of everything in entire signal pathsource><connections><cables><scope>><probe<<terminations.or high frequency techniques, excellent bookhttps://www.amazon.com/High-Speed-Digital-Design-Handbook/dp/0133957241For oscilloscope probe techniques recommendhttps://w140.com/tekwiki/images/6/62/062-1146-00.pdfBon chanceJon

author: fourfathom
author_rank: Super Contributor
timestamp: January 21, 2022, 04:17:05 pm
content: Quote from: hitech95 on January 21, 2022, 02:53:18 pmThat hot-glued additional connector with all the wires? That's going to add major reflections. The scope probe signal will look lousy, and the unterminated stubs (wires and connector pins) will cause major reflections that will show up as ringing at the clock input to the device being driven.The 33 Ohm series resistor is probably about right. The problem is perhaps the layout and definitely the wired connector. Did you have your clock problem before you added the connector?By the way, I'm not criticizing the hot-glued connector, I've done that when necessary and mine looked just as ugly. But mine was for slow signals. You can't treat critical clocks like that.

author: fourfathom
author_rank: Super Contributor
timestamp: January 21, 2022, 04:36:54 pm
content: The way I would probe that circuit (after removing the wires on the clock signals) is to find a good ground connection near the end of the trace. It looks like you may have to scrape off a bit of solder mask. Find a place that's close to a feed-through so you have a short connection to the inner ground plane. I usually scatter grounded pads around the board (with holes for a soldered header pin) so I have available probe-ground points. Connect the probe ground to that ground. Then probe the clock input pin. You will probably see ringing or a step if you probe at the series resistor, but the signal at the pin should be fairly clean -- this is the way an unterminated transmission line works.There are tutorials available that show ways to connect your scope ground, and you may want to review them. The alligator-clip ground is usually OK, but there are ground-probe adaptors that work much better. I've lost my adaptors, but I do just as well by winding a short length of solid bare hookup wire around the probe ground sleeve.

author: hitech95
author_rank: Regular Contributor
timestamp: January 21, 2022, 04:45:40 pm
content: Quote from: fourfathom on January 21, 2022, 04:17:05 pmThe hot glued connector has been added after the clock issues ere showing up by the TAS5731M. I've added it to easy attach probes and the logic analyzer.I know that it is not an ideal probing situation, my friend is not so much into EE. I've had to made a easy connector for him.I'll try to see if he can remove it and probe the mclk directly from the pull down resistor. So I also have GND with a via next to it. As said thoose i2s traces are 22mm in length.I'm not sure if he have such adapters. I know that he used the ground clip.Quote from: jonpaul on January 21, 2022, 04:03:28 pmI dont have such an equipment to see such frequencies, 250Mhz+ bandwidth scope is a bit out of my hobby approach.Since MCLK should be 256fs it should be 12.288MHz so a 200Mhz scope should be enough.If you guys have any suggestion for a better probing I can finally figure out if the issue is MCLK or not.The quite strage thing is that the Amplifier IC could also work with 64Fs to the MCLK input (aka bclk output), but even doing so the flags are there.I would love to exclude the clock signals and see if it is the amplifier IC that is bad... (since chip shortage i got it from ebay so they might be defective/or fakes)

author: jonpaul
author_rank: Super Contributor
timestamp: January 21, 2022, 05:39:23 pm
content: Hello: Digital scopes especially made in China often have poor transient response.Your long Wide spaced wires and connector create an LC circuit that is ringing.Just make Zo probe: Place 1/8 or1/4 W axial resistor 450 Ohms DIRECT to IC pins, attach RG198/U coax to other resistor end and IC ground.Other side of coax to 50 Ohm scope. If scope is 1 meg input use inline 50 Ohm term.Makes a 10X Zo probe.J

author: Bassman59
author_rank: Super Contributor
timestamp: January 21, 2022, 05:59:39 pm
content: Quote from: hitech95 on January 21, 2022, 03:48:18 pmHow long is your scope probe's ground lead, and to what is it connected?Most oscilloscope probe kits include a little curlicue spring thing that you use for your ground reference connection. Remove the ground wire, unscrew the plastic part that covers the probe's business end, and attach the curlicue to the end. It'll have a point that you can use to touch onto a ground via or pin that's closest to the signal you're measuring.

author: SiliconWizard
author_rank: Super Contributor
timestamp: January 21, 2022, 06:51:20 pm
content: Sorry if I missed it, but what is generating the MCLK, BCLK, LRCLK signals?

author: jonpaul
author_rank: Super Contributor
timestamp: January 21, 2022, 06:53:57 pm
content: see OP Hitech95"Posts: 156Country: itComputer technician playing with electronics...View Profile Kytech Personal Message (Online)Re: MCLK at 24.576MHz: how bad is the signal integrity?« Reply #7 on: Today at 02:53:18 pm »Say ThanksReplyQuoteThe amplifier section:https://e2e.ti.com/cfs-file/__key/communityserver-discussions-components-files/6/pastedimage1641852424770v1.pngThe PCM9211 section is mostly the same of the EVM board (I have no coax, and no optical inputs I only use th MPIOs and the ADC):https://www.ti.com/lit/ug/sbau174/sbau174.pdf?ts=1642776354790The difference are the 33Ohm resistors between the TAS5731m and the PCM9211 main output port.Probin has been done on the soldered on additional connector. It have both GNDs and clock signals.The scope configuration should be visible in the pictures."

author: ve7xen
author_rank: Super Contributor
timestamp: January 21, 2022, 07:58:54 pm
content: I think you're chasing a red herring here. I've done some pretty nasty wiring with I2S signals and never had any issues, with signals looking worse than what you're showing here. Your traces actually look reasonably clean for imperfectly probed I2S to me; despite the ringing the edges are clean. The frequencies seem to be correct. I'd look elsewhere for the problem. What source are you using in the PCM2911? Is its PLL locking? Have you quadruple-checked the configuration registers match your clock setup? etc.

author: SiliconWizard
author_rank: Super Contributor
timestamp: January 21, 2022, 08:03:35 pm
content: Yep. Signals are actually not looking bad at all from the screenshots. Very typical digital signals acquired with not enough bandwidth, and/or slightly improper probe grounding. Nothing to fret about, just a bit of ringing. And the capture from a logic analyzer shows that the signals are interpreted correctly. So I would also suspect the part that generates I2S, some mismatch in the format, etc.

author: jonpaul
author_rank: Super Contributor
timestamp: January 21, 2022, 08:13:45 pm
content: Silicon Wizard: My sentiments exactly.perhaps OP has a poor setup for observing, probes or scope.....Jon

author: hitech95
author_rank: Regular Contributor
timestamp: January 21, 2022, 08:40:13 pm
content: Quote from: ve7xen on January 21, 2022, 07:58:54 pmI'm using the PCM9211 internal ADC as a source, so the main OSC clock is divided to generate all the clocks. All the registers seems fine to me, with a simple (PCM5102A) DAC I can get audio out.I've also tried with other I2S sources but I'm facing the same issues. I've prototyped with I2S on breadboard and I've never run into such kind of problems.Initially I've thought that there was components on my OSC (i've forget the damping resistor). TI E2E forum said that the issues are in my clocks...So I'm really starting to think that something is off with the AMP chips... but I'll also have to try with a better probe method.Quote from: jonpaul on January 21, 2022, 08:13:45 pmAs already stated I dont have a scope I asked a friend to do some measurements at its job location.The scope is a SDS2104X Plus...The probing has been done my my friend with a scope from work in after hours. He is a SW guy so he dont actually fully know how to probe properly.He used the siglent probes or the picoscope ones. It was set at x10 with 50 ohm termination.Due to covid regulations I cannot visit him to properly capture the data my myself.So if you think that the clocks are fine and its only probing error/reflections due to my crappy conector I can start figuring out if the issue is the IC.Quote from: SiliconWizard on January 21, 2022, 08:03:35 pmThe TAS chip have an auto detect for the format, the format get detected correctly (register 0x00) but on register 0x02 I have errors.

author: fourfathom
author_rank: Super Contributor
timestamp: January 21, 2022, 09:09:58 pm
content: Quote from: hitech95 on January 21, 2022, 08:40:13 pmThe scope probably wasn't set for 50 Ohm termination. At least with a typical 10X probe I hope it wasn't! But the waveforms don't look like this was the case.Some of the ringing shown looked like it could have been causing double-clocking, depending on the input threshold. But I do think that the clock nastiness is probably an artifact of probing and that wired connector.