NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Developers v
« Previous 1 … 39 40 41 42 43 … 93 Next »
Over-the-air channels with Yahoo/API

 
  • 0 Vote(s) - 0 Average
Over-the-air channels with Yahoo/API
jldet5
Offline

Member

Posts: 96
Threads: 8
Joined: Apr 2007
#21
2007-07-14, 07:52 PM (This post was last modified: 2007-07-14, 08:08 PM by jldet5.)
Thanks; that makes sense!


Next problem. The time offset is stuck on -06:00. I'm not sure if GBPVR expects no offset at all and then compensates based on the time zone as set by the computer of if it needs to be done manually.

Should the offset be set to +0000 or UTC ?
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#22
2007-07-14, 08:23 PM
jldet5 Wrote:Thanks; that makes sense!


Next problem. The time offset is stuck on -06:00. I'm not sure if GBPVR expects no offset at all and then compensates based on the time zone as set by the computer of if it needs to be done manually.

Should the offset be set to +0000 or UTC ?
I was using "UTC" but for some reason it resulted in the guide being an hour off. Switching it to "+0000" makes it work correctly.
jldet5
Offline

Member

Posts: 96
Threads: 8
Joined: Apr 2007
#23
2007-07-14, 08:54 PM
Looks like the offset is not being written to the XML file. This will be a problem for getting the EPG guide data on the right time along with DST changes?
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#24
2007-07-14, 09:24 PM
I convert the times to UTC from the database then add the offset.
Here's the c# code I use. (The offset is a variable because I allow it to be overridden from the command line.)
Code:
string offset = "+0000";
DateTime progStartTime = program.StartTime.ToUniversalTime();
DateTime progStopTime = program.EndTime.ToUniversalTime();
progStart.Value = string.Format(CultureInfo.InvariantCulture, "{0:yyyyMMddHHmmss} {1}", progStartTime, offset);
progStop.Value = string.Format(CultureInfo.InvariantCulture, "{0:yyyyMMddHHmmss} {1}", progStopTime, offset);
I can't remember if the times in the zip files are UTC or not since I am actually puling the data from the Go 4 TV database, so you may not have to perform the ToUniversalTime().
Squid
Offline

Member

Posts: 72
Threads: 14
Joined: May 2005
#25
2007-07-16, 04:30 AM (This post was last modified: 2007-07-16, 05:47 AM by Squid.)
Big thanks from me, this is exactly what I needed, and I don't think it could work any better.

Thanks!

Squid

Edit:

Hey, the times are off an hour! I figured since I was CST I would be okay. Guess not.
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#26
2007-07-16, 07:40 PM
jldet5 Wrote:Looks like the offset is not being written to the XML file. This will be a problem for getting the EPG guide data on the right time along with DST changes?
You can have GB-PVR offset the epg for you in this case. In the config where you specify the XML file, there is an option to adjustthe offset.
Squid
Offline

Member

Posts: 72
Threads: 14
Joined: May 2005
#27
2007-07-16, 07:41 PM
I don't know if the output results are acceptable to gbpvr or not ( I'll test it when I get home tonight ). Attached is a little perl script that moves the stop and start times forward 1 hour. At least it looks like it does to me. If this actually works ( and anybody wants me to ) then I'll make the hardcoded filenames and +10000 command line arguments and make an executable.

---
#!perl
use XML::Simple;

my $tvlist = XMLin('OverTheAir.xml');

foreach my $prog (@{$tvlist->{'programme'}}) {
$prog->{'stop'} = $prog->{'stop'} + 10000;
$prog->{'start'} = $prog->{'start'} + 10000;
}

open OUTFILE,(">outfile.xml");
print OUTFILE XMLout($tvlist);
---

Before:
--
<programme start="20070715180000" stop="20070715190000" channel="5">
<title>Nature</title>
<sub-title>Kalahari: The Flooded Desert</sub-title>
<desc>The Kalahari Desert's Okavango Delta from the point of view of crocodiles and eagles.</desc>
<category>Anthology</category>
<category>Nature</category>
<category>Series</category>
<rating system="VCHIP"><value>TVG</value></rating>
</programme>
--
After
--
<programme channel="5" desc="The Kalahari Desert's Okavango Delta from the point of view of crocodiles and eagles." start="20070715190000" stop="20070715200000" sub-title="Kalahari: The Flooded Desert" title="Nature">
<category>Anthology</category>
<category>Nature</category>
<category>Series</category>
<rating system="VCHIP" value="TVG" />
</programme>
--


Squid
Squid
Offline

Member

Posts: 72
Threads: 14
Joined: May 2005
#28
2007-07-16, 07:43 PM
whurlston Wrote:You can have GB-PVR offset the epg for you in this case. In the config where you specify the XML file, there is an option to adjustthe offset.


Tried that, it appeared to ignore my setting. Tried the empty button, then the reload button.

I tried + and - numbers, it didn't have any effect.

Squid
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#29
2007-07-16, 08:36 PM
Instead of moving the times ahead one hour, I would simply try adding the "+0000" to the start and stop times.
jldet5
Offline

Member

Posts: 96
Threads: 8
Joined: Apr 2007
#30
2007-07-16, 09:46 PM
Squid Wrote:Tried that, it appeared to ignore my setting. Tried the empty button, then the reload button.

I tried + and - numbers, it didn't have any effect.

Squid

Same for me.
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (9): « Previous 1 2 3 4 5 … 9 Next »
Jump to page 


Possibly Related Threads…
Thread Author Replies Views Last Post
  is there a service?method which returns listings for multiple channels? reven 16 7,383 2022-04-11, 04:30 PM
Last Post: mandai
  Channels List by Channel Group Name scJohn 1 2,842 2018-01-05, 10:45 PM
Last Post: mvallevand
  Switching Audio Channels spitefulgod 0 2,070 2016-12-15, 08:42 PM
Last Post: spitefulgod
  Merged channels mvallevand 3 2,756 2014-04-11, 04:55 AM
Last Post: mvallevand
  Scan for channels programmatically or via command prompt? reven 12 5,499 2013-03-08, 05:01 AM
Last Post: reven
  Non-broadcasting channels imilne 16 6,463 2011-07-02, 04:31 PM
Last Post: sub
  Recording without mapped channels. mvallevand 11 4,264 2009-09-06, 05:09 AM
Last Post: mvallevand
  Switch Channels in Inset JavaWiz 2 1,696 2008-07-27, 06:03 AM
Last Post: JavaWiz
  mapping satellite channels to EPG kainat 26 10,541 2008-02-19, 01:49 PM
Last Post: kainat
  Yahoo Go TV to XMLTV (via API) -Oz- 216 77,837 2007-09-14, 09:26 PM
Last Post: whurlston

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

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

Linear Mode
Threaded Mode