These days, almost every home with outdoor lighting has a motion sensor. Such a device eliminates the need to fight your way through the door, but, apparently, it also scares those who enter it. The only problem is that the dogs and cats in the area have no respect for these lamps and continue to put their feces in the garden, when they find a place that is used for this purpose. Hence, the idea of connecting a siren in the same way as an outdoor lamp to clearly show that dogs and cats are not welcome. Naturally, it would be better not to surprise the neighbors with this alarm signal.
Here, we can use the fact that dogs and cats have better hearing than humans. Not only are their ears more sensitive, but they can also perceive much higher frequencies. In humans, the upper limit is around 18 kHz, but dogs and cats can hear frequencies above 20 kHz. We can take advantage of this by building a siren that emits a frequency greater than 20 kHz. It will frighten dogs and cats, but people will not hear it. All that is required is an oscillator with an amplifier stage and a tweeter capable of reproducing these high frequencies, such as a piezoelectric tweeter.
The diagram shows how to do this easily. The power supply for the entire circuit is composed of C2. The 230 V cable is connected individually to the motion detection lamp. C1 and R1 provide capacitive coupling to reduce 230 V to the acceptable voltage. A DC voltage of about 9.1 V is generated from this voltage using a bridge rectifier at D1, which is monitored and stored by C2. The oscillator is built around R3, C3 and IC1a. The frequency of this oscillator instead depends on the specific characteristics of IC1, so the values given here should be considered as a guide. If the oscillator frequency is too high, it can be reduced by increasing the value of R3 and/or C3.
If the frequency is low (meaning that a siren is heard), the value of R3 and/or C3 should be increased. The square wave of the oscillator is applied to the input of the H-bridge which has several Schmitt triggers and the combination of the final output stage (T1-T4). This method makes the value of the square wave signal twice the supply voltage. As a result, a respectable 18V is obtained across the piezoelectric tweeter, which is enough to produce a good sound quality. When building a circuit, you should take into account that it is powered directly by 230 V and not by electrical power in the main.
So it is important to avoid any contact with everything when using the circuit. In practice, this means that the circuit must be enclosed in a well-insulated enclosure. If you want to test the circuit, it is better to first remove C1 using a resistor, because it may contain a dangerous charge. You should also make sure that components F1, C1, R1 and B1 all have a gap of at least 6mm!