John said:
Standard disclaimer: use at your own risk, etc.:
Because you mentioned that you were relatively inexperienced in electronics,
the expression, "attach it to the car battery" is a little scary. It
sounds like you might be thinking of attaching directly to the battery,
which requires both fusing and the knowledge of how to design and install
it safely (without risk of burning the car or yourself).
The right place to tie in is at the car's fuse block. That's the
distribution point for electrical power.
You'll want to find a circuit with a small-value fuse (e.g., 5 amp) that is
energized with the key off, and find a wire on the fused side of that
circuit (when the fuse is pulled, it's dead). Then you can just tap into
that wire using one of those 3M insulation displacement connectors (no
stripping, cutting or soldering). Voila! And you're protected against
accidental short circuits.
Yep, that's about how I would do it. But if you are scared to do the
installation yourself, have your car shop do it for you. Takes only 5
min so their time is a lot cheaper than a new car if you get it wrong...
IIRC, that sort of dummy burglar alarms are even commercially available
(so you are not the first to think about that). Whether they would scare
off a professional car thief is a different matter.
If you want to learn more about electronics, a real car burglar alarm
would be a nice project to start with. Some simple circuits come to
mind:
a) Somebody entering a car or driving it would cause movement. A
pendulum could be used to detect that. Circuit is very simple.
Disadvantage: Usually some kids find out quickly that shaking the car
causes the alarm to go off, and use it to annoy the neighbours.
b) A car ignition uses high current, causing the voltage at the car
battery to drop. This can be detected electronically. Not too
complicated, and probably quite tamper-proof.
c) Detect opening of the doors, using the switches for the internal
light. Very simple, but no real obstacle for professionals.
d) Detect the presence of humans inside the car by ultrasound. Circuit
is a bit more involved, an can sometimes cause false alarm after
temperature fluctuations.
Have a look at the electronics section of your local library for a book
on the subject. You may also be able to get such a system in kit form
from an electronics dealer.