Author Topic: Voltage spikes around switching boost converter & questions about oscilloscopes  (Read 3130 times)

0 Members and 1 Guest are viewing this topic.

Offline MrFloofingtonTopic starter

  • Newbie
  • Posts: 2
  • Country: fi
Hello, I'm very much a beginner with electronics and I just got an oscilloscope so I have a few (probably quite dumb) questions...

I've built a 12vdc to 200vdc boost circuit designed for driving nixie tubes using this diagram
.
I built it on perfboard using this layout
.
Now when I probe the output of it under load I get this:



Which is mostly what I would expect except for those short >10v spikes every time at the start of a boost cycle. And I've measured if before with no load attached and the spikes could reach 30v.
Then I measured the timing pin on the mc34063 chip and at first it looked like it was at 12v and I was like wtf is going on but zooming in further reveals a normal looking clock line but with short spikes similiar to those on the output:
.

1st question: What is causing the spikes, are they real? Or is the scope just picking up interference from the switching and I can safely ignore the spikes and maybe set a BW limit to not see them?
Or are the spikes caused by my crappy perf board layout or something like that?

2nd question: When I was playing around with the scopes coupling modes, there were one or two instances where I switched to AC coupling but the signal looked like it was still stuck in the DC mode. Switching around the modes and selecting AC again fixed it, but I'm wondering if its a sign I'm doing something terribly wrong or is it a bug with the scope?

3rd question... after doing the measurements and playing around I got kind of paranoid about the safety of probing this circuit with the scope. I've previously watched Dave's video on "How to not blow up your oscilloscope" and it left me with the idea that its generally safe to probe around if your D.U.T is connected to the wall with an adapter that does not use an earth pin. And to power the 200v booster I used a random $2 230vac to 12v DC power brick from ebay (uses only 2 prongs to connect to wall, no earth pin)  But then I thought that I read somewhere that the mains earth is just connected to neutral (or that it can be). So out of curiosity I tested the resistance between the 12V dc output terminals and the mains earth and I got readings of about 1M ohms... I also tested with a DMM how much current can flow from the power bricks DC output to mains earth and I got like 4milliamps... when I tested voltage it spiked to a few volts on first contact but then went down to few millivolts.
So the "non earthed" power bricks DC output is somehow connected to mains earth? So... is it safe to to probe around devices powered by this and connecting the scope probes earth clip to anywhere? even though it looks like some current could flow and there might be a voltage difference?

Last question: on the scope near the BNC inputs it says "Max 400v pk". I know there are many threads about ppl asking about the max voltage input to scopes and I've read them but its still not 100% clear to me with using 10X probes.
I've seen people say that the 10X probe will just divide the voltage seen by the scope by 10, so in my case by that logic I should theoretically be able to probe a 4000v (4kv) signal with a 10X probe? Is this correct? I know the normal probes are only rated to like 300v on 10X modes, but I'm talking theoretically, if the probe could handle it.
I've also seen some people saying that you should never probe a voltage higher than the max voltage of the scope, even with a 10X probe, because the "AC coupling capacitor will charge to the original voltage" and blow up your scope regardless of the 10X probe. Or at least something along those lines. So what is the correct answer?
« Last Edit: February 06, 2018, 12:13:04 am by MrFloofington »
 

Online T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 21658
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Simulating it in my head depends on what the 34063 does, but supposing it turns off in about 200ns, Q1 will have a drain rise-time around ballpark 100ns.  During turn-off, drain voltage swings up rapidly, until the output diode conducts.  At that moment, all the inductor current was flowing through the transistor (the transistor was trying to turn off, but its current doesn't fall to zero at the moment Vgs falls: the current continues flowing due to Miller effect and/or Coss).  After, the inductor current goes into the diode and output capacitor.

So, we should expect to see the output waveform having more or less the response to a step change in current.  Voltage rises, hits the diode, current jumps up (in, on the order of maybe 50ns?), and stuff happens.

What happens?  We need an equivalent circuit of the output filter.  Presumably, this is just the capacitor.  Which you've got a good one, if that's just an electrolytic -- relatively high ESR.  The layout also has a long path between capacitor, diode and transistor: about an inch, about 20nH worth of inductance.

The inductor responds to changes in current.  The equation of inductance is: V = L * dI/dt.  If current is ramping at (1A) / (50ns), and L is 20nH, the overshoot is 0.4V.

The ESR responds to current.  The equation is: V = I * R.  If current is 1A peak, and ESR is -- ballpark let's say 5 ohms -- then the overshoot is 5V.

ESR probably dominates here.  To reduce overshoot, try a film capacitor instead (very low ESR).  You'll always have some left, even if you measure the output directly across the capacitor (least stray inductance in your measurement).  To deal with it faster, you can add an LC filter.

Regarding probes, the probe itself has a voltage limit (usually not far from 400V as well).  Which is only 40V at the scope, so you don't have to worry about using it within that range.

HTH,
Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 
The following users thanked this post: MrFloofington

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16607
  • Country: us
  • DavidH
Which is mostly what I would expect except for those short >10v spikes every time at the start of a boost cycle.

That noise level seems excessive to me even for a 200 volt output.

Quote
1st question: What is causing the spikes, are they real? Or is the scope just picking up interference from the switching and I can safely ignore the spikes and maybe set a BW limit to not see them?
Or are the spikes caused by my crappy perf board layout or something like that?

As a sanity check, probe the same point you are using for the ground lead on your probe.  This will show the limits of your measurement and whether common mode noise from a ground loop or pickup from the loop area of the ground attachment is a problem.

You may need a coaxial connection to the probe tip without the ground lead to make reliable measurements.

Quote
2nd question: When I was playing around with the scopes coupling modes, there were one or two instances where I switched to AC coupling but the signal looked like it was still stuck in the DC mode. Switching around the modes and selecting AC again fixed it, but I'm wondering if its a sign I'm doing something terribly wrong or is it a bug with the scope?

I think that is a bug in the oscilloscope.

Quote
3rd question... after doing the measurements and playing around I got kind of paranoid about the safety of probing this circuit with the scope. I've previously watched Dave's video on "How to not blow up your oscilloscope" and it left me with the idea that its generally safe to probe around if your D.U.T is connected to the wall with an adapter that does not use an earth pin.

It is safe unless the power adapter is faulty.

Quote
And to power the 200v booster I used a random $2 230vac to 12v DC power brick from ebay (uses only 2 prongs to connect to wall, no earth pin)  But then I thought that I read somewhere that the mains earth is just connected to neutral (or that it can be). So out of curiosity I tested the resistance between the 12V dc output terminals and the mains earth and I got readings of about 1M ohms... I also tested with a DMM how much current can flow from the power bricks DC output to mains earth and I got like 4milliamps... when I tested voltage it spiked to a few volts on first contact but then went down to few millivolts.
So the "non earthed" power bricks DC output is somehow connected to mains earth? So... is it safe to to probe around devices powered by this and connecting the scope probes earth clip to anywhere? even though it looks like some current could flow and there might be a voltage difference?

The high frequency noise from the power brick might be confusing your DMM.  The leakage should be much less than 4 milliamps.

Quote
Last question: on the scope near the BNC inputs it says "Max 400v pk". I know there are many threads about ppl asking about the max voltage input to scopes and I've read them but its still not 100% clear to me with using 10X probes.

I've seen people say that the 10X probe will just divide the voltage seen by the scope by 10, so in my case by that logic I should theoretically be able to probe a 4000v (4kv) signal with a 10X probe? Is this correct? I know the normal probes are only rated to like 300v on 10X modes, but I'm talking theoretically, if the probe could handle it.
I've also seen some people saying that you should never probe a voltage higher than the max voltage of the scope, even with a 10X probe, because the "AC coupling capacitor will charge to the original voltage" and blow up your scope regardless of the 10X probe. Or at least something along those lines. So what is the correct answer?

The last is almost always correct.  Standard 10x probes do not attenuate the DC level when AC input coupling is used.  Most 100x probes do not either.  So in both of these cases, DC coupling *must* be used to extend the input voltage rating of the oscilloscope for DC signals and using AC coupling to measure just the AC component risks damage if the average DC voltage is greater than the oscilloscope's peak input voltage no matter what the probe's attenuation is.

1000x probes, better 100x probes, and some vary rare 10x probes do not have this limitation.  They can be identified by having an input resistance which is lower than their attenuation factor would produce.
 
The following users thanked this post: MrFloofington

Offline danadak

  • Super Contributor
  • ***
  • Posts: 1875
  • Country: us
  • Reactor Operator SSN-583, Retired EE
This might be useful -


http://web.mit.edu/6.101/www/reference/ABCprobes_s.pdf


Note the probes V rating determines your safe HV measurement capability, not the attenuation
factor of the probe.


Regards, Dana.
Love Cypress PSOC, ATTiny, Bit Slice, OpAmps, Oscilloscopes, and Analog Gurus like Pease, Miller, Widlar, Dobkin, obsessed with being an engineer
 
The following users thanked this post: MrFloofington

Offline MrFloofingtonTopic starter

  • Newbie
  • Posts: 2
  • Country: fi
Thank you for the great answers guys!

ESR probably dominates here.  To reduce overshoot, try a film capacitor instead (very low ESR).  You'll always have some left, even if you measure the output directly across the capacitor (least stray inductance in your measurement).  To deal with it faster, you can add an LC filter.

I just tried messing around with output cap ESR in my ltspice simulation and indeed managed to create similiar spikes. I had previously used a ~0ohm capacitor in my simulation which is clearly not representative of the random electrolytic I stuck on the output  ;D
I'll try messing around with different types of caps and maybe a filter.. Though I'm still wondering why I'm also getting similiar spikes on the 34063's timing capacitor, I want to look at the spikes again and try what David Hess suggested in the other reply to check for noise but now I'm scared of hooking up my scope again because:

Quote
And to power the 200v booster I used a random $2 230vac to 12v DC power brick from ebay (uses only 2 prongs to connect to wall, no earth pin)  But then I thought that I read somewhere that the mains earth is just connected to neutral (or that it can be). So out of curiosity I tested the resistance between the 12V dc output terminals and the mains earth and I got readings of about 1M ohms... I also tested with a DMM how much current can flow from the power bricks DC output to mains earth and I got like 4milliamps... when I tested voltage it spiked to a few volts on first contact but then went down to few millivolts.
So the "non earthed" power bricks DC output is somehow connected to mains earth? So... is it safe to to probe around devices powered by this and connecting the scope probes earth clip to anywhere? even though it looks like some current could flow and there might be a voltage difference?

The high frequency noise from the power brick might be confusing your DMM.  The leakage should be much less than 4 milliamps.

I just remembered that when I was probing the power brick output and mains earth I had my DMM in DC mode...
I tried again in AC mode and I got >90V between the dc output negative connection and earth!!! Thats where I've been sticking my oscilloscope ground clip to :scared:
Havent tried measuring current in AC mode cus I'm scared of blowing up something.. Though I didn't get any sparks or explosions with the scopes ground clip...
Whats going on? Is the DMM just confused? Would that voltage drop to 0 if it was actually connected to earth with a small leakage current? Btw my DMM is a "true RMS" aneng an8008

EDIT: I just tested the current this time with the multimeter probes in the correct holes (last time when I got that 4mA reading I had the probes in the slot for microamps only  :palm:) and I got 0 mA in both DC and AC modes.
So it looks like I've been worrying over nothing as it seems no real power can flow to earth out of the dc adapter. ::) I still don't know whats up with that 90v voltage difference, but if no current can flow then I guess it means nothing.
« Last Edit: February 06, 2018, 09:32:02 pm by MrFloofington »
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16607
  • Country: us
  • DavidH
I still don't know whats up with that 90v voltage difference, but if no current can flow then I guess it means nothing.

Capacitive coupling across the isolation barrier allows a significant voltage across the multimeter's roughly 10 megohm input resistance and 100pF of capacitance.
 
The following users thanked this post: MrFloofington


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf