Have you probed your Dell Latitude USB port with a scope probe? - Page 1
Forum section: electronics / projects

author: willd1971
author_rank: Regular Contributor
timestamp: February 18, 2012, 10:39:33 am
content: Hi Guys,Not sure if this is the best place for this discussion...I came across an interesting USB problem at work this week - need help to solve!!!!We have developed a piece of measurement equipment which acts as a USB peripheral device. The equipment includes a laser diode and off the shelf laser diode driver (PLD500). There's also a bunch of customised hardware for system control, sequencing, data acquisition, and communications. The peripheral device is self powered from an isolated 12V bench supply, we don't draw anything from USB.Using a Dell Latitude D610 or D820 we have a common issue, plugging and unplugging USB sends a large transient through the peripheral device which has a damaging effect on the laser diode despite the PLD500 being designed to protect against this kind of thing. Using an IBM Lenovo laptop does not cause a transient. Interestingly using a USB isolator based on AMuD4160 does not help the situation.We probed the Dell USB port when there is nothing connected and found 95V RMS with a multimeter and an oscilloscope showed around 280V pk-pk 50Hz. The AC component discharged as soon as it was grounded or touched with fingers. However, when connected to a floating system like our perhipheral device it tended to make everything float in the same way. We tried this on 3 Dell laptops, all the same, the IBM laptop had no such issue.During the above, the Dell was connected to the mains through its standard power brick (different power bricks for each laptop). When running on batteries there was no AC component on the USB port and there were no damaging transients.So here's the question, what's going on and how do I protect my sensitive USB peripheral regardless of what it's connected to?Any feedback gladly welcomed. Transients not welcome!Williamwww.labtronix.co.uk

author: jahonen
author_rank: Super Contributor
timestamp: February 18, 2012, 10:55:33 am
content: It is probably the leakage current which comes from AC-adaptor Y-capacitor which kills the laser diode via common mode transient. Isn't the Dell laptop ground connected to mains earth when it is plugged via it's AC adaptor?Is any point of laser diode connected to mains earth or to some big metallic object? If it is, then only way where this common mode leakage current may flow is via laser diode, killing it in process.Regards,Janne

author: amyk
author_rank: Super Contributor
timestamp: February 18, 2012, 11:17:37 am
content: Does the AC adapter have a grounded plug?

author: IanJ
author_rank: Unknown
timestamp: February 18, 2012, 12:23:21 pm
content: I have a Dell laptop in use them in my workshop/shed and powered via it's brick.Now, my workbench has several of those green cutting matts nailed down onto the wooden bench........and I notice if I have my hands on the keyboard/mouse pad and my forearms on the green matts then whenever my arm touches the head of any of the nails I get a tingle.Ian.

author: Unknown
author_rank: Unknown
timestamp: February 18, 2012, 12:46:21 pm
content: So does it have a grounded plug? Do you have it connected to a grounded socket? I share Janne's analysis that it's most likely leakage through the mains filter. Equipment with a ground connection should only be connected to grounded sockets. If it's a double isolated power supply, than it's just badly designed if it gives a tingling sensation. In the case of Ian, it may also be that it's your workbench that's at a high potential due to leakage from something else.

author: Rufus
author_rank: Super Contributor
timestamp: February 18, 2012, 03:03:02 pm
content: Yes it is leakage from mains to dc output of the laptop supply brick. Sadly it is quite common to see tens of volts ac on laptop power brick outputs with respect to earth measured with a multimeter. A small capacitor across the isolation of a flyback converter transformer is one way to reduce EMI and produces this leakage path.Piss poor when you plug your USB debugging tool into an earthed target board and in a dark room can see small sparks.I bought a Dell XPS17 recently and pleasingly it came with an earthed brick, I measure about 1k ohm from the dc output to mains earth.That said if you are killing laser diodes plugging in a USB connection you have a system problem that needs fixing. Laser diodes can be extremely fragile.

author: willd1971
author_rank: Regular Contributor
timestamp: February 18, 2012, 03:43:06 pm
content: Thanks for replies so far. The D820 does have an earthed brick the D610s have no earth connection - in both cases the output measures open circuit wrt earth and mains input, so I would say the laptops are running isolated supplies. I've worked in different locations - wooden benches and currently an isolated metal optics bench. The peripheral USB device is enclosed in a large plastic Peli case, the inside is lined with a complete adhesive aluminium foil which itself is currently earthed, the system ground is isolated from earth but can be connected to earth at the bench supply with no problems. The USB screen was connected to system ground but I switched that over to earth quite early on.Any comments on how to effectively block the plugging transient from entering my USB peripheral? As I said in the opening message the AD isolator didn't appear to help. Worth stating that the AC mains component appears on all conductors coming out of the laptop. What about transorbs to earth on the USB input - only trouble is the eventual application location may not be able to provide an earth? EMC advice sought!!!!RegardsWilliamwww.labtronix.co.uk

author: Unknown
author_rank: Unknown
timestamp: February 18, 2012, 03:52:24 pm
content: Quote from: willd1971 on February 18, 2012, 03:43:06 pmIf it's a common mode problem, then it shouldn't be an issue for an isolated device, should it? You can use chokes and caps to filter common mode signals, but they are probably going to be extremely big to block 50 Hz. They are typically used to block high frequencies.I'm by no means an EMC wiz, but in my opinion you should make up your mind: either design it as an earthed appliance and require an earth connection, or design it to be isolated from ground and don't provide an earth connection at all. In the isolated case, connect the shield to USB ground, and you shouldn't have an issue with the common mode voltage, just like the laptops.

author: IanB
author_rank: Super Contributor
timestamp: February 18, 2012, 05:19:24 pm
content: On a related note, my iPhone and USB charger cable both make non-contact voltage detectors beep like a merry party when the charger is plugged in. It happens the same way whichever way round I plug the two pin charger into the mains socket. It looks like high voltage leakage on low voltage switched mode supplies can happen in all sorts of places.

author: firewalker
author_rank: Super Contributor
timestamp: February 18, 2012, 05:33:05 pm
content: Test you P.S.U. I had similar problems in a project.

author: Unknown
author_rank: Unknown
timestamp: February 18, 2012, 06:50:34 pm
content: Someone from the AVRfreaks forum did some similar measurements on double isolated SMPSs:http://www.aplomb.nl/SMPS_leakage/Doc_ie.html

author: ejeffrey
author_rank: Super Contributor
timestamp: February 18, 2012, 06:57:30 pm
content: Quote from: willd1971 on February 18, 2012, 03:43:06 pmBy the way, optical tables (as with all other permanently installed large metal objects) should generally be permanently earthed.I think your best bet is to make sure that USB 'ground' contacts your circuit ground before USB5V. If the 5V power contact, which has 230 VAC at high impedance imposed on it due to the capacitive coupling across the power supply makes contact with your circuit, that current will flow to ground through your circuit. Even if your circuit is floating, you will have to charge up its self-capacitance, which can be 10s of picofarad. The sudden discharge can be enough to blow out your laser diode, especially if the voltage is negative at the time. If the ground contact is made first, the current shouldn't flow through the diode.The brute force way to do this is to put a small reed relay with a 5V coil power line with a delayed-on circuit so the relay only closes after both 5V and ground have been present for ~200 ms. It is also common to have a normally closed relay *and* a MOSFET shorting out the laser diode. The relay protects the diode when the circuit is not powered. When powered, the MOSFET is turned on, then the relay contacts are opened. The mosfet protects against any transient from the relay contacts. Then the circuit turns off the mosfet so that it can drive the diode.It is almost impossible to design a surge suppressor that is fast enough to protect a laser diode. Most diodes are just too slow to clamp the type of spikes that can damage a laser diode. One thing you can do is put a shottky diode anti-parallel with your laser (as close as possible to the laser diode itself). That will clamp negative spikes fairly effectively.

author: Unknown
author_rank: Unknown
timestamp: February 18, 2012, 07:20:46 pm
content: Quote from: ejeffrey on February 18, 2012, 06:57:30 pmAgreed.Quote from: ejeffrey on February 18, 2012, 06:57:30 pmDoesn't the USB connector take care of this? The shell should make contact first, then the power pins, and then the data pins. Though the delay probably won't be 200 ms.

author: ivan747
author_rank: Super Contributor
timestamp: February 18, 2012, 07:54:17 pm
content: Quote from: IanJ on February 18, 2012, 12:23:21 pmI can confirm the same thing happens with a Macbook Pro, early 2010, when touching the wall and the aluminum surface. The tingle only happens when it starts charging (there's a ~1 second delay between connecting the plug and when the computer starts charging).Update: my multimeter (which is not true RMS) is measuring 50V, spot on, from the USB connector's shield to ground. This is interesting. I'll hook up the oscilloscope.My oscilloscope shows a noisy sine wave at 9V RMS. It has 1M? input impedance, vs. 10M? input impedance on the multimeter.

author: Rufus
author_rank: Super Contributor
timestamp: February 18, 2012, 08:34:16 pm
content: Quote from: willd1971 on February 18, 2012, 03:43:06 pmThe PSU has a small capacitor between the output ground and the mains input. Not sure what typical values are, from the photo in the AVRfreaks forum link someone gave it looks like 2200pF.When you plug in the USB connector you are shorting one end of that capacitor to your ground and the other end is at what ever part of the mains cycle you are on. It isn't much different to an ESD zap, probably milder and if it is damaging or upsetting your equipment you have a system problem which needs fixing.

author: SeanB
author_rank: Super Contributor
timestamp: February 19, 2012, 12:13:48 pm
content: The laptop PSU will not be connected to the earth pin ( even if it has a 3 pin cord that is correctly connected, the pin inside the case will either not be connected or will only go to 2 class Y input filter caps) and the secondary is connected via a small value capacitor ( 2200pf in many cases, but varies, and may be 2 in series or a class Y or a no name brand blue blob) to the negative of the reservoir capacitor. This makes the whole laptop float at the mains frequency between +-300V. The only way to stop this is to ground the internal case, either by plugging in an external monitor ( which will invariably have the VGA/DVI cable shield connected to mains earth) or by adding an external earth bond, easiest by using a blank 15 pin VGA male connector and connecting a grounded cable to the shell only. Place this in the VGA socket on the laptop before power on, and preferably use the screws.Another option is to use an isolated USB interface, and ensure the interface is laid out so as to have a totally isolated ( including USB cable shield) portion of the case and board. Connect cable shield to nothing on the board, and the computer side will only be powered when plugged in. If you need power connect events on the non computer side and the particular design does not do it well then add a high creep opto and a current limiter to the USB power and use the output of the opto transistor to do it.

author: willd1971
author_rank: Regular Contributor
timestamp: February 19, 2012, 08:56:29 pm
content: Thanks, there are some useful comments here. I should point out that the original issue of laser diode damage only arises when the USB connector is mechanically cycled while the laser diode is enabled, when the laser diode is disabled the usual crowbar is in place to protect it.Also, the nasty transient is generated regardless of whether or not the peripheral device is earthed or floating. As someone previously stated it's probably self capacitance in the isolated condition.I will try a fast shottky up by the pins of the laser diode - I had considered this previously but don't want to overheat the laser diode during soldering.USB isolation interests me - we tried it already without success. We found that an onboard dc dc converter providing down stream power still allowed a certain amount of the AC component through (~45VAC). We removed the dc dc converter, powered the interface ic from peripheral power, and found the downstream conductors to be clean. But still, plugging the host side caused transients - not necessarily enough to immediately wreck the laser diode but surely a degradation. My current thought is to earth the USB isolator on its upstream shield so that when the laptop is plugged in and the shields make contact before anything else, hopefully the AC component will decay away to earth without ever passing through my laser diode... My concern is that there may be a significant radiated transient when any conductor is contacted with the Dell USB port, and perhaps this is my remaining mode of susceptibility.I'll be in the lab again first thing in the morning and will feedback anything interesting!Williamwww.labtronix.co.uk

author: ejeffrey
author_rank: Super Contributor
timestamp: February 19, 2012, 10:43:02 pm
content: Yeah, you have to be careful with soldering. If you can use a socket that makes it easier.QuoteSurges aside, this is trouble. When a circuit with feedback loops powers up it takes some time to stabilize. Unless you take exceptional care there is a possibility for out-of-range excursions. You should try to make sure that the diode is shorted out until the circuit powers up and before the power supply caps are drained.

author: willd1971
author_rank: Regular Contributor
timestamp: February 21, 2012, 08:58:45 pm
content: So, a couple of days fiddling in the lab has seen some progress. We settled on a USB-ISO module from olimex.com but did 'edit' it a bit. It's an isolator based on the AMuD4160 inductive isolator designed for USB applications. The module includes a small capacitance from the host screen to host ground and a small inductance from peripheral ground to peripheral screen. We removed these links to the circuit to maximise our isolation. The module also includes a dc dc isolator to provide peripheral-side power for the AMuD4160, and the peripheral device too (although not in my application). We found a lot of the original mains ripple from the Dell host was coupled through this isolator (measured 45V pk-pk on the peripheral side), so it was removed and peripheral-side power was provided from the peripheral itself. Now on testing we found an in-line arrangement outside the screened box of the peripheral device electronics works flawlessly for us, we measured no mains ripple on the peripheral side, although a small transient can still be captured on the oscilloscope during plug contacting - even when the probe is not electrically connected to the system, but it's tiny in comparisson with what we had before. Not so good is placing the USB-ISO within the screened box - this does interfere with the peripheral device electronics - but that's not surprising given the horrible ripple on the USB host lead. We are sticking with an in-line solution outside the box for now, but ultimately a properly screened entry will allow the isolator to reside in the box. Thanks for suggestions and comments - problem is currently solvedWilliam

author: Rufus
author_rank: Super Contributor
timestamp: February 21, 2012, 10:04:13 pm
content: Quote from: willd1971 on February 21, 2012, 08:58:45 pmNo it isn't. Now you will only be damaging your diodes when someone wearing nylon pants walks up and touches it or when you get a mains transient.

author: willd1971
author_rank: Regular Contributor
timestamp: February 22, 2012, 06:57:03 am
content: Touches what? It's an enclosed system apart from the USB and Power interfaces - the USB interface is now effectively isolated and the power interface is regulated 12VDC, also mains isolated, there should be no rubbish coming through there. I'll perhaps try some local static discharges to verify the screen is effective before I put the LD back in though.William

author: scrat
author_rank: Frequent Contributor
timestamp: February 25, 2012, 02:33:10 am
content: I know this can be a stupid question, but this is an occasion of asking to experienced people.If it was a lower speed link (for example, RS-232 or 485), would it have been effective adding some series resistance on all of the wires (GND comprised), instead of isolating?Thanks.