Hard Wired Apple AirTag with Battery Backup.

Thread Starter

_ts

Joined Oct 22, 2024
1
I came here from this thread which was massively helpful. I am looking to do something pretty similar, but instead of connecting to the car's battery, I want to do mine via USB, as most cars have USB type A or cigarette charger outlets in the truck or gloveboxes.

The idea is to have the AirTag powered by the car (USB) when the car is on, when the USB looses power, it defaults to backup battery (LIR2032), which is also charged by the car (USB).

Here's what I am thinking:

Car USB (5v Output) -> Buck Converter (5V to 3.6V for LIR2032) -> TP4056 Lithium-Ion Charging Circuit -> Schottky Diode -> AirTag with LIR2032 Rechargeable Battery in it.

The benefits of doing it this way is I can use the original AirTag enclosure with the battery holder, and just solder in the connection points. Does this sound like it would work? Is there an easier way to do this? Is a TP4056 or similar charging circuit really necessary?

Thanks
 

Ya’akov

Joined Jan 27, 2019
10,226
Welcome to AAC.

In principle, what you propose should work but what three caveats concerning the TP4056:

1. The LIR2032 has a charging regime of CC/CV which is typical for Li cells, but while the CV phase is the standard 4.2V, the CC phase is only 17mA, far lower than the designers of the TP4056 anticipated. However the charge current of the chip is programmable using a resistor on pin 2 (PROG). The table of values provided in the data sheet only goes down to 100mA—but in the text there is a formula for calculating arbitrary values: \[I_{BAT} = \frac{V_{PROG}}{R_{PROG}} \times 1200\]
Solving for a standard value resistor, it seems that a 100kΩ resistor is the closest option at ~14mA.

2. The charge termination detection method is C/10. If you have both a load connected during charging, the additional current draw of the load may confound the charge termination detection and prevent the TP4056 from terminating the charge, overcharging the cell. The LIR2032 is not vented the way a cylindrical cell is and it will rupture eventually. Well before that it will operate with a reduced capacity.

The solution to this is a PMOS FET that disconnects the LIR2032 from the AirTag during charge. If you want the AirTag to operate during this time, another P-channel FET can be used to connect it directly to the buck converter during the time it is charging. Since the charging will only happen when the buck converter‘s output is available, this should work as required.

3. Temperature sensing, typically used in batteries (such as a 1S2P pack made from 18650 cells) is supported by the TP4056 using a thermistor connected to pin 1 (TEMP). Because you are using this in an automotive application where over- and under-temperature conditions are a real possibility, it is important to implement this function. The TP4056 datasheet has details on the required thermistor. Gluing it to the surface with cyanoacrylate cement and/or taping it with polyimide (Kapton®) tape is important to insure proper operation.

When these concerns are addressed, your plan should work, but there is a remaining concern. The reason for selecting the LIR2032 may not be a good one. The normal cell expected by the AirTag is an LR2032 with a maximum output of 3V making the LIR2032 a full 1.2V more than the designers of the tag (apparently) expect. This may mean you will need a voltage regulator at the output of the LIR2032.

This and the necessity to disconnect the AirTag from the cell means that your design goal of using the LIR2032 in the existing battery holder is probably not obtainable. Making a connector that will fit in the holder, preserving the goal of not modifying the AirTag (a good idea, I think) is relatively easy. Using a 3D printer to create a custom design or fabricating something from PCB material should be simple enough. But once this is the case, the LIR2032 with it small capacity and oddball charge current seems to be cruft. It was a good thought but I see no reason to preserve it now that it is clear it won’t simply be plug and play.

Instead, I would use a small Lithium Polymer cell which has the advantage of a typical charge current, simple connections (a pair of wires) eliminating the need for a coin cell socket or the bother of insulating a leaded version of the coin cell. LiPos can be found in very tiny sizes if required. If you want go through the trouble, you could incorporate a LiPo into the connector that fits the AirTags battery holder along with the load switching circuitry and simply offer the necessary terminals or lead coming form that cell/switching module. Having a PCB made that is cut to fit the coin cell holder shouldn’t be a problem for any of the major PCB service houses. You can even have them assemble the SMD parts and include the TP4056 on the board itself.

Alternatively, consider the scheme used by many dashcam designs to avoid the use of a secondary cell—which are vulnerable to damage by the high temperatures in an automobile passenger compartment in the summer—a supercapacitor. This brings some of its own challenges but should be possible and should provide a longer no-maintenance life cycle.

Good luck, whatever you choose.
 
Top