The Silence Map

Asked on Super User by Prakash Dutta, 6 years ago. No reply there for at least a week.

Triggering a python script when charger is plugged in windows 10

I want to write a python script that will alarm the user when the battery is fully charged in his/her laptop. I can write a python script that will check the battery status every 5 minutes and when the battery is 100% charged, it will fire some alarm. But I don't want this script to be running in the background forever. Instead, I want to run this script only when the charger is plugged in. How do I access this kind of event?

This question is one of 1 report of the same problem:

Triggering a python script when charger is plugged in windows 10

Nobody has answered it yet, here or anywhere.

Related problems

Question by Prakash Dutta on Super User, licensed CC BY-SA. We show a short excerpt and link to the original thread as credit.