Inspiration

Recently, my parents suspect that my time spent on the computer has led to an increase in the electricity bill, so I decided to track my PC's power consumption to see if that was the case. I also wanted to see the potential environmental effects of prolonged electricity usage.

What it does

Upon game launch, the program will ping the TP-Link smart plug every second for a power reading. After the game is exited, the average power, energy consumption, and energy cost will be calculated for the duration of the game time. The energy consumption and equivalent CO2 emissions per month and year are also calculated, assuming that the user plays the same amount per day.

How I built it

I used the python-kasa API to communicate with the TP-Link smart plug, which my PC plugs into.

What I learned

While working on this project, I realized I never really thought about how much energy my PC uses during long gaming sessions. Although $0.22 per kWh seems like nothing, it can quickly add up if you game frequently and for long periods of time. After seeing the results of my testing, I'm definitely more energy-conscious whenever I'm on the computer.

What's next for PC Game Power Monitor

A proper GUI and better method for game detection. Also a way to set a monthly budget and calculate the maximum gaming time based on it.

Built With

Share this project:

Updates