The new UPS Power HAT for Raspberry Pi Zero is an uninterruptable power supply HAT (Hardware Attach of Top) for the small yet powerful single board computer. It is able to provide steady power source to Raspberry Pi for an extended period of time when the main power is off, by which to avoid unpredictable system down and assure safe shut down. In addition, the product could be used to supply stable power for some applications requiring mobility such as, Raspberry Pi camera, tablet PC, field data collection system, a portable Raspberry Pi as Laptop or IoT (Internet of Things).
The HAT comes with 3 (two) on-board LEDs to show the status of the battery at full capacity or charging. A MAX17040 fuel gauge is adopted in this product for accurate power detection. Thus, Raspberry Pi board is able to get information of battery capacity and battery voltage directly via I2C communication.
Note: The HAT comes with battery, but not Raspberry Pi computer, please get it separately.
- Cascading (from bottom) design saves space while powering raspberry pi and expansion boards without affecting GPIO expansion.
- Support up to 400mA charging current for battery charging
- Can be charged and supplied power to raspberry pi at the same time.
- With 3 LED power indicator FULL indicator ,CHARGE indicator and 5V Output Indicator.
- The HAT comes with a Lithium Polymer (LiPo) with capacity of 1000mAh.
- Able to power Raspberry Pi Zero W for around 30 minutes without main supply under normal usage.
- Removable battery, user can choose a more larger capacity lithium battery pack (NOTE: typical voltage must be 3.7V).
- With safety protection circuit to prevent overcharge and over-discharge.
- Support I2C communication with Raspberry Pi main board for battery voltage and capacity
Note: The USP HAT will provides power to Raspberry Pi via GPIO pins, so DONOT connect the micro USB to rasberrry pi. Please connect the micro USB to UPS HAT board and the UPS HAT will power Raspberry Pi Zero via the GPIO.
- Firstly,you need to remove the Pogo pins protector as shown in the picture.
- To remove the Pogo pins protector you might need to let loose the screw of the screwed protector
- After removing the protector, tighten the screw back
- Then, stack the Raspberry Pi Zero computer onto the UPS HAT via the 40-pin GPIO and tighten the screw to Pi Zero board with the nut provided
- To power on the Rasberry Pi Zero,simply toggle the swith on UPS HAT to 'ON' and vice versa
- Charge the UPS HAT via microB receptor on the HAT
- UPS HAT is also in charging mode when Rasbperry Pi and UPS HAT is power up at the same time.
- Example of coding via python:
- Via Terminal:
- First, enable the I2C on Raspberry Pi proccessor, run this command: sudo raspi-config
- Next, install I2C tools, run this command: sudo apt-get install i2c-tools
- To check the tools installation, run: sudo i2cdetect -l
- To check the address of the I2C decice run: sudo i2cdetect -y -a 1
- The address of MAX17048 should be 0x36
- To check the battery capacity, run: sudo i2cget -f -y 1 0x36 4 w
- In example, it returns "0x853d"
- "0x853d" in some way represent the battery capacity, but some conversion is needed. According to MAX17048, we need to swap the high byte and low byte. We will get "0x3d85" after swapping.
- Next, converts "0x3d85" into decimal，0x3d85 = 15749(Decimal)
- Now, 15749/256 = 61.52 is the percentage of the capacity, that means the battery capacity is 61.52%.
- To check the voltage reading run: sudo i2cget -f -y 1 0x36 2 w
- In example, it returns "0xb0bc"
- "0xb0bc" in some way represent battery voltage, but again some conversion is needed. According to MAX17040, we need to swap the high byte and low byte, it will be "0xb980"
- Next, converts "0xbcb0" to decimal, it will be 47488
- The battery voltage is: 48304* 78.125 / 1000000 = 3.71V
- Note:78.125 is a fixed value
- The 3.71V is the Battery Voltage
- 1 x UPS Power HAT for Raspberry Pi Zero
- 1 x 3.7V 1000 mAh Lithium Battery