Author Topic: Developing a Weather Plugin, videos  (Read 102526 times)

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5549
  • DOES work for LinuxMCE.
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #75 on: February 09, 2015, 04:43:21 pm »
Guys, you can capture all the radar data from weather.com.

If you look in MythWeather's source tree, there is an XML file (maps.xml), that contains all the known radar imagery.

It just needs to be mapped.

-Thom

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #76 on: February 11, 2015, 03:08:09 pm »
I'm not real happy with the accuracy of the data coming from WorldWideWeather.com or other world wide weather APIs. The USA has a free accurate service with NOAA.

Marie.O

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 3676
  • Wastes Life On LinuxMCE Since 2007
    • View Profile
    • My Home
Re: Developing a Weather Plugin, videos
« Reply #77 on: February 11, 2015, 05:33:18 pm »
Does NOAA cover only the US? I prefer a not perfect weather service that covers my location over a weather service that does accurately cover only other locations. ;)

phenigma

  • LinuxMCE God
  • ****
  • Posts: 1758
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #78 on: February 11, 2015, 05:39:56 pm »
As posde mentions, our users are worldwide and a service that presents data worldwide is the goal.  If someone wishes to extend that to permit multiple data providers that would be even better  ;D

J.

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #79 on: February 11, 2015, 05:48:44 pm »
Only the US. I suppose there could be more than 1.

For accuracy right now World weather had me at "Partly Cloudy, 19F" and it is overcast moderate snow and 27F. Also there is no detailed forecast.

Accuweather looks better but cost $$.

I'm working on a NOAA version now but could easily be modified to any API.

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #80 on: February 11, 2015, 05:54:06 pm »
Sorry J didn't see your post. I'm not sure I could do multiple data sources as it may be beyond me. Each service references data differently.

phenigma

  • LinuxMCE God
  • ****
  • Posts: 1758
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #81 on: February 11, 2015, 10:19:17 pm »
Right now, I envisions something simple, like a webadmin page that allows the user to select an appropriate source.  Perhaps each source is a different script, say.  Then the webadmin selection activates/deactivates the appropriate scripts.  Others may have input into this, but atm that seems the easiest.  Otherwise a source that covers everyone would be ideal.  My $0.02.

J.

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #82 on: February 12, 2015, 10:22:20 pm »
Hi J

I am putting together a NOAA addition to your Weather device. I can also do a Open World wide something version as well with maybe an option to select the version. The problem with most of the good, free APIs is they want their logo showing. Any suggestions for that?  I know it is selfish but for the USA the NOAA data is the best so I think having options is looking like the way to go. Thoughts there?

I am almost done with the code and will send it to you if that's ok?

Thanks

Jim

phenigma

  • LinuxMCE God
  • ****
  • Posts: 1758
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #83 on: February 13, 2015, 12:10:42 am »
SBCC: Yes please!  :D  I'd rather have (than have not).

cfernandes: I'm still looking for some guidance on how I use the script you provided.  I'm not sure what I should do with it/where it should be put.  Is it a standalone script that runs?  Or is it a part of webadmin?

I'm happy to help incorporate this into the system.  I expect we can work out a way to deal with multiple data sources easily.

How do each of your methods work?  Do they poll for weather?  If so at what interval?  Is the interval selectable?  How do we set our locations?  Or can we yet?

If we need a webadmin page to help configure then that can be worked on as well.

You guys tell me what is required and I'll work with you to make it happen/alter requirements as needed, etc...

J.

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #84 on: February 13, 2015, 01:23:28 am »
Hi Jason

Right now I am creating the methods to load the data. I suppose we could have the user select a polling interval. Locations I was getting from "SELECT `Zip` FROM `Installation`" but I'm thinking that should be confirmed or having that as default but then can be changed.

Methods can be selected with a user selection like
Code: [Select]
if(NOAA) {
 Get_NOAA_DATA();
} else...

cfernandes

  • Guru
  • ****
  • Posts: 359
    • View Profile
    • my company web site
Re: Developing a Weather Plugin, videos
« Reply #85 on: February 14, 2015, 12:46:06 pm »
Hi J.

I think we could have a script for each data source, and one page in webadmin to configure which we would like, and include your own key api when needed, and also the time interval.

 I believe that the information in the table pluto_main.installation covers all data necessary for the pursuit of climate data.

in my case I can not use the zip. not all sites are located just by zip

 I'm running in cron with every 8 hours

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #86 on: February 16, 2015, 09:50:41 pm »
Hi

I have a working device in C++ for NOAA only right now. Other APIs can be added as well and I will probalby start looking into others. It does use curl and jsoncpp. I made use of the Configuration Script data already on the template. Uses are "API:??,lat:??,lon:??,units:??,lang:??". Right now only "API:NOAA" works for API. "units:0" is imperial of deg F. "units:1" is metric but right now the text add "F" to the unit. I will fix that. "lang:english" is english, not sure about others but worth trying whatever. I am still testing but if anyone is interested I could get you the code or binary.

Is there any way to add a "Info By" area to the orbiter so APIs that require that can be used?

Thanks

Jim
 

cfernandes

  • Guru
  • ****
  • Posts: 359
    • View Profile
    • my company web site
Re: Developing a Weather Plugin, videos
« Reply #87 on: February 17, 2015, 12:39:33 pm »
Hi jim,
you can share the code with me, i can help integrate other api.

Carlos Fernandes

SBCC

  • Guru
  • ****
  • Posts: 164
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #88 on: February 17, 2015, 11:57:21 pm »
Hi Carlos

I am making some changes. I'm trying to add some mutexes and I'm working through how LMCE handles those. I need one for curl and one for the the message sender. Give me a little bit.

Thanks for helping

Jim

phenigma

  • LinuxMCE God
  • ****
  • Posts: 1758
    • View Profile
Re: Developing a Weather Plugin, videos
« Reply #89 on: February 18, 2015, 02:04:57 am »
Sounds like great stuff so far guys!  Keep up the great work!

J.