I have a Qi charger in my car and I wanted that my phone launched the dash cam app when the phone starts charging on this base.

Is there any API to detect the ID of the Qi charger? Besides the API, is there any way to generate an event when the phone starts charging?


1 Answer 1


Type of Charging is determined by :

  • Charging Signature - see here

  • The D+ and D- pins of the cable that negotiate the charging voltage and current with the device, in tune with the charging circuitry in the charger (see Overview of USB Charging for more

  • So a Qi charger would be recognised by the internal circuitry in the device and voltage / current negotiated with the battery charger circuit , depending on the charge level of battery

I am not aware if the API provides information regarding the make or brand or ID of charging, to use that to trigger any action. If available , that would be so very convenient for OEM's to tie users to their own chargers as a sales strategy :). I have also not come across any evidence in the charging algorithms published by charging IC manufacturers. This is not a definite conclusion though

Coming to your requirement, is the preferred option. Many apps are available. I prefer using MacroDroid , since it is free (upto 5 macros) and easy to learn. To understand how MacroDroid works and required settings, my answer here

Your macro would look like this

  • Macro : Dashcam (name of macro )

Trigger: Power connected / removedPower connected

Action: Launch application → Select from drop down your dashcam app

Constraints: WiFi State → WiFi not connected to network ( assumption here is that when you are in your car you are not connected to any WiFI network. When you are connected to any network say at work or home, and charging this macro will not run, meaning your dashcam will not be launched)

Alternative constraint suggested by OP, an excellent one ( thanks ) is

Bluetooth State:Device connected


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .