SageTV Community  

Go Back   SageTV Community > Hardware Support > Hardware Support
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

Hardware Support Discussions related to using various hardware setups with SageTV products. Anything relating to capture cards, remotes, infrared receivers/transmitters, system compatibility or other hardware related problems or suggestions should be posted here.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 03-01-2006, 06:08 PM
amac's Avatar
amac amac is offline
Sage Advanced User
 
Join Date: Dec 2005
Posts: 107
Smile Power Management Revisited

Well, I've finally developed a solution for my power management woes. My woes are primarily around my Hauppauge IR blaster/transmitter losing synch with Sage and so channel changing was not working when the computer would resume from standby.

I've written a Windows script that detects the Windows events for entering standby and resuming from standby. Yes, sounds a bit like Sagewake. But Sagewake wouldn't work properly for me and is no longer supported.

Furthermore, this script doesn't take over scheduling power management like Sagewake did. It leaves that up to Sage. That makes sense as Sage knows best when it can go to sleep and it knows best when it should wake up.

All this script does is enable anyone who has the know-how to alter this script to run any program they want as the computer is about to enter standby, and run any program(s) when the computer wakes up.

The script has not been generalized. Anyone wanting to use it will have to tailor it for their own setup but it's not too hard. Perhaps someone will be nice and generalize it for the group.

Oh yeah, to use it (after you have modified it to suit your needs) do one of the following:
1. simply add it to your startup folder and reboot.
2. You may double click on the file from explorer. Obviously, running it this way will only work until the machine is rebooted.

If ever you need to stop the script, bring up the task manager (CTRL-ALT-DEL) and end the process named 'wscript'.

Good luck.
Attached Files
File Type: zip MonitorResume.zip (720 Bytes, 480 views)
__________________
amac's config:
Sage 7.1.9, Java Java 1.7.0_75, Windows 8.1, Athlon X4 620, 4GB, Hauppauge 950Q, ATI 650HD video encoder with IR/Blaster, Radeon 5450, HDMI out, TV is primary monitor, Plex Plug-in serves up to mobile devices/PS3/WiiU just fine

Last edited by amac; 03-07-2006 at 11:20 AM.
Reply With Quote
  #2  
Old 03-31-2008, 10:02 PM
Altec Altec is offline
Sage User
 
Join Date: Feb 2006
Posts: 6
Actisys 200L wake from s3 issue

Hi Amac

I'm having an issue with my Actisys 200L IR blaster (connected to serial port). It doesn't wake when the PC is resuming from s3 until I manually shut and re-start the Sage Service.

I saw your script below and was wondering if it could be altered to 'simply' close the Sage Service and re-start it immediately upon PC resume from S3 state.

I normally only operate Sage in service mode for recording.

Greatly appreciate your help.





Quote:
Originally Posted by amac View Post
Well, I've finally developed a solution for my power management woes. My woes are primarily around my Hauppauge IR blaster/transmitter losing synch with Sage and so channel changing was not working when the computer would resume from standby.

I've written a Windows script that detects the Windows events for entering standby and resuming from standby. Yes, sounds a bit like Sagewake. But Sagewake wouldn't work properly for me and is no longer supported.

Furthermore, this script doesn't take over scheduling power management like Sagewake did. It leaves that up to Sage. That makes sense as Sage knows best when it can go to sleep and it knows best when it should wake up.

All this script does is enable anyone who has the know-how to alter this script to run any program they want as the computer is about to enter standby, and run any program(s) when the computer wakes up.

The script has not been generalized. Anyone wanting to use it will have to tailor it for their own setup but it's not too hard. Perhaps someone will be nice and generalize it for the group.

Oh yeah, to use it (after you have modified it to suit your needs) do one of the following:
1. simply add it to your startup folder and reboot.
2. You may double click on the file from explorer. Obviously, running it this way will only work until the machine is rebooted.

If ever you need to stop the script, bring up the task manager (CTRL-ALT-DEL) and end the process named 'wscript'.

Good luck.
Reply With Quote
  #3  
Old 04-16-2008, 06:52 PM
Altec Altec is offline
Sage User
 
Join Date: Feb 2006
Posts: 6
Just in case anyone else has this problem, I installed a freeware program called 'Hibernate Trigger' which will run any file/script on PC wake up.

I just applied a simple script which stops the Sage Service and restarts it again. Hibernate Trigger runs this script everytime my PC resumes from s3 stand-by.

My Actisys IR then performs without problems.

.bat file
--- begin ---
net stop "SageTV"
@ping 127.0.0.1 -n 2 -w 1000 > nul
@ping 127.0.0.1 -n %1% -w 1000> nul
net start "SageTV"
--- end ---
Reply With Quote
  #4  
Old 04-17-2008, 01:30 PM
brewston brewston is offline
Sage Expert
 
Join Date: Apr 2006
Location: Surrey
Posts: 719
Any idea on the syntax to kill the UI on standby ? I'd like to try this to work around an mp3 image caching problem I seem to have

Thanks
__________________
Tecra M5, 2 x HD200, 2 x HD300
2 x PCTV 290e
Win 7, Sage 7.1.9, Phoenix 2 STV
Stephane's XMLTV Importer, Digiguide,
Reply With Quote
  #5  
Old 04-17-2008, 08:19 PM
Altec Altec is offline
Sage User
 
Join Date: Feb 2006
Posts: 6
Quote:
Originally Posted by brewston View Post
Any idea on the syntax to kill the UI on standby ? I'd like to try this to work around an mp3 image caching problem I seem to have

Thanks
Amac closed the UI as part of his VB program to reset his IR remote. Perhaps you could use that part of his code?

strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colMonitoredEvents = objWMIService.ExecNotificationQuery _
("Select * from Win32_PowerManagementEvent")
Set WshShell = WScript.CreateObject("WScript.Shell")

Do
Set strLatestEvent = colMonitoredEvents.NextEvent
if strLatestEvent.EventType = 4 then
'WshShell.Popup "Entering Suspend/Standby/Hibernate",1
'close the remote control IR program
WshShell.Run """E:\Program Files\WinTV\Ir.exe""" & " /QUIT"
elseif strLatestEvent.EventType = 18 then 'resume automatic
WScript.Sleep 1000
' WshShell.Popup "Resuming Suspend",1
WshShell.AppActivate "SageTV"
'send Sage Alt-F4 to close the program
WshShell.Sendkeys "%{F4}"
WScript.Sleep 10000
'restart the IR process
WshShell.Run """E:\Program Files\WinTV\Ir.exe""" & " /QUIET"
' WshShell.Popup "IR restart sent", 2
WScript.Sleep 2000
'restart sage
WshShell.run """e:\program files\sagetv\sagetv\sagetv.exe"""
WScript.Sleep 35000
' WshShell.Popup "Sage activate sending", 30
'make sage the front window (and so ready for remote control)
WshShell.AppActivate "SageTV"
end if

Loop
Reply With Quote
  #6  
Old 04-18-2008, 03:17 PM
amac's Avatar
amac amac is offline
Sage Advanced User
 
Join Date: Dec 2005
Posts: 107
Wow. I didn't realize this thread had come back to life.

Altec, looks like you found a great solution to your problem. I'll keep it in mind.

Brewston, I must say I don't use my script anymore since I switched to Windows XP. My driver refresh problems went away.

However, I think with the right modifications you should be able to use it try and address your issue.
__________________
amac's config:
Sage 7.1.9, Java Java 1.7.0_75, Windows 8.1, Athlon X4 620, 4GB, Hauppauge 950Q, ATI 650HD video encoder with IR/Blaster, Radeon 5450, HDMI out, TV is primary monitor, Plex Plug-in serves up to mobile devices/PS3/WiiU just fine
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 12:57 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.