SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Studio
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Studio Discussion related to the SageTV Studio application produced by SageTV. Questions, issues, problems, suggestions, etc. relating to the Studio software application should be posted here.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 05-29-2010, 08:18 PM
MeInMaui's Avatar
MeInMaui MeInMaui is offline
SageTVaholic
 
Join Date: Feb 2005
Location: Maui. HI
Posts: 4,203
Question Weather api documentation

Is there a javadoc available for the weather api used in the default stv? Thanks.

Aloha,
Mike
__________________
"Everything doesn't exist. I'm thirsty." ...later... "No, it's real!!! I'm full."
- Nikolaus (4yrs old)
Reply With Quote
  #2  
Old 05-30-2010, 07:45 AM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
I'm only guessing, but I'd imagine it uses the RSS APIs in the core? I think it's just an RSS feed used. Again, that's just a guess though.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
Reply With Quote
  #3  
Old 06-02-2010, 12:41 PM
Opus4's Avatar
Opus4 Opus4 is offline
Administrator
 
Join Date: Sep 2003
Location: NJ
Posts: 19,624
Below is a list of the weather API calls used by SageTV.

Important
Use of these API calls requires abiding by the terms set by weather.com, the source of this weather information used by SageTV. This means that each weather related screen in SageTV must display the sponsor links and credits, as the default STV does at the bottom of every weather menu.

You do not need to worry about how often the data is downloaded from weather.com because these calls already track the last-update times and only get the updated RSS feed info as needed.

These calls are not designed to track multiple locations at once.

Quote:
Usage of weather API calls for SageTV integration in the Studio:

First get an instance of this class using:
Weather = tv_sage_weather_WeatherDotCom_getInstance()

Then you can set the units/locationID using:
tv_sage_weather_WeatherDotCom_setUnits(Weather, "s")
tv_sage_weather_WeatherDotCom_setLocationID(Weather, "USCA0924")

You can search for location IDs this way, its returns a java.util.Map of Names to LocationIDs:
tv_sage_weather_WeatherDotCom_searchLocations(Weather, "Chicago")

To cause an update to occur (it respects caching, returns a boolean):
tv_sage_weather_WeatherDotCom_updateNow()

To Get more info:
tv_sage_weather_WeatherDotCom_getLocationID(Weather)
tv_sage_weather_WeatherDotCom_getUnits(Weather)
tv_sage_weather_WeatherDotCom_getLastError(Weather)
tv_sage_weather_WeatherDotCom_getLocationProperties(Weather) returns a Map
tv_sage_weather_WeatherDotCom_getCurrentConditionProperties(Weather) returns a Map
tv_sage_weather_WeatherDotCom_getForecastProperties(Weather) returns a Map
tv_sage_weather_WeatherDotCom_getSponsorProperties(Weather) returns a Map
tv_sage_weather_WeatherDotCom_getLocationInfo(Weather, String property) returns a String
tv_sage_weather_WeatherDotCom_getCurrentCondition(Weather, String property) returns a String
tv_sage_weather_WeatherDotCom_getForecastCondition(Weather, String property) returns a String
tv_sage_weather_WeatherDotCom_getSponsorLinks(Weather, String property) returns a String
tv_sage_weather_WeatherDotCom_getLastUpdateTime(Weather)
tv_sage_weather_WeatherDotCom_isCurrentlyUpdating(Weather)
- Andy
__________________
SageTV Open Source v9 is available.
- Read the SageTV FAQ. Older PDF User's Guides mostly still apply: SageTV V7.0 & SageTV Studio v7.1.
- Hauppauge remote help: 1) Basics/Extending it 2) Replace it 3) Use it w/o needing focus
- HD Extenders: A) FAQs B) URC MX-700 remote setup
Note: This is a users' forum; see the Rules. For official tech support fill out a Support Request.
Reply With Quote
  #4  
Old 06-02-2010, 12:58 PM
jaminben jaminben is offline
Sage Icon
 
Join Date: Sep 2007
Location: Norwich, UK
Posts: 1,754
Send a message via MSN to jaminben
Quote:
Originally Posted by Opus4 View Post
Use of these API calls requires abiding by the terms set by weather.com, the source of this weather information used by SageTV. This means that each weather related screen in SageTV must display the sponsor links and credits, as the default STV does at the bottom of every weather menu.
Heh, that's a pain as its something I didn't do in the Ortus STV. I assume that its something I need to add or can I get away with it as its a user created STV and something thats not officially supported by SageTV?

Cheers

Ben
__________________
Server - Win7 64bit, 2.4Ghz Intel Core 2 Duo, TBS 6284 PCI-E Quad DVB-T2 Tuner, 3 x HD200 & 1 x HD300 extenders
Reply With Quote
  #5  
Old 06-02-2010, 01:26 PM
MeInMaui's Avatar
MeInMaui MeInMaui is offline
SageTVaholic
 
Join Date: Feb 2005
Location: Maui. HI
Posts: 4,203
I'm pretty sure you can't get away with it. I'm adding the required stuff to the phoenix weather screen, but we're also evaluating other potential weather data sources.

Aloha,
Mike
__________________
"Everything doesn't exist. I'm thirsty." ...later... "No, it's real!!! I'm full."
- Nikolaus (4yrs old)
Reply With Quote
  #6  
Old 06-02-2010, 01:30 PM
jaminben jaminben is offline
Sage Icon
 
Join Date: Sep 2007
Location: Norwich, UK
Posts: 1,754
Send a message via MSN to jaminben
Actually the code is in there along with the images but I guess theirs a bug somewhere which is why its not showing on screen. Unfortunately there's just not enough hours in the day to locate and fix it......maybe one day it'll work as it was intended to

Cheers

Ben
__________________
Server - Win7 64bit, 2.4Ghz Intel Core 2 Duo, TBS 6284 PCI-E Quad DVB-T2 Tuner, 3 x HD200 & 1 x HD300 extenders
Reply With Quote
  #7  
Old 06-02-2010, 01:38 PM
Opus4's Avatar
Opus4 Opus4 is offline
Administrator
 
Join Date: Sep 2003
Location: NJ
Posts: 19,624
If you are using the SageTV weather calls, then you are using SageTV's key and must therefore abide by weather.com's rules so that the built-in calls are not in violation of their terms. If you use SageTV's key & violate their terms, you put our weather data access at risk.

If you use your own key from weather.com, you can flout their rules at your own risk of having your key canceled.

I think the SageTV weather calls are based on source from nielm. That code may still be floating around somewhere & you could modify it to work the way you want.

- Andy
__________________
SageTV Open Source v9 is available.
- Read the SageTV FAQ. Older PDF User's Guides mostly still apply: SageTV V7.0 & SageTV Studio v7.1.
- Hauppauge remote help: 1) Basics/Extending it 2) Replace it 3) Use it w/o needing focus
- HD Extenders: A) FAQs B) URC MX-700 remote setup
Note: This is a users' forum; see the Rules. For official tech support fill out a Support Request.
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Using Weather Network as a feed for Canadian Weather Fastrack SageTV Customizations 2 03-22-2009 09:47 PM
Wunderground Weather instead of Weather.com??? Stuntman SageTV Customizations 9 02-03-2009 05:22 PM
weather.com weather extractor for mlbdude2 1.8.7 (v1.0.1 / July 6) nielm SageTV Customizations 105 10-08-2004 06:54 AM


All times are GMT -6. The time now is 12:16 PM.


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