Windows: getting notification about power state changes
mail at timgolden.me.uk
Tue Oct 19 11:30:39 CEST 2010
On 19/10/2010 10:06, Gelonida wrote:
> I'd like to be notified about certain events and call certain python
> functions depending on the event.
> call a function:
> - before (or after) the screen saver kicks in
> - before (or after) the monitor is switched off
> - before (or after) the hard disk is switched off
> - before the PC enters stand by mode
> - after the PC left stand by mode
> - before (or after) the PC's hard disk was powered up
> - before (or after) the monitor was switched on
> - before (or after) the screen saver was stopped
This should take you a certain amount of the way:
I honestly don't know if the OS even knows when the monitor's
switched on / when the disk is spun up.
WMI has some power events:
but again I don't know about disk/monitor events.
More information about the Python-list