Do you think about capturing the events to let them show on your serial LCD?
No, not show them directly, but when I have my serial lcd plugin loaded, and I send my machine into S3 standby i get this horrid exception error as follows :-
Code: Select all
System.QuerySuspend
System.Suspend
System.Idle
Exception in thread Thread-206:
Traceback (most recent call last):
File "threading.pyc", line 460, in __bootstrap
File "threading.pyc", line 625, in run
File "23", line 24, in UpdateMyScreen
File "plugins/VFD/__init__.py", line 400, in __call__
File "plugins/VFD/__init__.py", line 330, in UpdateVFD
File "plugins/VFD/__init__.py", line 357, in VFD_String
File "C:\Program Files\EventGhost\eg\WinAPI\serial\serialwin32.py", line 240, in write
SerialTimeoutException: Write timeout
Exception in thread Thread-207:
Traceback (most recent call last):
File "threading.pyc", line 460, in __bootstrap
File "threading.pyc", line 625, in run
File "23", line 24, in UpdateMyScreen
File "plugins/VFD/__init__.py", line 400, in __call__
File "plugins/VFD/__init__.py", line 330, in UpdateVFD
File "plugins/VFD/__init__.py", line 357, in VFD_String
File "C:\Program Files\EventGhost\eg\WinAPI\serial\serialwin32.py", line 238, in write
error: (995, 'GetOverlappedResult', 'The I/O operation has been aborted because of either a thread exit or an application request.')
System.ResumeAutomatic
System.Resume
I know why it happens, my plugin is getting used (serial port routines) whilst the system is going into standby.
I just wanted my plugin to be notified (directly) of any System.Suspend messages so that the system can pause any updates sent to the serial port, or even close the serial port and reopen when resumed, that would be cleaner than anyone having to code / capture / cater for it themselves via an "event sink action" (if i understand what you mean by an "event sink action").
I
could hijack the code from the PowerBroadcastNotifier.py file for my plugin to get the suspend / resume events, you OK with that?
