NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public NextPVR Support Legacy (v4.x and earlier) v
« Previous 1 … 111 112 113 114 115 … 433 Next »
HOW-TO: Keep EPG updated with OTA data via scheduled task

HOW-TO: Keep EPG updated with OTA data via scheduled task
jimt35126
Offline

Junior Member

Posts: 7
Threads: 1
Joined: Apr 2016
#1
2016-10-25, 01:31 PM
Hey, this is my first post, although I've been using NextPVR for 2-3 years, off and on. My name is Jim, I'm 65, retired/disabled, and one of my "superpowers" is getting stuff to work. Currently, I'm using NextPVR on a consumer-level Toshiba Satellite running Windows 10. I hope this post helps someone to use NextPVR more effectively. NextPVR is the best program of its type: it is so well thought-out, and generally does exactly what it needs to do.

-=-=-=-

1. Create the following batch file:

Code:
net stop "NPVR Recording Service"
"C:\Program Files (x86)\NPVR\NextPVR.exe" -updateepgonly
net start "NPVR Recording Service"

Save the file somewhere you have access, and give it a name, such as UpdateEPG.bat. You will probably need administrator-level access to perform the next step.

2. Create a scheduled task which calls this batch file 1 or more times a day. The important thing is that you change the user to SYSTEM, which will allow the net stop and net start commands to work properly. No other special attributes are needed, although I like to select the option, "Run this task on demand" for testing purposes, or if I just need to run it to update the EPG again for some reason.

(This is not a tutorial on using Task Scheduler, although you may ask any questions, and I will attempt to answer them.)

3. Finally, uncheck the options within NextPVR to auto-update the EPG at a set time, and to update the EPG during live TV. (This last is not as exciting as it sounds: it can only update the channels at the same frequency as the one you are watching, and you must watch for at least 1 minute to get it updated.)

Here are some observations about using NextPVR with a TV card or USB TV stick:

A. Your tuner can only do one thing at a time. If you are watching live TV when the background task runs, the recording service will be stopped and restarted but the EPG will not be able to update. You will not receive an error message when this happens.

B. This batch file should give you exactly the same results as manually updating the EPG from the settings, and it will take just as long. How long? 60 seconds per frequency (not per channel: a single frequency can include more than one channel). This means the update could take 10 or 15 minutes or longer depending on how many data streams are retrieved. The 60-second duration is hard-coded into the program and is a very clever way to make sure that the EPG update does not get stuck or take too long.

C. Therefore, it is up to you to decide when the task will run. You cannot record a show and update the EPG at the same time. My own task is set to run at 1:05 AM, 9:05 AM, and 5:05 PM; i.e., once every 8 hours. I have a particular channel which gives me only 10 hours of EPG, so I need more than a single daily update.

D. The concept of turning the recording service off and back on was derived from some articles in the forum archives. When the recording service turns back on, it will take a "fresh look" at your scheduling requests. This is primarily useful for recording TV series by name. Note that OTA data does not give you season and episode numbers, so the setting option to prevent duplicate recordings will not have any effect with this method. Sometimes I end up with a few duplicates of The Outer Limits, but this is no big deal. In fact, it helps, in case one of the recordings did not get good reception.

E. If you're using a USB TV stick, it may not work properly after your computer does a soft boot. You will know this when you are no longer retrieving EPG data, or cannot watch a live show. Generally, unplugging the USB stick for a few moments and then plugging it back in will do the trick. Then you can run the task on demand (if you selected that option when setting up the task).

F. This is cool: there is one exception to not being able to watch live TV while also recording a program: when the channel you wish to watch is on the same frequency as the channel recording, you can do both! The tray icon will turn red whenever you are recording a show or running NextPVR.
mvallevand
Offline

Posting Freak

Ontario Canada
Posts: 52,943
Threads: 956
Joined: May 2006
#2
2016-10-25, 03:08 PM
When the service starts I doesn't do a full re-schedule, it just check the currently scheduled events so I don't think it does what you want.

Schedules Direct is so cheap it is hard to recommend any ATSC OTA task scheduling approach, no matter how well thought out.

Martin
jimt35126
Offline

Junior Member

Posts: 7
Threads: 1
Joined: Apr 2016
#3
2016-10-25, 03:21 PM
mvallevand Wrote:When the service starts I doesn't do a full re-schedule, it just check the currently scheduled events so I don't think it does what you want.

Schedules Direct is so cheap it is hard to recommend any ATSC OTA task scheduling approach, no matter how well thought out.

Martin

If the station has changed the broadcast time for a series, I do think that the recording times will be updated to match. Schedules Direct appears to be a very nice service. I'm not quite ready to dive into XML files and such. Thank you for reading my post and for your comments.

~Jim
Graham
Offline

Posting Freak

UK
Posts: 4,058
Threads: 102
Joined: Dec 2005
#4
2016-10-25, 03:40 PM
I do my EPG updates using a batch file and task scheduler ... I have a ... "C:\Program Files (x86)\NPVR\NextPVR.exe" -emptyepgonly ... before the -updateepgonly ... Plus, I don't stop and start the recording service and everything works as expected ... I suspect that the stop and start are redundant.
mvallevand
Offline

Posting Freak

Ontario Canada
Posts: 52,943
Threads: 956
Joined: May 2006
#5
2016-10-25, 04:22 PM
jimt35126 Wrote:If the station has changed the broadcast time for a series, I do think that the recording times will be updated to match. Schedules Direct appears to be a very nice service. I'm not quite ready to dive into XML files and such. Thank you for reading my post and for your comments.

~Jim

Right but the premise of your logic is there is not enough data at the update time to care through the day so there may may be nothing to reschedule.

NextPVR's SD support is built in you just need an account and do the mapping.

Martin
mvallevand
Offline

Posting Freak

Ontario Canada
Posts: 52,943
Threads: 956
Joined: May 2006
#6
2016-10-25, 04:24 PM
Graham Wrote:I do my EPG updates using a batch file and task scheduler ... I have a ... "C:\Program Files (x86)\NPVR\NextPVR.exe" -emptyepgonly ... before the -updateepgonly ... Plus, I don't stop and start the recording service and everything works as expected ... I suspect that the stop and start are redundant.

Totally different scenario where with ATSC since on some channels we are lucky to get now/next data.

Martin
dixxfixx
Offline

Member

Posts: 149
Threads: 5
Joined: Nov 2007
#7
2016-10-25, 07:41 PM
SD is great, and I wouldn't use anything else. But for my brother, who apparently lives in a cave, and has no interwebs, I did something very much like this. We had to schedule it four times a day because OTA EPG in Dallas is so bad.
WinXP SP3 A8V-X Athlon 64 FX-60 2.60GHz 2GB
NextPVR 3.4.8
NYPlayer
Offline

Senior Member

Posts: 308
Threads: 22
Joined: Aug 2014
#8
2016-10-25, 10:02 PM
This is what I use to update the EPG it checks to make sure nothing is recording or anyone is watching. You can also removehistory or empty the epg.

updateepg.bat

Code:
CD /d "%~dp0"
:loop
set chknpvr=1
"c:\Program Files (x86)\NPVR\NScriptHelper.exe" -isInUse | find "NOT RECORDING"
set chknpvr=%ERRORLEVEL%
if %chknpvr% NEQ 0 timeout 300
if %chknpvr% NEQ 0 goto loop
rem if %chknpvr% EQU 0 "C:\Program Files (x86)\NPVR\NextPVR.exe" -removehistory
rem if %chknpvr% EQU 0 "C:\Program Files (x86)\NPVR\NextPVR.exe" -emptyepgonly
if %chknpvr% EQU 0 "C:\Program Files (x86)\NPVR\NextPVR.exe" -updateepgonly
Exit
NEXTPVR Server Acer AM3910-UR10P Intel Core i3-540 3.06GHz Desktop, Windows 8.1 Pro. 64bit, 2 HdHomerun units(OTA Tuners) , 1 HD Homerun Prime , for a total of 7 HD Tuners , LinkSYS 16 port Gigabyte Switch.
D-link 857 Router
mvallevand
Offline

Posting Freak

Ontario Canada
Posts: 52,943
Threads: 956
Joined: May 2006
#9
2016-10-25, 10:07 PM
Emptying the guide isn't recommended if you use SD. EPG items are hashed and they are supposed to only get updated when changed according to the API spec. There is some safety there as it avoids problems if SD isn't reachable for any reason at EPG update time.

Martin
NYPlayer
Offline

Senior Member

Posts: 308
Threads: 22
Joined: Aug 2014
#10
2016-10-25, 10:13 PM
mvallevand Wrote:Emptying the guide isn't recommended if you use SD. EPG items are hashed and they are supposed to only get updated when changed according to the API spec. There is some safety there as it avoids problems if SD isn't reachable for any reason at EPG update time.

Martin

Agree 100%
NEXTPVR Server Acer AM3910-UR10P Intel Core i3-540 3.06GHz Desktop, Windows 8.1 Pro. 64bit, 2 HdHomerun units(OTA Tuners) , 1 HD Homerun Prime , for a total of 7 HD Tuners , LinkSYS 16 port Gigabyte Switch.
D-link 857 Router
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (2): 1 2 Next »


Possibly Related Threads…
Thread Author Replies Views Last Post
  No data received jcole998 1 264 2025-04-15, 03:08 PM
Last Post: mvallevand
  Auto Update EPG not running as scheduled? BairStrokes 2 1,722 2021-03-26, 12:02 PM
Last Post: NumberFive
  Automation EPG Updates not being scheduled NumberFive 4 2,125 2021-03-22, 02:27 PM
Last Post: NumberFive
  Recording service stopped or not running at scheduled time MattInetroit 3 1,882 2021-01-08, 12:03 AM
Last Post: mvallevand
  Auto Update EPG not running as scheduled Bobbybear 10 3,591 2020-10-24, 09:24 AM
Last Post: Bobbybear
  No data delivered/failed to lock a signal? from Hauppauge HDHR/DCR-2650 bishoph 8 3,617 2020-04-13, 09:55 PM
Last Post: sub
  OTA EPG guide data only for 2 hrs acegolfer 6 3,601 2020-03-18, 08:30 PM
Last Post: mvallevand
  Channles loosing EPG data Brucek2839 5 2,299 2019-11-21, 03:17 AM
Last Post: mvallevand
  Free view updated channels spudjg1 9 3,110 2019-10-20, 01:41 PM
Last Post: spudjg1
  HDHR Recordings Include Data From Wrong Channel During Post-Padding BrettB 2 5,216 2019-10-12, 05:34 PM
Last Post: mvallevand

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

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

Linear Mode
Threaded Mode