NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Add-ons (3rd party plugins, utilities and skins) Old Stuff (Legacy) GB-PVR Support (legacy) v
« Previous 1 2 3 4 5 1231 Next »
Inhibit Computer Shutdown While Recording

 
  • 0 Vote(s) - 0 Average
Inhibit Computer Shutdown While Recording
rwnz
Offline

Member

Posts: 89
Threads: 15
Joined: Aug 2006
#11
2009-11-03, 08:36 PM
Thanks pBs. I look forward to seeing what you put together. I've had little time to study this problem closely so if your solution works then that will suit me very well.
Hauppauge WinTV-HVR-2200, Intel C2D E8400; 4GB RAM; ASUS EN9400GT SILENT 512MB; Windows 10 Home 64 Bit; NPVR + EPG Collector. TVersity; Sony Smart TVs; Xtreamer Sidewinders. TV source: DVB-T
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#12
2009-11-04, 07:02 AM
cool, so far the mechanisms are working fine...just have to get it all tied together, also adding ability to run something before exiting and upon return, from both shut and suspend..
[and an clone of the vista "these programs request you not shutdown" dialog for XP users]
it should be ready in about a week...Smile
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#13
2010-01-01, 12:01 AM
sorry it's been so long...having problems getting suspend intercept working on vista/win7..

shutdown/restart intercept working fine, give you a menu saying
"Recording Protector" is preventing shutdown. Reason: "Recording Monk"
it gives option to cancel shutdown or ignore warning and shutdown...

that screen waits as long as is necessary for recording to complete, not sure if it disappears when recording completes tho..

if you cancel shutdown, back to desktop till recording is done, then it pops up a msg saying it's ok to shutdown now..[just a reminder] and satys at desktop..

suspend intercept works on xp, but not getting it working on vista/7 yet...almost...Smile
i dropped work on it for a week and when i went back,it looked like martian to me...lol
but i'm back on it...as i think it's really good thing to have for all media machines...
[i don't have enough fingers to count the number of times i restarted during a recording..]

i still have to make xp menu look like vista's, and some more general feedback traytiips etc to throw in to wrap it all up..
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#14
2010-01-09, 06:26 PM (This post was last modified: 2010-01-10, 11:51 AM by pBS.)
here ya go, i think i got all the kinks out, but ya never know..
for testing...

it will deny shutdown/restart/suspend if recording is "in progress"..
and asks if you want to still do it...otherwise exits and stops power down..
forced shutdowns aren't interrupted...[like from gbpvr system screen]

if not recording, powers down as normal..
also provides shutdown/restart shortcut menu in tray and visual feedback of recording status in tray..
[not just that capture source is busy]

it works from client for testing, but it's pretty pointless to prevent shutdown of client while server is recording...Smile

darnit, something's not working for suspend on vista/7...
i can reset the win timers so they don't suspend, but user initiated ones just happen...Sad
more research...
rest of it works fine tho...
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
rwnz
Offline

Member

Posts: 89
Threads: 15
Joined: Aug 2006
#15
2010-02-07, 01:03 AM
Thanks. After various distractions over our summer holiday I've started playing around with this stuff again and just noticed your post, so will look into it more over the next few days.
Hauppauge WinTV-HVR-2200, Intel C2D E8400; 4GB RAM; ASUS EN9400GT SILENT 512MB; Windows 10 Home 64 Bit; NPVR + EPG Collector. TVersity; Sony Smart TVs; Xtreamer Sidewinders. TV source: DVB-T
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#16
2010-02-07, 04:50 PM
ahh, summer....it's winter here...Smile
i've been using it since i made it and no probs yet...tho vista/win7 suspend intercept isn't working quite right yet...shutdowns and restarts are..

i'll see if i can't get them going too...must be something i'm missing..or maybe it can't be done..
best part is, it tells you why you shouldn't shutdown..[tells what is recording] so you have a choice if it's something that's not important..
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
rwnz
Offline

Member

Posts: 89
Threads: 15
Joined: Aug 2006
#17
2010-02-07, 09:17 PM
Well pBS, thank you for this. It does do what you said. Unfortunately it is the user initiated suspend that I most need to inhibit. Under XP I had GBPVR working sweetly, waking the computer to update the EPG and to record, and blocking suspend/hibernate/shutdown when recording. Now under Win 7 I also have the problem that when suspended the computer switches on at around 3am. So once I have that sorted then I'll suspend rather than shutdown so that GBPVR can always do its thing.

As for the 'summer' holiday, 3 weeks away including a spot of tenting with only 2 days of good hot sunshine. But get back home and out comes the sun! In contrast, my sisters webcam in the north of the USA shows everything covered in snow.
Hauppauge WinTV-HVR-2200, Intel C2D E8400; 4GB RAM; ASUS EN9400GT SILENT 512MB; Windows 10 Home 64 Bit; NPVR + EPG Collector. TVersity; Sony Smart TVs; Xtreamer Sidewinders. TV source: DVB-T
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#18
2010-02-09, 09:58 PM (This post was last modified: 2010-02-09, 10:38 PM by pBS.)
i'll see if i can't reset the timers instead of denying the suspend instead for vista/7...
for auto suspends that should do the trick..
there's *supposed* to be some way to halt suspends, or maybe just go into away mode or something so it's still on..maybe with win7 out there's new info at MS..

i also need to put a bit in for the epg updates and recordings from sleep, [non-userinitiated wakes] but i see no ill effects so far, mine wakes and does epg update fine, and wakes for recordings fine, so it may no be necessary..but i haven't done much with win7 testing in that respect...

update: unfortunately user initiated suspends are not possible to be stopped in vista/7, period..
workaround, turn off ability to sleep at all, then turn it back on when it's ok...
then there's no sleep mode for user to initiate..Big Grin
i'll have to find some easy commands for that..[should be a powercfg.exe cmdline..]

p.s. here in houston it snows like every 10-20 years...lol
but tar roads literally melt in the summers...Big Grin
[but it did snow here back in decemeber!]
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#19
2010-02-09, 11:10 PM (This post was last modified: 2010-02-10, 05:11 AM by pBS.)
you can also just hide the buttons when you want...Smile
UPDATE: well darn, hiding is instant but unhiding isn't...have to reboot to get them back..
there are some policy entries that seem to disable suspend also..will look there..
AHA! found it, to update immediately, run "gpupdate" after setting reg entry..Big Grin
will see if power configs can be made dynamic this way also..cool
so now can make shutdown buttons disappear and re-appear at will..Smile
Code:
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]
"NoClose"=dword:00000001
and show them when it's ok...
Code:
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]
"NoClose"=-

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer]
"NoClose"=-

which seems to be the fastest/most complete way to stop user intitated ones...
i'm not sure but simply changing powercfg profiles to one that has no timers set to sleep may work without reboot to temporarily disable auto-sleep as well..

i'd put a shutdown/restart/sleep button to replace the windows ones so you could always still chose to shutdown while windows' ones are hidden..
but that one i'd control...Big Grin

this one hides just the sleep button only..
[but it seems to disable sleep modes altogether also..bad]
Code:
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\abfc2519-3608-4c2a-94ea-171b0ed546ab]
"ACSettingIndex"=dword:00000000
undo with:
Code:
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\abfc2519-3608-4c2a-94ea-171b0ed546ab]
"ACSettingIndex"=-
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
pBS
Offline

Posting Freak

Posts: 4,829
Threads: 182
Joined: Aug 2005
#20
2010-02-10, 05:22 AM (This post was last modified: 2010-02-12, 10:58 AM by pBS.)
here's a batch file to try....hides all shutdown options from exporer...[even task manager!]
had to find gpupdate to make them instantaneous..[no reboot!]
Code:
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /f /v NoClose /t REG_DWORD /d 1  
gpupdate /target:computer /force

so it hides sleep as well...tho sleep could be done from another program, it can't be done from windows itself..
on xp it actually hides the buttons immediately, in win7 it does disable, but you still see buttons..it disables shutdown/restart/sleep/hibernate modes..Big Grin
[but they still work, can be called manually, but timers are off..]

to restore:
Code:
reg delete HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /f /v NoClose
gpupdate /target:computer /force

so i'll work these into my program and provide safe alternatives for shutdown with reminders of what's recording or pending soon...as long as no ill side effects i think we have a winner! Big Grin

and seems to work in xp thru win7 the same...good deal..

disable system screen in gbpvr to take those options away from user accidents..
[all those shutdown/sleep options are 'forced' and ignore blocking attempts]
Hardware: HDHR Prime, HDPVR 1212, Raspberry pi2, VFD display w/LCDSmartie
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (6): « Previous 1 2 3 4 5 6 Next »


Possibly Related Threads…
Thread Author Replies Views Last Post
  Audio buzzing second time recording launched. dennit 2 4,514 2012-12-09, 11:28 PM
Last Post: dennit
  Start PC for recording, Sleep/Hibernate when done Basher52 6 4,916 2011-12-17, 02:52 PM
Last Post: Sykor
  GBPVR will not wake up XP computer from sleep keith_leitch 8 4,764 2011-10-10, 08:26 PM
Last Post: keith_leitch
  intermittent recording failures bcdudley 6 3,576 2011-09-28, 07:28 AM
Last Post: bcdudley
  Recording fails but only on one channel (live viewing still works) dshoup 5 3,474 2011-09-19, 01:15 AM
Last Post: sub
  Query : How to use multiple TV Cards (thru GB-PVR) in a Desktop Computer? seymoria 7 4,492 2011-09-07, 08:17 PM
Last Post: martint123
  Sattelite interent recording? crsfooddude 1 2,120 2011-07-26, 02:32 AM
Last Post: mvallevand
  Recording problem with Hauppauge Nova-S USB2 ... softfoot 4 3,341 2011-06-27, 02:06 AM
Last Post: sub
  How to kill an orphan Live TV recording? martint123 2 2,321 2011-05-16, 05:33 PM
Last Post: martint123
  SUB: Recording show in two pieces. Found bug(?) lif 10 4,994 2011-05-11, 09:30 AM
Last Post: jksmurf

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode