Trouble finding source of reference oscillation - Page 1
Forum section: electronics / projects

author: bitbanger
author_rank: Regular Contributor
timestamp: March 24, 2018, 01:53:23 am
content: Hi Folks -Continuing to work on a little personal project - basically it consists of a switching regulator with three pre-set output voltages programmed via the adj pin. The levels are determined by two schmitt trigger stages. The comparators are configured for 100mV of hysteresis. This is where the voltage reference comes in, for the comparators.Even with the hysteresis I see oscillations at switching, and upon closer observation my reference seeeeems to be initiating the oscillation. Even if it isn't I don't understand why my reference is being affected by the oscillations. You'll note that (schematic below) for the hysteresis + feedback I'm injecting the feedback into the "sensed" terminal and not my fixed reference: this is semi intentional even if not the most "correct" so my comparator output doesn't need to be inverted.Anyway I'm going bonkers trying to find the source of this reference perturbation - it doesn't align with the switch of the regulator, or my bench DC supply...At first I thought perhaps the opamp bias currents could be somehow contributing to the reference - the reference currents were pretty agressively low because this is a battery powered application. So I increased my reference Iq to be 10x Iload. Also please ignore that it's drawn as a three-terminal device - for some reason that's how the "Vault" pulled it in. Anyway this didn't help.Perhaps important to note that the oscillations are not apparent directly at the output of the reference, rather at the Thr1 and Thr2 points.Any thoughts? these oscillations occur at very slow and rapid transitions through the reference points.PS - not shown but I have tried 1nF and 0.1uF caps across the reference output with no (discernible) change in amount of oscillation.As far as construction everything is mostly on a manufactured proto pcb. The comparative IC is flying leaded (smt) because I switched from a different IC (was open collector output)

author: bitbanger
author_rank: Regular Contributor
timestamp: March 24, 2018, 02:00:07 am
content: Generally for the scope traces (unless noted otherwise)CH1 (YEL) = VinCH2 (GRN) = ThresholdsCH3 (BLU) = Track (tracking ~1/10th Vin)CH4 (RED) = comparator outputThe below are oscillations from both directions.

author: bitbanger
author_rank: Regular Contributor
timestamp: March 24, 2018, 02:02:06 am
content: Zoom/panning to the beginning of the above oscillation capture

author: bitbanger
author_rank: Regular Contributor
timestamp: March 24, 2018, 02:04:31 am
content: Lastly (I wish we could upload and embed images without using a third party...that way I could compose inline more easily).CH1 is now the switching regulator switch terminal/output. I can't see any direct correlation.Thanks again for taking the time!Jamie

author: Tomorokoshi
author_rank: Super Contributor
timestamp: March 24, 2018, 02:41:44 am
content: The low impedance cmos-output comparator output into the 25 pF mosfet gate capacitance with only a 4.7 M resistor as the load seems like an impedance mismatch issue. Maybe try a series output resistor with termination near the gate of the transistor.In the datasheet for the comparator it specifies to use a decoupling capacitor. Is there one in the construction of the circuit?

author: bitbanger
author_rank: Regular Contributor
timestamp: March 24, 2018, 02:57:11 am
content: Hi - yes 0.1uF directly beneath.I suppose I took the feature section pretty liberally - (stating that it can directly drive capacitive loads.). Isnt a low impedance output best for fast switching of a capacitive load?Also these disturbances in the reference seem to appear before even switching.

author: Tomorokoshi
author_rank: Super Contributor
timestamp: March 24, 2018, 03:45:15 am
content: Is switching to that capacitance drawing enough current to dip the supply to the reference? Otherwise why is it showing all that noise? How is everything wired to Vin? At which component is Vin being connected to the oscilloscope?

author: bitbanger
author_rank: Regular Contributor
timestamp: March 24, 2018, 04:54:48 pm
content: If you're talking about the first capture with the Vin ripple - this ripply only showed up during oscillation, otherwise was smooth. In this case I was also directly powering/testing the comparator circuit alone (without the rest of the system in place) and so it was lacking some bulk supply capacitance.Vin is being probed less than 1/4" away from the reference input pin.

author: bitbanger
author_rank: Regular Contributor
timestamp: March 25, 2018, 08:56:25 pm
content: Today I used an external system PSU for the reference level (Thr1) - works perfectly. I feel like I have enough bulk capacitance near the input of the reference. The dip in Vin looks alarming below, but remember that my oscillations (above) were occuring before this momentary sag. ??Also the disturbances above in the reference input directly track the output of the comparator (even though the feedback is tied into the other terminal). Perhaps my comp input impedance is too high, so when internal opamp bias currents are moving (for lack of better explanation) this input current change is appearing as voltage change at the input terminals? Odd because the + feedback is more drastically influencing the - input (reference).

author: bson
author_rank: Unknown
timestamp: March 25, 2018, 09:52:02 pm
content: 10ohm is not enough to dampen the gate charging. Just looking at the datasheets, an input capacitance of 22pF on a 2N7002, with 10ohm and zero source impedance, and given a 3.3V rail you'd be looking at a rise time of 1.1ns from 10mV to 1.8V. Peak current would be 320mA at the beginning of the switch - which clearly the TLC3702 can't supply. The TLC3702 has an absolute maximum output current of +/-22mA. This means you need a much bigger inline damping resistor than 10ohm; a ballpark figure of 220ohm would be a better choice, yielding a rise time of 25.1ns and a peak current of ~15mA for the nominal specs, but the easiest way to find a good value is empirically - just see what works well, and in your case give it a little extra to keep things nice and quiet in face of individual unit variation (unless it's a one-off).

author: bitbanger
author_rank: Regular Contributor
timestamp: March 26, 2018, 12:03:30 am
content: Good feedback (pun intended) thanks - I had already increased it five fold to 50ohms but you're right, I likely need to increase it more. I think this would help the sag at switching (rapidly) but unfortunately I don't think it's going to help with the oscillations (that begin to appear seemingly out of nowhere). That said to be fair any output capacitance could be a contributor to the continued oscillations, and so I had actually added it more to isolate the feedback from the gate capacitance ("out of the loop"). I think this effectively introduces a zero.Anyway I'll poke at it some more here this evening.Cheers,Jamie

author: bitbanger
author_rank: Regular Contributor
timestamp: March 26, 2018, 01:20:15 am
content: Yeah so it looks like the sag at switching is actually (my guess) lack of input capacitance (or too high ESR) at my switcher input. Below captures are with 240ohm series gate resistors - nearly identical to Vin above. Second capture is other direction (ignore trace labels: CH3 is Vout, Ch2 is switcher here). Both were with the PSU still serving as Vthr1.I wanted to see if this affected the original reference so I put the original reference/Vthr back into place. Starting to wonder if my instability is temperature or layout induced - I've been moving the board back and forth to my soldering station, sometimes moving the fixed jumper wires between the main board and the comparator board to get my iron in. Becayse now one direction the switch has about the same oscillation time, but the other direction is constant oscillation until I continue increasing Vin.

author: bitbanger
author_rank: Regular Contributor
timestamp: April 02, 2018, 11:57:21 pm
content: So to circle back - it doesn't appear it's neccessarily the reference itself - I put my system power supply in place of the 2.5V ref (vs the 0.639V input to comparator) and I get the same amount of oscillations. So this must be input impedance into the opamp, or stray capacitance causing lag at the output? The wiring is a bit how-you-doing but I'd hate to respin (even if it's just a proto board) without a little more consideration. Any thoughts?Thanks!