31 DC Power Sources
Batteries
Adafruit provides a basic battery tutorial. One of the big pluses of using batteries in analog instrumentation is the lack of noise in the power supply.
All batteries start out at a voltage higher than the nominal voltage when fully charged. The voltage drops as the battery approaches a discharged state, or when a higher current is drawn from the battery. While a battery is being charged, the charger voltage will be even higher than the fully charged voltage.
As an example, a nominally 12 volt lead acid battery being charged by a solar system might have a charging voltage as high as 15 volts, a fully charged voltage of 12.8 volts shortly after sundown, a short term drop to 11.5 volts while driving a pump motor, and a voltage closer to 12.0 volts or even lower by dawn if it has been under heavy use through the night.
AC Adapters
Adapters that plug into wall sockets usually use a switching power supply to reduce the 120V AC household power to a continuous DC voltage. Commonly available output voltages include 12V, 9V, 7.5V, and 5V. The 5V adapters are often provided with a USB connection to charge phones or other devices. The higher voltages usually have a barrel jack connector, usually with the positive voltage on the centre part of the connector. Always check the voltage and polarity of AC adapters before making a connection as the wrong adapter could destroy your device.
The noise level of the DC voltage will vary with adapter quality and current draw. You may need to provide some power conditioning for analog circuits.
The DC voltage will typically start high at no load and decrease slightly as the current draw approaches the rated load. A good power supply will include a shutoff mechanism triggered by exceeding the rated load, allowing it to survive your mistakes.
USB Ports
The actual USB ports on your computer provide data connection and can also provide power at about 5 volts. It can be reduced to lower values like the 3.3 volts required by many microcontrollers with a simple voltage regulator, usually located on the microcontroller board.
The current is provided directly from the computer’s power supply and may be noisy. Most computers will provide a constant voltage until they shut off the power if the current draw exceeds 500 mA.