As a complete beginner in the field of electrical engineering, I am trying to build an alarm system on an Arduino board. I want to power my board using an external 10V power supply. In case of power shortage (probably in form of an intruder that is smart enough to pull the plug below my alarm system) I want the board to seamlessly switch to a built-in 9V backup battery.
According to the Arduino documentation, the board will automatically use the higher voltage power supply, so my external should be used whenever available.
Now I am struggling to get the circuit working. So far I came up with this:
But this does not look right to me (connecting V_IN
to the kathode came pretty natural to me, but I haven't quite figured out how to close the circuit). Could someone please explain how to properly design the circuit?
My circuit has one more issue I want to address: as you can see, there is a voltage divider parallel to my pseudo power supply. This is to allow me keeping track of the battery voltage and warning early when to exchange batteries. Using these resistor values the voltage of a fresh battery on AD0
comes across as about 0.85V. Will this drain a lot of my battery capacity while the battery is not even used?
Thanks in advance.
10+1k=11k
. What willVbat/11000
give you? \$\endgroup\$