Warning: This post is not done and therefore not yet worth reading. I am posting it now for discussion.
I want to get back to testing the Wien Bridge Oscillator. So far, I have not gotten this to work with the Healthy EC Dev-Rev1. After searching for challenges others have had getting their setups to work, it appears the biggest challenge is in getting the Gain to start at slightly above 3. Once the oscillation starts, maintaining the gain at 3.
The goal of this post is to get the Wien Bridge Oscillator to work on the Healthy EC Dev-Rev1 or know the specifics of why it won’t work without changes to the PCB.
Thanks to Those That Went Before
Some things should be thanked for every time. This is the case with Chris Gammell. If it wasn’t for his Contextual Electronics course and guidance, I would not be passionately enjoying this incredible learning experience. I recently listened to a podcast where they noted in 1984 there was a significant drop in women who majored in computer science in the US. One woman interviewed noted she felt exceptionally strong in math and had confidence going into her freshman year at college – a hopeful computer science major. She remembers the day when she asked a question and the professor looked at her disdainfully and noted “you should already know this!” Here confidence plummeted… WOW! brings back memories…this is the EXACT experience I had with learning STEM subjects “back in the day!” Now, there are teachers/mentors/professors (these terms merge for me) like Chris who do not make assumptions about a person’s ability. Who brilliantly understand that most often not knowing/understanding can overwhelmingly be caused by a lack of context rather than an innate ability. Aha – now to me it is about the mental model…not a judgement of mental incompetence. Thanks to all those who set the passionate learner’s mental model in the direction of understanding. Thanks to Chris for the mental model I am developing about electronics.
Ryan (Sparky’s Widgets) embraces the concept of Open Source in a way that makes it possible for me to learn more about the details of pH and EC sensors. I would not be able to create these shields without Ryan’s Open Source minipH and miniEC projects. Ryan also makes these available for sale. I highly recommend buying these. At least check out his offerings.
There has been a TON of great articles available through the “Google is Our Friend” of today’s Internet. Thanks for all the information – particularly when stuff doesn’t work! My biggest challenge is using the right search term. Something I assume will always be a challenge.
Testing the Wien Bridge Oscillator
I was not able to get Oscillation going in prior tests (link). No wonder – since the circuit is wrong…OOPS! :-) (I know it’s not funny, but for some reason I find my screw ups to be delightful. I think because the only thing they “hurt” is my ego). This is after spending several hours dedicated to understanding the electronics and circuit design of a Wien Bridge Oscillator (link).
Here’s the current design…
…exactly how is the bandpass filter supposed to work? The frequency filter needs to be on the non-inverting side of the op amp. The feedback loop is on the non-inverting side. Like this example from The art of electronics, second edition p 297:
Key characteristics of this circuit:
- The frequency of Oscillation is determined by a band pass filter. For EC measurements, the desired frequency is 1.6KHz. The equation for determining the frequency based on the resistor/capacitor choice (see the kicad EC.sch schematic found at this GitHub location) R14 = R19 = R= 1K and C9 = C11= C=100n…. f = 1/(2∏RC) = 1/(2*3.14*1000*.0000001) ~= 1.6KHz. If the circuit was set up right, the output frequency should be very close to 1.6KHz.
- Oscillation gets going when the Gain is slightly greater then 3. As this post notes: Setting the correct op amp gain is critical. Not enough – oscillations will cease. Too much – oscillation amplitude will grow until the output saturates.
- Once the Oscillation is going, the gain is maintained at 3.
The non-inverting side of the op amp – setting the frequency of the output wave – shows a bandpass circuit that works for waveforms of 1.6KHz.
The inverting side of the op amp sets the feedback loop to a gain of 3 (20K/10K + 1) = 3. The gain in the Healthy EC Dev-Rev1 circuit is (22K/10K+1) = 3.2. Which made sense to me after reading this post which states in the section Diode Stabilised Wien Bridge Oscillator:
Initially the gain….will be just slightly greater than 3, this will allow oscillations to start.
Using diodes. Explore JFET. Which JFET? Use Zener diode? I need to understand the feedback look of the Wien Bridge Oscillator circuit in The art of electronics.