Deze schakeling beschrijft hoe je de ventilator automatisch kunt laten in- en uitschakelen, afhankelijk van de luchtvochtigheidsgraad. Zakt deze onder een zekere drempelwaarde, aangeduid met led lampjes, dan schakelt de ventilator zich uit. Zie details voor het schakelschema in de onderstaande afbeelding. De toelichting is per onderdeel van de schakeling beschreven in het Engels (machine vertaling).

– The purpose of this circuit is to switch a ventilation motor on or off at high or low humidity. It concerns the ventilation in the mechanical ventilation cabinet of the house.

– The voltage for the circuit is 12V by means of a transformer, rectifier, smoothing capacitor and a type 7812 voltage regulator.

– The humidity sensor is of a capacitory nature. At higher humidity, the impedance decreases. An AC voltage is required for measurement. This is generated in the opamp by means of a relaxation oscillator.

– This relaxation oscillator is generated by a JFET opamp (LF347). The diagram entails a description of the way the oscillator works. Ground for the purpose of oscillating is established created midway between Vcc (12V) and Vdd (0V). Frequency is about 4.5 kHz.

– Through a coupling capacitor this pulse is fed to the moisture sensor. After the sensor, the signal is rectified and after a smoothing capacitor the signal is supplied to an amplifying opamp. Voltage at normal humidity is approximately 200mV (at the non-inverting input of the opamp).

– This opamp is a CMOS opamp (CA3040) because this typ of opamp is able to measure common mode input voltage of 0V. Unlike the JFET opamp, which is only sensitive as of about 1V. The gain based on this non-inverting circuit is 1+20=21 using 5.1 k and 100 k resistors. The output signal averages about 4 to 4.5V, of course depending on the humidity (in the bathroom).

– The output signal is fed into the base of a transistor that has a set of LEDs on its collector side that, triggered by the amount of current in the transistor, light up successively in green, yellow and red. On the emitter side there is a diode (to provide a certain amount of voltage drop) and a resistor. In addition, each LED also has a current limiting resistor of 1k.

– Secondly, the output humidity signal is fed to a JFET opamp (LF347) which compares the amplified voltage at the non-inverting input with a reference voltage from a 2V variable resistor at the inverting input. At a lower voltage < 2V at the non-inverting input, the inverting input ‘wins’ and accordingly the opamp’s output goes to low. In the case of the JFET opamp this compares to 1.2V.

– This output is then offered to a C-channel MOSFET (RFP70N06) with a gate source threshold of 2V. At a low voltage at the gate the MOSFET blocks. This causes the voltage at the drain side to rise to Vcc.

– This positive voltage is tapped at the drain side and led to an NPN transistor.

– At the base of the NPN transistor there is a continuous pulse at a frequency of about 8 Hz. This frequency is generated by means of a relaxation oscillator from a JFET opamp (LF347). In the same way as in the previously described relaxation oscillator circuit. This makes a blue LED on the emitter of the transistor flashing. Note: the higher the voltage at the base, the higher the current through the emitter.

– In addition, the output of the comparator is routed to an optocoupler MOC series 3063 (shown in the diagram as a relay). The internal photo triac turns on at input high. Since the 230V circuit has an inductive load (AC motor), there are peaks in the current when the motor suddenly turns off. The optocoupler is not able to handle this sudden increase in current and breaks down. To prevent this, the outputs are connected via a 470 Ohm resistor to the MT1 and MT2 connections of the triac. Furthermore, the gate of the triac is connected to one of the outputs of the optocoupler. This allows a larger peak current to be processed in the triac. A snuffer circuit is installed parallel to the triac by a series resistor (470 Ohm) and a capacitor (100 nF, rated 600V). The triac was designed for it, not the optocoupler.

– The 12V power supply is built with a 7812 voltage regulator.

Learning moments

– Do not solder to the moisture sensor.  It can only withstand 60 C°.

– The higher the voltage between base and emitter, the higher the current through base and emitter. Depending on the beta gain of the transistor, the collector current is increased. Resistors in the line collector and emitter only determine whether the current is lower than allowed by the transistor but the transistor determines the maximum allowed collector current.

– A 555 timer or an opamp can both be used to generate a block voltage (oscillator). A 555 timer is set up for this purpose; an opamp can be used for this purpose. In my case I wanted to get as much as possible out of the quad opamp.

– Quad opamps have the advantage that you can use an opamp four times on a chip. However, you can’t control bias or offset because these pin-ins are missing.

– Send out a JFET opamp comb not lower than 1.2V. A CMOS opamp does. This is the so called input common mode voltage. That’s why I used a separate CMOS opamp to amplify the 100-300mV signal.

– The MOSFET transistor blocks completely or opens the channel completely. Useful to set Vcc or Vdd.

– Amplification via an inverting or non-inverting circuit is transparent and easy to calculate. Of course, increase can only take place up to Vcc.

– Pay close attention to the power in the transistors, chips or voltage regulators.

– Don’t put a diode in line between emitter output and zero rail voltage. When current is too low, the diode cuts off, so does the transistor which makes that the input signal to the basis does not have a reference point: the input starts to float. When this input signal is also used to compare to a reference voltage on an opamp, the output of the opamp may start to be unpredictable.


Translated with