I want to recognize the charger through my application.
I implemented the Android Accessory API in my app, and installed in Samsung Galaxy S2.
But I am getting AccessoryList as null.
How to resolve it.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The charger is not an “accessory” per se, it is rather a state of the battery. Here’s a nice QA on how to get notified about power connection state.
That your accessory list is empty could be due to some other issue. Please elaborate your question and provide some of your code, it is easier to help out when we know more.