Shop OBEX P1 Docs P2 Docs Learn Events
Using the Spinneret to send weather station data to weather underground — Parallax Forums

Using the Spinneret to send weather station data to weather underground

kf4ixmkf4ixm Posts: 529
edited 2011-01-30 07:23 in Accessories
Hi all i have been reading some about the spinneret web server, but haven't found anything about someone using it to send weather station data to weather underground for personal weather stations. According to the wunder wiki found here, it uses the HTTP GET method to send/upload the pws data to the wunderground servers using a string formatted like this...
http://rtupdate.wunderground.com/weatherstation/updateweatherstation.php?ID=KCASANFR5&PASSWORD=XXXXXX&dateutc=2000-01-01+10%3A32%3A35&winddir=230&windspeedmph=12&windgustmph=12&tempf=70&rainin=0&baromin=29.1&dewptf=68.2&humidity=90&weather=&clouds=&softwaretype=vws%20versionxx&action=updateraw&realtime=1&rtfreq=2.5

Is the spinneret capable of "pushing" a string, like above, to a server? has anyone done anything like this that could share some examples on sending pws data?

Thanks in advance!

Comments

  • zoopydogsitzoopydogsit Posts: 174
    edited 2011-01-23 14:33
    From looking at your example it's only HTTP and not needing to negotiate TLS then it should be quite do-able. Have a look at some of the other coding examples in this forum.

    I glanced at the wiki, and it would appear that it's a plain text (not secure) password. Even if they did some kind of hashing then their are some crypto related objects in OBEX there is an RC4, MD5, and AES, that may help a solution.

    If you have a weather station, then why not buy a Spinneret, join the competition, submit a request and post your project. As the competition is collaborative then you are likely to get help from other forum members if you ask for help and post your code.

    From looking at it, go for it!
  • kf4ixmkf4ixm Posts: 529
    edited 2011-01-23 14:43
    Okay, thanks for the reply! i had read through some of the examples, but didn't see anything about sending an http request, or either i simply overlooked it. i will go back and look again. and yes i do plan on getting a spinneret soon. my weather station is still on the workbench right now, but i plan on getting it done soon and will post schematics and code. it's in the hardware only stage now, i really haven't done any coding yet, other than sensor testing and i/o.
  • zoopydogsitzoopydogsit Posts: 174
    edited 2011-01-23 15:12
    You won't find a specific code example for sending a HTTP datagram, however there are other coding examples showing successful web page display. I would suspect that sending a datagram would not be that hard. Again, your likely to get help here. Remember the competition is about collaboration.

    It sounds like a good use of the Spinneret. Though you'd only be using the TCP/IP portion. You may also want to consider writing the same data to a file on the SD Card with data from the RTC and display the content on a web page to show long term weather history. For example when on holidays you could check to see how your garden is going from, how much rainfall, temperature and humidity.

    BTW. I have a WS-3600 weather station here. It beloned to a relative that used it in standalone mode. I'm yet to see if it does serial comms. If so I may look in on your project.
  • kf4ixmkf4ixm Posts: 529
    edited 2011-01-23 15:21
    you'll be happy to know that the ws-3600 does do serial comms, :) Thank you for all your input. i will definantly have to get me one soon so i can start playing with it, i doubt it will be in time for the contest though.
  • ohararpohararp Posts: 24
    edited 2011-01-28 15:08
    I am definitely interested in this as www.thingspeak.com offers similar services via http post
  • $WMc%$WMc% Posts: 1,884
    edited 2011-01-28 17:52
    kf4ixm wrote: »
    Hi all i have been reading some about the spinneret web server, but haven't found anything about someone using it to send weather station data to weather underground for personal weather stations. According to the wunder wiki found here, it uses the HTTP GET method to send/upload the pws data to the wunderground servers using a string formatted like this...
    http://rtupdate.wunderground.com/weatherstation/updateweatherstation.php?ID=KCASANFR5&PASSWORD=XXXXXX&dateutc=2000-01-01+10%3A32%3A35&winddir=230&windspeedmph=12&windgustmph=12&tempf=70&rainin=0&baromin=29.1&dewptf=68.2&humidity=90&weather=&clouds=&softwaretype=vws%20versionxx&action=updateraw&realtime=1&rtfreq=2.5
    

    Is the spinneret capable of "pushing" a string, like above, to a server? has anyone done anything like this that could share some examples on sending pws data?

    Thanks in advance!
    '
    '
    How do you eat an elephant? one byte at a time.
    '
    Have you tried to Parse out the "date,winddri,speed,temp,rain,and bars of pressure" one at a time?
  • Mike GMike G Posts: 2,702
    edited 2011-01-29 05:51
    Sending Spinneret HTTP requests.
    http://forums.parallax.com/showthread.php?127619-Help-using-the-Spinneret-as-a-Client

    You will need to find the IP of the URL and send a properly formatted header. There is also a client demos with Tim's driver download. So, if you have the driver you probably already have the client demo.
  • wrightmewrightme Posts: 43
    edited 2011-01-30 07:23
    You won't find a specific code example for sending a HTTP datagram, however there are other coding examples showing successful web page display. I would suspect that sending a datagram would not be that hard. Again, your likely to get help here. Remember the competition is about collaboration.

    It sounds like a good use of the Spinneret. Though you'd only be using the TCP/IP portion. You may also want to consider writing the same data to a file on the SD Card with data from the RTC and display the content on a web page to show long term weather history. For example when on holidays you could check to see how your garden is going from, how much rainfall, temperature and humidity.

    BTW. I have a WS-3600 weather station here. It beloned to a relative that used it in standalone mode. I'm yet to see if it does serial comms. If so I may look in on your project.

    Interesting!
    I have the WS-2308, using serial, HeavyWeather and VWS to send to my website on a hosting service. The HW software has a rudimentary ftp method to send data after receiving it from the WS, but VWS is more configurable, and latches on to the HW stuff to send it up.
    I have not explored the data stream at all, but I would not be surprised if it is useable somehow.
Sign In or Register to comment.