Rain Alarm Circuit with BC547 and BC557 Transistors and a Buzzer

Clothes drying on the terrace, grain spread in the sun, a car with open windows: all of these need a warning when it starts to rain. A rain alarm detects water drops on a sensor plate and sounds a buzzer immediately. This version uses only two transistors, an NPN BC547 and a PNP BC557, connected as a complementary pair so that a very small current through the rain water switches the buzzer fully on.

Compared with a single-transistor circuit, the two-transistor arrangement has much higher overall gain. That matters here because a few rain drops bridging the sensor tracks form a path of high and unpredictable resistance.

Components Required

PartValue / TypeQuantity
NPN transistor Q1BC5471
PNP transistor Q2BC5571
R1 (sensor series resistor)1 kilo-ohm1
R2 (Q1 base pull-down)100 kilo-ohm1
R3 (Q2 base resistor)10 kilo-ohm1
R4 (Q2 base-emitter)47 kilo-ohm1
R5 (LED resistor)1 kilo-ohm1
LEDRed 5 mm1
Active buzzer9 to 12 V DC1
Rain sensor plateVeroboard or PCB with interleaved tracks, about 5 x 7 cm1
Power9 V battery with clip, plus SPST switch1 each

Circuit Explained Stage by Stage

Stage 1: The sensor plate

The sensor is two sets of copper tracks interleaved like the fingers of two combs, with a gap of 1 to 2 mm between neighbouring tracks. On a piece of veroboard you can make one by joining alternate strips together at opposite ends. One comb goes to +9 V, the other goes to R1. When dry, the plate is an open circuit. A single drop bridging two tracks creates a resistance path, typically tens to hundreds of kilo-ohm depending on how much water and how dirty it is.

Stage 2: NPN input transistor

Current from the plate flows through R1 into the base of Q1. R1 limits base current if the plate is completely flooded or shorted. R2 (100 kilo-ohm) from base to ground keeps Q1 off when the plate is dry or only slightly damp, and it also sets a rough sensitivity: the water path must deliver enough current to raise the base above about 0.6 V across R2.

Stage 3: PNP output transistor

Q1's collector pulls current out of Q2's base through R3. Q2's emitter is on +9 V, so when Q1 conducts, Q2's base is pulled below its emitter and Q2 switches on. R4 between Q2's base and emitter makes sure Q2 stays off when Q1 is off. Q2's collector feeds the buzzer and the LED to ground, so both turn on together.

Connections

PointConnects toNotes
Sensor comb 1+9 V-
Sensor comb 2R1 to Q1 baseR2 from Q1 base to GND
Q1 emitterGND-
Q1 collectorR3 to Q2 baseR4 from Q2 base to +9 V
Q2 emitter+9 V-
Q2 collectorBuzzer (+) and R5 to LED anodeBuzzer (-) and LED cathode to GND
+9V ---+----------------+-------+
       |                |       |
   [sensor]           R4 47k    Q2 emitter (BC557)
       |                |       |
     R1 1k     Q2 base--+       Q2 collector--+-- buzzer -- GND
       |                |                     +-- R5 1k -- LED -- GND
  Q1 base --+         R3 10k
            |           |
         R2 100k    Q1 collector (BC547)
            |       Q1 emitter
GND --------+-----------+

How It Works

With a dry plate, no base current reaches Q1, so Q1 is off, no current flows through R3, R4 holds Q2 off and the buzzer is silent. Standby current is essentially only transistor leakage, so a 9 V battery lasts a long time.

When rain bridges the tracks, a small current flows into Q1's base. Q1 amplifies it by its current gain, perhaps 150 to 300 times. That collector current becomes Q2's base current, which Q2 amplifies again. The combined gain is in the tens of thousands, so even a weak water path can switch on a buzzer drawing 20 to 30 mA.

Assembly and Testing

  1. Make the sensor plate. Cut the veroboard so alternate strips can be joined at opposite ends with wire links, forming two interleaved combs. Check with a multimeter that the combs are not shorted when dry.
  2. Assemble the two-transistor circuit on a small board. Check the BC547 and BC557 pinouts from their datasheets; they are not always identical between manufacturers.
  3. Connect the buzzer and LED with correct polarity.
  4. Power on with the plate dry: nothing should happen. Measure the supply current; it should be well under 1 mA.
  5. Sprinkle a few drops of water on the plate or touch it with a wet finger. The buzzer and LED should come on at once.
  6. Mount the plate outdoors at a slight angle so water drains off, and keep the circuit board indoors connected by a two-core cable.

Troubleshooting

  • No sound when wet: short the plate directly with a wire. If the buzzer now sounds, the plate tracks are too far apart or dirty; clean them. If not, check transistor pinouts and buzzer polarity.
  • Buzzer sounds when dry: check for solder bridges on the plate, and make sure R2 and R4 are in place.
  • Alarm triggers from dew or fog: reduce sensitivity by lowering R2 to 47 kilo-ohm, or tilt the plate more steeply.
  • Plate corrodes quickly: DC across the tracks causes electrolysis. Tin the tracks with solder or coat them lightly, and replace the plate when it degrades.
  • Weak, distorted buzzer sound: the battery is low or the buzzer is rated for a higher voltage.

Summary

This rain alarm combines an interleaved-track sensor with an NPN and PNP transistor pair. The NPN stage senses the tiny current through rain water and the PNP stage switches the buzzer from the positive rail. The same front end works as a leak detector under a washing machine or water purifier.