# Noise in simple BC547-Raspberry Pi GPIO doorbell?

I've connected a Raspberry Pi to my Friedland "Ding Dong" doorbell. The doorbell has two (apparently unused) terminals, over which there seems to be a stable voltage of 1 mV when the button is not pressed, and a stable voltage of 4.8 V when the button is pressed.

To get this signal into the Raspberry Pi, I've come up with this simple design:

Between the switch and the resistor is 10 m of UTP cable. The resistor is the largest one I had, and it can still trigger the transistor. I'm running the GPIO input high (pull-up resistor) so a signal on the base pulls it down to ground.

My problem is that every once in a while, a signal will be detected when there is none. I know noone rang my doorbell, but the Raspberry Pi detects a signal (I'm using Python3 GPIO.wait_for_edge, like this:)

 GPIO.wait_for_edge(pin,GPIO.FALLING)


So I suppose some noise can trigger the transistor? But what can I do about it?

• Keep in mind that many doorbells use AC current to actuate. They have a simple transformer connected to mains which outputs a few volts AC. Are you sure your doorbell uses a DC supply? – Ryan Griggs Jan 1 '16 at 21:54
• Good point! But it does have four 1.5 V cells, and no mains connection :-) – OZ1SEJ Jan 1 '16 at 23:28