top of page

Universal mobile power supply for Arduino

 
Requirements for the project:
  1. It has to be a rechargeable power source (Li-ion or Li-pol batteries) for Arduino and sensors.

  2. Batteries might be in different formats: 18650, from mobile phones (different geometry and the number and location of power connectors), Li-ion batteries of various shapes and thicknesses with power wires. It is necessary to make a universal device capable of charging all types of batteries I have and powering 5V electronics from this battery.

  3. The battery can be charged either via micro-USB or using a 5V solar panel.

  4. It is necessary to monitor the voltage of the battery to determine the charge level.

  5. The final device must be housed in a sealed case for outdoor use and capable to bear at least light rain.

  6. The device case should be able to accommodate a half-size breadboard for the Arduino, associated electronics and sensors.

  7. It should be possible to pull the device out of the case for modifications and electronics installation.

Photos of the finished device and in the assembly process.
Device diagram
Components used in the project.

All components used (except for the case, printed circuit boards, wires and male bumper connectors) are shown on the diagrams and named for ease of comparison of the component in the diagram and in the description below, its name will be indicated in brackets (in red).

Case.

Due to the fact that I do not have a 3D printer and I cannot make a case for a specific project, I purchased a transparent (to see the glow of the LEDs) plastic box (for storing food) with a tightly lidded lid of a suitable size in a home accessories store.

Price 2 USD.

Solar panel ( D1 ).

I had several solar panels of different sizes and capacities. I chose a small panel 110 * 60mm with a voltage of 5V 1W (200mA) (the declared maximum, which is usually practically unattainable, I received about 150mA on a bright sunny spring day). The panel fit well in size on the case cover.

The price of this solar panel is 2 USD.

Schottky diode ( D2 )

A diode should be used to exclude the backflow of current to the solar panel (when it is not generating current), a Schottky diode is best suited for that purpose. The Schottky diode has low voltage drop (0.3-0.5V), in comparison to the usual diode type 1N007, where the drop is 0.8-1V. I only had a very powerful diode 1N5825 (40V, 5A), but for this project a simpler diode 1N5817 (20V, 1A) could be suitable as well, and it also has an even lower voltage drop, which is important considering that we are dealing with a small solar panel.

Price of 1N5817 : 4.5 USD for 50 pieces

Battery Charge Module (BMS) ( M1 ).

I used the TP4056 module, which has a micro-USB connector on board and capable to charge with a current of 1A and a voltage of 4.1-4.2V, the model has protection against overcharging and over-discharging of connected lithium-ion battery. The module also has terminals for a separate alternative incoming power supply (in my case the solar panel).

Because I did not plan to make the device to work with more than one battery, then higher charging power and voltage were not required, although I have more powerful charging and step-up/step-down modules.

TP4056 module price : 2 USD for 5 pieces

Step-up / Booster module ( M2 ).

Such a module is required in the device because the battery charging module transfers voltage from the connected battery i.e. 3.7-4.2V, and for the purpose of powering Arduino or other electronics, I need stable 5V.

A compact and efficient step-up module from Wavgat was chosen, supporting 1-1.5A current.

Price of the used boost module : 1.1USD

Power connectors ( J1-J3, JP1, JP2 ).

The project uses 3 double screw connectors for printed circuit boards

  • ( J1 ) for connecting batteries with wires or an 18650 battery located in the battery box.

  • ( J2 ) for solar panel connection (I choose screw connector over soldering for easy device disassembly)

  • ( J3 ) for 5V output from the step-up module to the breadboard

in order to connect and use batteries from mobile phones, i needed exactly the same connector as it used in mobile phones ( JP1, JP2 ). In the diagram, for ease of reading, the 4-pin connector was divided into two. I had 3 different batteries, 1 of them with 3 contacts and 2 with 4 contacts, and the location of the + and - contacts was also different. As a result, I took off the connector from the old donor phone with 4 pins, which could be used for all my different batteries. You can also buy this connector on AliExpress. The issue with the different location of the power and ground pins on battery was resolved through switches (see below)

PCB connectors price: 1 USD for 20pcs

18650 battery case price: 1 USD for 1 piece

Switches ( S1-S4 ).

The project uses 4 3-pin switches for PCB mounting.

Two of them are used to select the battery contacts from the mobile phone, one ( S1 ) for the first pair of contacts (GND), the other ( S2 ) for the second pair (VCC).

The third switch ( S3 ) is used to connect an alternative power supply to the charging module (solar panel)

The fourth switch ( S4 ) is used to turn on the 5V boost module. The decision to install this switch was made to ensure power saving and not to keep the module on when there is nothing to power (battery charging only and storage mode).

Switches price: 2USD for 10pcs

Voltmeter ( M3 ) and button ( S5 )

Voltmeters of this type are available with 3 and 2 wires. The voltmeter with 2 wires receives power for itself and measures the voltage from the same circuit, I depicted that voltmeter on the diagram. The three-wire module receives a separate power supply for itself and separately connected for the measurement circuit, which allows to measure wider range of voltages that are not sufficient or exceed the operation of the module itself.

The voltmeter display contains 3 numbers and can be of 4 different colors.

The button ( S5 ) has been added for the purpose of saving the energy consumed by the voltmeter ( M3 ), and switching it on only when it is necessary.

Voltmeter price: 2 USD per piece

Button price: 2 USD for 30 pieces

Printed circuit board.

The project uses three printed circuit boards. Two 5x7cm as vertical walls and one 7x9cm as a "floor" for the mobile battery.

All elements of the device were soldered on "PCB walls".

It is convenient to connect printed circuit boards to each other by single-core wires (0.5mm)

5x7 PCB price: 2.5USD for 10pcs

7x9 PCB price: 1.6USD for 5pcs

Bread board

A half-size breadboard is used to house additional possible electronic components such as an Arduino microcontroller and various sensors. VCC and GND are routed to the breadboard bus through wires connected to the connector ( J3 )

Half size breadboard price : 1.5USD per piece

Bumper connectors

I installed 4 double male connectors on one of the PCBs as a bumper to reduce the backlash of the device inside the case. It's a completely optional thing.

Price for bumper connectors: 2USD for 30 pieces of 40pin connectors

 

Total for components.

The cost of all components of the project excluding tools and consumables (flux, solder, wires) was: 13 USD , if we exclude the prototype board, then 11.5 USD.

All components mentioned above with the links you can find in this Google-document.

Instruments.

To work on the project, I used the following tools (see photo above):

  • Heat resistant elastic mat

  • Vise for PCB repair

  • Multimeter

  • Glue gun (for fixing the JP1-JP2 mobile battery connector and fixing the solar panel to the case)

  • Wires. The project uses two types of wires, single-core 0.5mm for all connections and bonding of printed circuit boards and multicore 22AWG for flexible connection to the solar panel and the breadboard.

  • Heat shrink tubes for insulating wire connections

  • Gas burner (I use instead of a bulky hot air gun, very convenient)

  • Flux in the form of a marker pen

  • Solder wire

  • Soldering iron

  • Soldering iron tip cleaning sponge

  • Soldering iron tip stand

  • Nippers

  • Pliers

  • Screwdriver

  • The copper clip for securing the wire while soldering was incredibly handy.

  • Third hand (not shown in the photo). You can do without it, but it is more convenient to use it.

A more detailed description of these and my other DIY tools with links where to find them is here.

bottom of page