question: you have a USB connector on your project. how do you connect the shield? justify your answer, reply to the thread. (click this thread for the poll)
question: you have a USB connector on your project. how do you connect the shield? justify your answer, reply to the thread. (click this thread for the poll) 71 comments
how do you connect the USB connector shield ground to the board's digital ground? justify your answer. Inductive ferrite bead to limit conduction of higher frequencies and keep them off the shield @tubetime through the skin of the device user. So, I guess that would be a very low value capacitor with extremely high ESR? @tubetime capacitor (and high-value resistor in parallel) for ESD protection: the shield is a touch-point and is susceptible to contact ESD strikes. Ref: Microchip AN2587 at https://ww1.microchip.com/downloads/aemDocuments/documents/OTH/ApplicationNotes/ApplicationNotes/00002587A.pdf @tubetime I'd say through a resistor, something like a 10k resistor. Not sure why you'd add a capacitor; I'd guess the shield itself has enough parasitic capacitance to hold an ESD spike. And I don't understand analog electronics enough to know about the inductor, but I can see a case for it. Did once encounter a USB plug converter that just didn't connect GND, so the only GND we got was through shield ground... @tubetime always nail it down. The device isn't expected to have any other earth, and shield isolation isn't needed for signal integrity @tubetime Device side float, host side connect straight to GND. You have a ground loop otherwise. The shield is just to keep stuff off the cable. @tubetime I think there are two possible answers: directly and capacitor. Directly might be preferred for most applications, but it creates a ground loop that might be problematic in some applications. If that is the case, a capacitor might help. I usually put a 0603 footprint to assemble a 0 ohm resistor, that can be replaced by a capacitor if needed. @tubetime direct connection. I used to use a 1nF // 1Mohm connection, but changed to direct after reading an application note or blog. Can’t remember where I read it. @tubetime If it is a Type-C connector, connect shield directly to GND because the spec says to. If it is a host, connect shield directly to GND because the spec says to. If it is neither, you have options, but lately I prefer direct connection because it is simple, easier to pass ESD testing, and has become the norm since Type-C. @tubetime I voted capacitor but in reality it is a parallel RC combination with 1 MΩ edit: Justify it… I'm not 100% shure but I think the reason was grounding the device's case this way enough against static electricity but not providing a real DC-path to prevent ground-loops (host grounds the shield directly, device never). src: some friend at C3PB explained this as the ultimate solution to me so the correct answer is that *it depends on your system grounding strategy* but the most-often-correct answer is to tie them directly together. particularly if you're a hobbyist type, just tie them together and don't worry about it. but if that's not enough for you, continue reading... for professionals, you'll want to study this book very carefully: https://www.goodreads.com/book/show/19168165-electromagnetic-compatibility-engineering your system grounding strategy may involve various frequencies of interest, and what you do depends a lot on that! for example, if you're worried primarily about low frequency interference, you can disconnect the shield ground and get nearly 20dB reduction of noise at 50KHz. however, higher frequencies will see your puny disconnected shield and (due to parasitic capacitance) jump right across anyway! you'll get this same effect when you connect a capacitor between the shield ground and the board ground. you're now just *choosing* where that RF current will go. having an RF current flowing isn't necessarily bad. because of the skin effect, this noise current flows on the outside of the braided shield in the cable while your common mode signal current flows on the inside of the braided shield, and they don't interact (at high frequencies) but if you really don't want those RF currents (perhaps your cable just happens to be the right length to form a monopole antenna to radiate interference) you can add a ferrite bead around the cable. this causes common mode currents to see a higher impedance at high frequencies, and this reduces the current. in my experience with complex interconnected systems, this can turn into a game of whack-a-mole as the RF return current will find a path back (oh yes it will!) using a different route--and it may be a less desirable one! what about the thing with the shield ground tied with an inductor in series? this is part of a *system* of multiple units connected together, and it's called a hybrid ground. with a capacitor in series for each device, your grounding system allows RF return currents to take the shortest path but forces lower frequency currents to go through some other path, presumably a single point ground (audio folks like this!) the inductor approach is less common because RF currents like to couple through parasitic capacitances (as we discussed before), so it's tough to control, but this method gives you a multipoint ground at low frequencies and a single point ground at high frequencies. say we've connected the shield to our board ground. we can still improve on this! page 486 of the book sets up a nice concept relevant to our problem at hand. create a "clean" I/O ground area on the PCB that acts like an extension of the chassis. put your EMI filter parts here. the idea is to direct any EMI on the signals ➡️ to the shield ground return. incidentally this approach does another good thing -- putting all the connectors on one side of the board. we're trying to build a circuit that plugs into a USB jack, not a dipole antenna! here's a fantastic real-world example of this design technique. here's a Macintosh 512K motherboard. with a bright light behind it, you can see the divide between the "clean" IO ground and the "dirty" logic ground. (they did break the rule slightly with the keyboard connector on the front, but they've also extended the cut in the ground plane along the right edge of the board.) naturally the topic gets even more complex when you add in ESD protection. some folks mentioned adding a "bleeder" resistor in parallel with the coupling capacitor. i'm leery of adding series impedance to limit the current, typically you want that ESD out of there without giving it opportunities to current share with sensitive signal returns. also it turns out that many resistors can get destroyed by an ESD pulse, so there's another good reason to avoid this approach. you might be OK if you add a shield ground ring around the board, near any gaps in your enclosure, so that ESD strikes will hit that rather than your main board ground. you should also protect any buttons or switches. for example, some tact switches come with a shield ground ring that goes to a 5th pin, which should be tied to your shield ground. earlier i said that the tl;dr for hobbyists is to just tie the shield to your board ground. for professionals who aren't experts in EMI but work for big companies who have EMI folks on staff, you might just want to add a generic "series component" between the two grounds and populate it with a 0 ohm jumper. the EMI people (during precompliance testing) may need to play around with that connection, and this makes it easy. @tubetime @tubetime Ooooh, that's what these lines on PCBs are for. Makes sense. @tubetime I honestly think this is ill-advised, because it makes the very signal lines whose signal we did this whole connection for cross reference levels and hence become noisy at the receiver. That's not really an option for single- ended signals, and the differential ones you would encounter today would be very unhappy about the break in impedance and the complete loss of current return path (much more energy in the E-field between diff traces and their joint adjacent ground plane than … @funkylab yeah the book advises building a ground "bridge" directly underneath high speed traces that cross over. they have high frequency return currents that take the path of least inductance (directly underneath) and if you have a ground cut underneath then the loop area increases, and you start radiating... @tubetime @funkylab I think you’re right. Just remember that “low frequency” that does cross the ground plane better have very slow rise/fall times. I could not find the >1GHz EMI that was radiating from my board. Long story short, it was a 32kHz oscillator with a 800fs rise/fall time. In the oscillator manufacturers defense, the datasheet only had a maximum rise time spec. But who would have thought the edges would be that sharp! @MarkAtMicrochip @funkylab you can sorta cheat a bit with high slew rate signals if they have a very long period and if you quasipeak during the EMI scan, but yeah usually high slew rate signals are a problem. @tubetime Signals crossing a split plane in that example are firing all kind of alarms in my brain. Even if the signal is low freq, rise/fall times in todays electronics can cause EMI problems. @tubetime Does it ever make sense to add a ferrite bead to 50 ohm coax? For context: I'm a ham. @profoundlynerdy sure, if you're having trouble with common mode noise currents going between equipment. i've had to do it before. it's tough to do it right because usually the RF noise finds another path. @tubetime 1Meg||some capacitor. Do not directly connect it to ground as some USB devices use the shield as a separate conductor for low speed signals. @tubetime A 1M resistor in parallel with a 100n capacitor. I want to avoid any large DC current, but I don't want it to build a charge either hence the 1M resistor. I also want any noise to be shunted to gnd hence the 100n cap (and the value is because I almost certainly have 100n caps already in BOM). @tubetime 1M is what's in ESD wristwrap, so seemed appropriate to just avoid charge buildup. 100n ... honestly just because I have those on most boards anyway. And 30kohm at 50 Hz seemed good enough to avoid hums. I'm pretty sure I copied that kind of topology from some example somewhere but it's been so long I couldn't give a source. @tubetime Directly to the ground plane. I've never failed EMC/ESD with that. Inductor is the worst option, I've fixed a few EMC fails where folks did that. Essentially an HF open. I want to keep the signals going through the cable in the cable which requires an HF short. Open makes an antenna driven my any common mode current in the other wires. Capacitor or cap || resistor has a use in breaking low frequency ground loops, keeping extraneous DC currents out of the braid. Not relevant for USB. @tubetime All the EMC people I talked to said directly to GND. And it's now even mentioned in the USB-C spec. And @jacqueline passed EMC with it so another great data point. |
@tubetime oh here we go 🍿