Electronics > Projects, Designs, and Technical Stuff

EMF pickup from amplifier in I2C line causing glitches. (Now with scope trace!)

<< < (18/31) > >>

dmills:
3dB is generally figured to be at the lower end of the scale for a perceived volume change, with around 10dB (This is frequency dependent) being generally figured to be roughly a perceptual doubling in volume, there is a reason concert sound systems get so stupidly large.....

Regards, Dan.

T3sl4co1l:
Simulators are first and foremost, numerical solvers.  They only represent reality to the extent that you, the modeler, have created a model that will produce realistic numerical results.

Ground is absolute, so you have to add a GND symbol (net 0) somewhere.  Preferably on a common net, so all your voltage measurements are relative to it, without having to connect a pair of wires to read the difference.  (In SPICE, there IS such a thing as absolute voltage -- 0 is global ground.  In reality, you always need two wires.)

There are two kinds of components, for example: SPICE standard R, L, C are pure abstract components.  On the other hand, real components, can be modeled as an infinite network of abstract RLC parts!

How far into that network you go, determines how good (accurate over a given frequency range or time scale) your model will be.

The analyses you will be most interested in, are Transient (the "play" button, or select it from the menu), and AC Steady State.

To use Transient, use pulse signal voltage sources to represent your amplifier's switching output.  The rise and fall times will be short, 10ns perhaps.  You specify the pulse width (say 0.5us) and period (say 1us, thus giving about 50% duty at 1MHz -- representative enough), and the voltages when 'on' and 'off'.  You can also assign an AC Magnitude, which does nothing in Transient.

To use AC Steady State, at least one voltage source has to have an AC Magnitude and Phase assigned (otherwise, they default to zero).  This performs an AC frequency sweep, using the assumption that the circuit's DC operating point is linear.  (This won't matter, because your network is linear.  It does matter for nonlinear circuits, like amplifiers, where the DC condition varies with signal level.)  On the sim dialog, enter a range of frequencies, usually a fair amount below and above the cutoff frequency (say, 10k to 100M).  You'll want a decade plot with 200-500 points/dec.  Go to the "Output" tab and pick a few circuit nodes to plot.  (If you haven't named the circuit nodes, they will have default numberings.  Hit OK on the dialog and double-click a wire to see what name it has, and set a user-defined name if you like.)

Once you've picked the outputs, press the Simulate button.  The graph view will open, and you should see something resembling a lowpass filter.

Note that, since the SPICE components are ideal, your filter will also be ideal.  Adding ESR to inductors and capacitors is a good first step.  Inductors also have EPR (i.e., a modest sized resistor in parallel) and C, and capacitors have ESL also.  A real filter will have many humps and valleys at high frequencies (because real components are complicated); in the simulator, you only get as many humps and valleys as you have reactive (L or C) components.

You can also determine power dissipation.  If you do a Transient simulation (from the menu), you can pick outputs.  If you write an expression for power (such as VSRC[ i] * V(VSRC), the power generated by a source VSRC), you will get a plot of that.  You can do this for sources and loads, and subtract to find the difference: losses.

Tim

SteveyG:

--- Quote from: Starlord on July 06, 2016, 12:15:19 am ---Ive never used LTSpice before, but I installed it and it looked old and shitty, so I tried setting up a circuit in Digikey's PartSim which I had working in five minutes and graphed the output, but I'm not sure the output I'm seeing is accurate and their parts don't provide many parameters to adjust, so I guess both tools have their serious flaws.  I went back to LTSpice and am now trying to set up a simulation, hoping it actually has a graph and noise function like Partsim so I can see a graph of the falloff, but god this software sucks.   I mean they got nothing at all right about the interface.  Mouse zoom is reversed, and if you point somewhere and zoom in it doesn't zoom into that point, it also works in a mirrored fashion from how it works in Eagle and every other cad package out there.  And when I move a component, the wires become detached, or maybe they were never attached in the first place.  It's a mystery!  How exciting. :(  Oh, and how could I forget that you have to cut to delete, you can't just point and press delete, and for some reason to rotate you have to press CTRL-R instead of just R or simply right clicking while you're dragging the object.  Ugh.  Annnd, I can't find any noise function on the voltage source.  I'm betting this software has no ability to graph the output either.

Tell me again why people recommend this tool so much?  There's gotta be something more modern out there.  This looks like a Windows 3.1 application.  I have literally used simulators written in Javascript that function better than this.  And that even showed the flow of electrons in the circuit in real time.

--- End quote ---

LTspice is very powerful and isn't difficult to use - electronic simulation tools don't need to show electron flow or run in Javascript to do their job. Do you know how to use SPICE?

Starlord:

--- Quote from: SteveyG on July 08, 2016, 10:26:50 am ---LTspice is very powerful and isn't difficult to use - electronic simulation tools don't need to show electron flow or run in Javascript to do their job. Do you know how to use SPICE?

--- End quote ---

Well I'm sure once you learn it's quirks, you can use it, but I think it's fair to say it's design is antiquated and unintuitive.

And sure, you don't need to see electron flow, but I just mentioned it because when I was learning how to design filters with resistors and capacitors long ago, being able to see what was actually going on with the electrons in real time made it so much clearer to me what the capacitors were doing.  For a beginner, it's a godsend.

Anyway, I got Multisim Blue from Mouser and I found an audiophile site which actually had a simulation model for a class D amplifier output filter, and from there I was able to simulate different values of inductors and capacitors and see how they affected the output.  I'm still not sure how those peaks after the flat region affect the current draw of the amp, but since someone here knew something about that and suggested a certain set of values and said the current use was related to that peak, as long as my peak is less than or equal to the one his suggested values give, I think I'm safe.

I finally settled on a 2.2uF inductor and .1uF cap, because it kept that peak low, but increased the attenuation of frequencies above 1MHz by a great deal more.  And after looking for hours at different inductors, sorting by price and size and quantity available and DC resistance and current handling capacity...  It suddenly occurred to me that I already had a tiny 2.2uF cap on my 5V switching regulator, and when I looked at the specs, it matched up precisely with my needs for the amp.  So it turns out I don't need to add yet another component to my BOM which is nice, given this whole thing is already too expensive.  But they're still gonna be $1 apiece with the placement costs, so, sad face. 

But back on the subject of Multisim... I like it a lot.  Reasonably modern interface, and works exactly as you'd expect it to.  I have absolutely no idea what I'm doing, but at least I can copy and paste and delete and move and rotate components in a way that makes sense, as well as easily connect wires between them.  I don't know how much I'll need to use it for the simple mostly digital circuits I design, but I think it will be my go to sim tool from now on.

tggzzz:

--- Quote from: Starlord on July 05, 2016, 10:28:37 am ---If the FCC wants products to be tested, then the government, not the small business owner, should bear the brunt of those costs.

--- End quote ---

Don't be silly.

The reason for many regulations is to stop small businesses having to bear the brunt of the costs. The costs, that is, of being prevented from doing their  business because they are being stomped by interference from someone down the street.

Or maybe you would be happy to have you service disrupted by someone operating a spark-gap transmitter.

I've dealt with the FCC in terms of opening up and setting new types of standards w.r.t. radio interference. The FCC were eminently reasonable, provided we ensured that pre-existing users continued to be able to operate.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod