Escolar Documentos
Profissional Documentos
Cultura Documentos
WeatherSnoop
Version 2.1.5
Contact Information
Tee-Boy 441 Saint Paul Avenue Opelousas, Louisiana 70570 Web: www.tee-boy.com Email: info@tee-boy.com
Support Information
We enjoy hearing from our customers, so if you have any questions or would like to give feedback on WeatherSnoop, please contact us at: support@tee-boy.com. We do our best to respond to inquiries in a timely fashion. Our on-line forums at http://www.tee-boy.com/forums contains additional support infor- mation and contributions from other WeatherSnoop users. Please be sure and visit this great resource for additional information.
Table of Contents
1 Introduction .............................................................10
WeatherSnoop vs. WeatherSnoop Lite .........................................10 How To Use This Users Guide .....................................................11 Whats Next? ...........................................................................11
Davis Vantage Pro/Vue..............................................................16 Oregon Scientic WMR100N.......................................................17 Oregon Scientic WMR200A .......................................................17 Oregon Scientic WMR968 .........................................................17 Peet Bros. ULTIMETER 100/800/2000/2100 .................................17 RainWise MKIIICC-LR ................................................................17 RainWise CC-3000 ....................................................................18 LaCrosse WS-2315 ...................................................................18 WS-1080/WS-2080...................................................................18 iROX Pro-X/Honeywell TE923 .....................................................18 Columbia Weather Capricorn 2000EX ..........................................18 Columbia Weather MicroServer...................................................19 WeatherSnoop XML Feed ...........................................................19 Weather Underground Website ...................................................19 Whats Next? ...........................................................................19
Using a Web Browser ................................................................25 Obtaining Weather Data via XML or JSON ....................................26 Sharing via FTP ........................................................................26 Archiving to the Database ..........................................................27 Whats Next? ...........................................................................27
Oregon Scientic WMR968 .........................................................57 LaCrosse WS-2315 ...................................................................58 WS-1080/WS-2080...................................................................59 IROX Pro-X/HoneyWell TE923 ....................................................60 RainWise MKIIICC-LR Interface ..................................................61 RainWise CC-3000 Interface ......................................................62 Peet Bros. ULTIMETER 100/800/2000/2100 .................................63 WeatherHawk Weather Station ...................................................64 Columbia Weather Systems Capricorn 2000EX .............................65 Columbia Weather Systems MicroServer ......................................66
Determining the License Type ....................................................70 Logging with the TBLog Class ....................................................71
1 Introduction
Congratulations on purchasing WeatherSnoop, the premiere weather station data man- agement software for Apple's Macintosh family of computers. WeatherSnoop adheres to the Macs core philosophy of providing a rich, elegant, and easy-to-navigate user inter- face; at the same time, it contains an abundant and robust set of features to help you get the most out of your weather data. WeatherSnoop has two main roles: rst, it acts as a consumer, collecting weather data from either a personal weather station or an Internet-based data source. Second, it can also act as a data provider, relaying your weather to popular online data services such as Weather Underground, WeatherBug and the Citizen Weather Observer Program (CWOP), or serve data to other interested applications via HTTP or FTP These capabilities make WeatherSnoop a powerful, centralized data management system for your weather infor- mation. At the heart of WeatherSnoop is the agent, an intelligent piece of software which under- stands how to connect and communicate to a weather source to obtain weather data. A weather source can be a weather station connected to your Mac via a USB or RS-232 ca- ble, or even a weather station accessible on your local area network or over the Internet. In fact, WeatherSnoop has support for over a dozen popular weather stations and weather information services, so there are many options to choose from.
10
Whats Next?
In the next section, well look at some specics of setting up a weather station, including connectivity issues related to your Mac. If you havent set up your weather station yet, now would be a good time to go over its instruction manual and perform the installation.
11
Setting Things Up
Virtually every weather station that is supported by WeatherSnoop has a manual avail- able, either with the station or obtainable over the Internet. We highly suggest that you take the time to read the manual for your particular station. You should use the stations instruction manual to determine where to optimally place your weather instruments, how to setup the station console and verify that the station is in working order, and run tests to ensure that all sensors are set up and working properly.
We advise customers to avoid using any RS-232 to USB adapter that uses the Pro- lic chipset. Adapters using this chipset have traditionally been unreliable. If you havent already installed the driver for either of these adapters, just go to Weath- erSnoops Help Menu and choose the menu option to be taken to the manufacturers web page. Once there, you can download and install the driver.
Whats Next?
By now you should have read your stations instruction manual and have set everything up. In the next section, well introduce you to WeatherSnoop. There, youll set up your site information and choose your weather source.
13
Launching WeatherSnoop
Now it is nally time to launch WeatherSnoop! To do so, simply double-click the Weath- erSnoop icon in your Applications folder, or single-click the icon in your dock if you pur- chased it from the Mac App Store. When launching it for the rst time, a hint box will ap- pear, along with the Agent window.
appears and the Stop button is shown. Clicking the Start button will start the agent and it will begin communicating to your data source; likewise, clicking on the Stop button will stop the agent and allow you to make changes to your settings.
14
The logging area (which can be hidden by clicking on the disclosure triangle) is also visi- ble to show the status of the agent while it is running. The Log Level slider allows you to adjust the amount of information that the log area shows, which can be helpful for de- bugging. Buttons are also available to clear the contents of the log area, copy the con- tents into the global copy buer, or email the contents. NOTE: You can only change options and settings in the Agent Win- dow when the Agent is stopped.
If you dont know the coordinates of your location, we recommend the tutorial on this site, which shows how to use Google Maps to nd it: http://www.labnol.org/internet/tools/nd-latitude-longitude-from-address-google-maps/ 1691/
15
Once youve set this information, just click on the globe icon; a browser will open and take you to your location in Google Maps.
Select the Source tab in the Agent window; there you will see a popup button which al- lows you to select one of the many supported weather sources. When a weather source is selected, a representing image appears, along with all of the available options for that source. Here are the possible selections for the weather source:
3. WeatherLink Serial Data Logger: for this logger, you will need to have an RS-232 to USB adapter and install the appropriate driver, then select the device name from the pop-up list. The Davis Vantage Pro/Vue Agent supports the retrieval of archived records stored in the station. You can turn on this feature by checking the option to obtain the archived records. Additionally, you can check the option to clear the archived data in the sta- tions memory after a successful retrieval of all of the archived data. If your rain bucket has the 0.2mm setting (UK and EUR users), then check that option so that rain values will be correctly measured.
RainWise MKIIICC-LR
This option will obtain all sensor values expected on the RainWise MKIIICC-LR. You will need to select the RS-232 device that the station is connected to. If you have an RS-232 to Network adapter, select TCP/IP as the device and enter its network address and port number.
17
RainWise CC-3000
This option will obtain all sensor values expected on the RainWise CC-3000. Although the CC-3000 interfaces to the Mac via a USB port, you will need to install the FTDI RS-232 to USB driver available from http://www.ftdichip.com/. The RainWise CC-3000 Agent supports the retrieval of archived records stored in the sta- tion. You can turn on this feature by checking the option to obtain the archived records.
LaCrosse WS-2315
This option will obtain all sensor values expected on an LaCrosse WS-2315. You will need to select the RS-232 device that the station is connected to. If you have an RS-232 to Network adapter, select TCP/IP as the device and enter its network address and port number.
WS-1080/WS-2080
This option will obtain all sensor values expected on a WS-1080/WS-2080. This station uses a USB interface, so no device selection is necessary. Note that this station is also sold under several names, including the Fine Oset, and the Tycon TP1080WC. The WS-1080/WS-2080 Agent supports the retrieval of archived records stored in the station. You can turn on this feature by checking the option to obtain the archived re- cords. Additionally, you can check the option to clear the archived data in the stations memory after a successful retrieval of all of the archived data.
18
Whats Next?
Now that you have set up your site information and chosen your weather source, youre ready to move on to the next step: deciding how to share your weather data. The next section shows you how to do just that.
19
To enable this feature, just click the checkbox, ll in your Weather Underground station ID and password, select the update interval, and your weather data will be sent to Weather Underground automatically. If you don't already have a station ID and would like to sign up your station, click on the Weather Underground logo and it will take you to the Per- sonal Weather Stations page. Once you have typed your station information, clicking on the logo will take you to the details web page for your station.
20
The interval is the number of seconds that WeatherSnoop waits between uploads of your weather data. Smaller intervals are better, as they allow for frequent uploads and more timely readings (especially with values that can change quickly, like wind speed and wind direction). However, if you want to limit the amount of trac due to bandwidth concerns or other considerations, you can select a larger interval. WeatherSnoop will stop sending data from to Weather Underground if it detects that more than one hour has passed since your station has provided any data. This is to pre- vent stale data from being uploaded to the service.
21
Once you have typed your station information, clicking on the logo will take you to the de- tails web page for your station.
22
NOTE: In order for CWOP to accept your data, your exact longitude and latitude must be set in the My Site tab. Once this is done, you can turn on the feature and your data will be sent to the CWOP server automatically.
23
24
When obtaining data this way, the computer running WeatherSnoop must be accessible from your network. If you are running on a local area network, this is usually not an is- sue. However if you wish to allow WeatherSnoop to serve data over the Internet, you will likely need to congure your Internet gateway device to allow access to the specic inter- nal IP address and port number that WeatherSnoop will be serving the data from.
25
You will need to input the username and password for the FTP account, as well as the server name. An optional server path can be specied where WeatherSnoop will actually place the le, and the FTP interval can also be set.
26
At the set period, WeatherSnoop will upload two les weather.xml and weather.json onto the server. These les contains the most current weather data in various units, as well as station information.
Whats Next?
In the next section, well examine the Weather Properties window, a feature that allows you to view your weather information at a glance and even lets you change your units.
27
5 Weather Properties
In WeatherSnoop terminology, a weather property is a single, measurable item (e.g. out- door temperature or barometric pressure) and all of its associated information such as its name, latest value, current unit, and the last time it was updated. The Weather Proper- ties window shows all of the available weather properties that WeatherSnoop supports in an easy-to-read table view. You can also change the unit of a property in this window.
Bring up the window by navigating to the View > Weather Properties menu item. From the window, you can view all of the available weather properties at a glance. The name of each weather property is shown, along with its most recent value, the time that the value was obtained, and the current unit. It is important to keep in mind that even though every weather property that Weath- erSnoop tracks will appear in the table, not all weather properties are supported for all station congurations. Those weather properties that are either unsupported or have yet to obtain a proper value from the source yet contain a value of Uninitialized.
Calibration Oset
Every weather property has a calibration oset, defaulting to 0, that can be set to either a positive or negative number. This is typically useful for adjusting the values of properties such as barometric pressure, or an anemometer which is reading wind speed values that are slightly o. The calibration oset is added to the value of the weather property and is reected throughout WeatherSnoop. Note that the oset is just a number without regard to units. If you change your units, you will need to update your calibration oset as well.
Whats Next?
The remainder of this guide, up to the appendices, focuses on features that not available in WeatherSnoop Lite. Beyond Lite, you will nd a full array of features over and above
29
weather data acquisition and sharing. Instrument gauges show you in real-time what your weather data looks like from your data source. Colorful graphs let you examine how your weather data has changed over time. You can also obtain an easy-to-read summary of the current weather conditions with the Weather Report feature.
30
6 Weather Report
The Weather Report window provides a summary of the current weather in an easy-to- understand, natural language format. Its content is updated once per second using the latest values from the weather properties referenced in the report. To view the Weather Report window, navigate to the View > Weather Report menu item.
Reading Aloud
Using the Macs text-to-speech technology, you can have the report information read over your Macs speakers at an interval of your choosing. The report is read aloud at specic intervals by turning on the speaking option and selecting a time, or you can click the Speak Now button to hear the weather report read aloud at that instant.
Whats Next?
Well kick things up a notch and show you how to see your weather data like it was really meant to be seen -- in gauges and instruments that bring it to life!
31
7 Weather Instruments
WeatherSnoop allows you to view your current weather with real-to-life instruments and gauges. Most gauges contain both analog and digital displays, while other values are rep- resented by LED indicators As soon as the agent obtains a new value for a weather property, all gauges for that property are immediately updated throughout WeatherSnoop to reect that value.
Hi-Def Instruments
The Hi-Def Instruments window is sized to 1920 x 1080 pixels and is designed to be dis- played on a resolution monitor or hi-denition television. It contains both indoor and outdoor instruments as well as a weather report area, a graph, an LED clock and a com- plete list of the weather properties. Navigate to the View > Hi-Def Weather Instruments menu item to show the Hi-Def Weather Instruments window.
34
Whats Next?
Now that youve seen how to bring your real-time data to your Mac in a lively and realistic fashion, well take a look at how to view your archived data through graphing.
35
36
As graph windows are created, they are generically named in ascending order as Graph 1, Graph 2, etc. Graph names are recycled as windows are closed Every graph window is composed of three major sections: 1. Top area: the date range cluster. The date range cluster allows you to select the start and end date for the graph. Use the stepper buttons or simply type in the date and time to change the range. You can also utilize the Quick Dates popup button to quickly and easily select one of several common date ranges. Once the dates have been set, simply click on the Refresh button and the graph will re- fresh its data to the new date range. 2. Middle area: the graph. The graph takes up the middle of the window and is where the values of the selected weather properties are plotted. You can hover your mouse over this area and a hint will appear indicating the weather property and its associated color in the graph. 3. Bottom area: the property details table. This table shows the names of the weather properties in the graph as well as other information. At a glance, you can view the property details table to see which weather properties are represented, along with the unit and the corresponding graph color. Additionally, the minimum, maximum, and av- erage values for date range are also indicated, as well as the number of data values that compose the graph itself. If you so choose, you can click on the disclosure triangle above the property details ta- ble in order to hide the table and make more room for the graph.
37
2. Right-click on one or more selected weather properties in the Weather Properties table. A menu will appear where you can opt to show all properties in a single graph win- dows, in separate graph windows, or add all properties to an existing graph window. 3. Drag one or more selected weather properties from the Weather Properties table onto the graph. To do this, bring up the Weather Properties window, then click on a weather property and drag it to the graph. You can also perform this function from the Weather Properties table in the Hi-Def Instruments window.
Whats Next?
There are times when you want to view your archived data as numbers instead of graphs, and even change a thing or two. Thats a job for the Data Custodian.
38
Heres how to congure the Data Custodian: 1. From the View menu, select the Weather Properties menu item to view the Weather Properties Window. 2. Click on the desired property in the Weather Properties window and drag and drop it onto the Data Custodian window (you can select more than one property by holding the Command key and clicking additional rows).
39
3. Select the desired date range, or use the Quick Date button, then click the Refresh but- ton. The Data Custodian will fetch the data and display it in the table. The Refresh button becomes the Cancel button while the fetch is occurring, allowing you to abort the procedure. Depending upon the date range and amount of data in the database, it may take several seconds to retrieve the data. When all of the data has been fetched, it will appear in tabular format, along with summary information in the bottom table.
Exporting
You can export the data from the Data Custodian to a comma-separated value (CSV) le by clicking on the Export... button. A sheet drops down with a default name and location to save the le. You can also elect to have the header row exported, as well as having the le opened automatically when the export is nished.
Whats Next?
Keeping a weather journal can be handy for referring to specic events. WeatherSnoops Weather Notes feature lets you do just that.
40
10 Weather Notes
Weather Notes allows you to keep a journal of noteworthy weather events or other infor- mation that you can easily refer back to. To interact with Weather Notes, simply navigate to the View menu and select Weather Notes. The Weather Notes window is a classic master/detail view that has a list of notes on the left pane and the content of the selected note in the text editing area. You can click on the + icon at the bottom to add a new note, or click on the - icon to remove a selected note. The search eld at the top right allows you to search all of your notes for a specic word or phrase.
All notes le itself is stored in the Documents folder of the WeatherSnoop data folder. To access this folder, select Tools > Show Files in Finder on the menu bar.
41
11 Data Quality
The issue of data quality is an important one to weather station owners as well as the weather data services that they publish to. The weather data that you generate and share could be used for a number of dierent purposes, including research and planning. For that reason, and for posterity itself, it is important that the weather data coming from your data source be as accurate as possible. There are many dierent factors that can aect a weather stations data quality. Here are some of the main ones: 1. Erratic or malfunctioning sensors, or wireless sensors that have weak batteries. 2. Sensors that are improperly placed or mounted (e.g. a temperature sensor is located in direct sunlight, or a wind gauge is partially blocked by a wall or other obstruction). 3. Intermittent communication between a wireless sensor and its base station due to poor placement, frayed wiring or battery issues. 4. Intermittently garbled or junk data coming from the station to the Mac due to poor ca- bling, older station rmware, or poorly designed hardware. In some of these instances, proper planning can have a direct impact on the quality of the data. In other cases, the problem lies with the data source itself, and no amount of recti- cation can avoid the occasional data error. The quality of collected weather data is more important than how much of the data is col- lected. While more data translates into higher data resolution, having a lot of invalid data is meaningless compared to have a smaller set of good data.
Range
Every type of weather property that WeatherSnoop supports (temperature, humidity, lin- ear measurement, etc) has a valid range limit that a value must t within in order to be considered of good quality. For example, it makes no sense to have a negative hourly
42
rainfall or wind speed. Likewise, extreme temperatures such as 500 F or -250 C repre- sent impractical weather scenarios and could indicate a station malfunction.
Age
Much of our weather data tends to vary over time. Temperature, humidity and pressures are constantly changing, even if slightly. On the other hand, it may not rain for days or weeks at a time, so those values are still valid even though they have not recently changed. Every weather property that WeatherSnoop supports has a timestamp associated with it. This timestamp can be seen in the Weather Property view, and one can quickly determine the age of a particular weather property. This age is useful in determining the datas validity in computations of the values of other weather properties.
Deviation
In most cases, a weather propertys value will not be signicantly dierent from its previ- ous value. For example, it is unlikely that a temperature will be 20 F one minute, then 97 F the next. On the other hand, wind speeds can change quickly and drastically.
Property Type
Temperature Humidity Pressure Length Velocity Direction Solar Radiation
Range
-40 to 140 F 0 to 100% 27 to 33 inHg 0 to innity 0 to 120 mph 0 to 360 degrees 0 to 10000 w/m2
43
Whats Next?
The rest of this Users Guide is composed of appendices which focus on specic technical parts of WeatherSnoop. Feel free to peruse the next few sections.
44
A2 Database Information
One of the features of WeatherSnoop is that it sends all real-time weather data to an SQLite database. This chapter explains the layout of the database and ways to get to the data.
The Schema
In the WeatherSnoop SQLite database, a table exists for each type of data value obtained from the station. Each row in a table contains two elements: the date/time of the sample (stored as the number of seconds since 1 January 1970) and the value recorded at that date/time. The following table shows the schema for the database, including the data item, unit, ta- ble name, and data type.
Data Item (Units) Barometric Pressure (inHg) Barometric Trend Rain Today (inches) Indoor Dew Point (F) Indoor Humidity (%) Indoor Temperature (F) Rain this Month (inches) Outdoor Dew Point (F) Outdoor Humidity (%) Outdoor Temperature (F) Rain this Year (inches) Rain Total (inches) Wind Direction (degrees) Wind Speed (miles/hour) Ultraviolet Index Solar Radiation (watts/meter) Ionizing Radiation (millirem/hour) Rain Rate (inches/hour) Forecast Table Name barometricPressure barometricTrend dayRain indoorDewPoint indoorHumidity indoorTemperature monthRain outdoorDewPoint outdoorHumidity outdoorTemperature yearRain totalRain windDirection windSpeed uvIndex solarRadiation ionizingRadiation rainRate forecast Data Type Float value String value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value Float value String value
Wind Gust (miles/hour) Extra Temperatures (1-10) Extra Humidities (1-10) Wind Chill (F) Outdoor Heat Index (F) Indoor Heat Index (F)
Float value Float value Float value Float value Float value Float value
Launch the Terminal.app application (found in the Applications > Utilities folder) and type the following command and press the Return key:
sqlite3 ~/Documents/weather.db
(This command assumes WeatherSnoop is storing the data in a database named weather.db located in your Documents folder; adjust the command accordingly if needed). You should then see the sqlite3 prompt.
SQLite version 3.4.0 Enter ".help" for instructions sqlite>
You can type the .table command and press Return to see the list of tables:
sqlite> .tables barometricPressure barometricTrend dayRain extraHumidity1 extraHumidity8 extraHumidity9 extraTemperature1 extraTemperature10 extraTemperature9 forecast indoorDewPoint indoorHeatIndex rainRate solarRadiation totalRain uvIndex
46
With SQLite you can construct SQL queries to see the data in any of the tables. For in- stance, to view all of the outdoor temperature data, type the following and press Return:
select * from outdoorTemperature;
The rst column is the date/time stamp of the sample, followed by the outdoor tempera- ture for that date/time (the vertical bar | is used as a column separator character). For a more reasonable date/time stamp you could type the following and press Return:
select datetime(time,'unixepoch','localtime'),value from outdoorTemperature;
If you want to output the data for the table to a CSV le for loading into a spreadsheet program, you could type the following commands:
sqlite> .mode csv sqlite> .output export.txt sqlite> select * from outdoorTemperature;
The rst command tells SQLite to output the data in CSV compatible mode; the second command forces the output of all subsequent commands to a le named export.txt; the third command, upon completion, will have exported all outdoor temperatures to the ex- port le.
47
There are other commands that you can use to view and lter your data. For more in- formation, visit the SQLite website at http://www.sqlite.org/
48
WeatherSnoop Tags
The current version of WeatherSnoop is available from the following tag:
%%wsVersion%%
more tags for the value of the property in dierent units (e.g. %%outdoorTempera- ture_Fahrenheit%%, %%outdoorTemperature_Celsius%%). The individual value tags are shown below:
50
51
52
value and its source. Station supplied values are just that: they are obtained directly from the station. Computed values are calculated internally by WeatherSnoop.
53
54
55
56
57
LaCrosse WS-2315
The WS-2315 weather station interface from LaCrosse connects to the Mac via a USB to RS-232 adapter. You can also use a Serial to Network adapter and specify the name or IP address in the agent to connect to the unit over a network. Rain values are computed via WeatherSnoops Rain Computer using the total rain accumulator provided by the station.
Value Barometric Pressure (Relative) Barometric Trend Extra Humidities Extra Temperatures Forecast Indoor Dew Point Indoor Heat Index Indoor Humidity Indoor Temperature Outdoor Dew Point Outdoor Heat Index Outdoor Humidity Outdoor Temperature Rain Rate Rain This Month Rain This Year Rain Today Rain Total Solar Radiation Ultraviolet Index Wind Chill Wind Direction Wind Gust Wind Speed Source Station supplied Station supplied Unavailable Unavailable Station supplied Computed Computed Station supplied Station supplied Computed Computed Station supplied Station supplied Computed Computed Computed Computed Station supplied Unavailable Unavailable Computed (see http://en.wikipedia.org/wiki/Wind_chill) Station supplied Computed Station supplied
58
WS-1080/WS-2080
The WS-1080/WS-2080 weather station connects to the Mac via USB. This station is sold under dierent brand names, including Ambient Weather WS-1080/WS-2080, Weatherwise WS-1080-SOLAR, Fine Oset, Zephyr WH1081, Tycon TP1080WC, N96GY or Digitech XC-0348. Rain values are com- puted via WeatherSnoops Rain Computer using the total rain accumulator provided by the station.
Value Barometric Pressure (Relative) Barometric Trend Extra Humidities Extra Temperatures Forecast Indoor Dew Point Indoor Heat Index Indoor Humidity Indoor Temperature Outdoor Dew Point Outdoor Heat Index Outdoor Humidity Outdoor Temperature Rain Rate Rain This Month Rain This Year Rain Today Rain Total Solar Radiation Ultraviolet Index Wind Chill Wind Direction Wind Gust Wind Speed Source Computed from absolute pressure and elevation Unavailable Unavailable Unavailable Unavailable Computed Computed Station supplied Station supplied Computed Computed Station supplied Station supplied Computed Computed Computed Computed Station supplied Unavailable Unavailable Computed (see http://en.wikipedia.org/wiki/Wind_chill) Station supplied Station supplied Station supplied
59
60
61
62
63
64
65
66
67
- (void)willUnload;
Description Methods
These two methods are for informational purposes, and should return the proper name of your plug-in, as well as a description, respectively. - (NSString *)name; - (NSString *)description;
Menu Methods
This method returns an NSMenuItem which will be inserted into the PlugIns menu on the WeatherSnoop menu bar. If your plug-in is designed to not require any user interactivity, or you do not wish to have it appear in the menu, return nil. - (NSMenuItem *)menuItem;
69
- (WeatherSite *)weatherSite; Weather-related properties such as temperature, humidity, wind, etc. are stored within the WeatherSite object, and each property is represented by an Objective-C object of the class WSProperty. Please see the example plug-in project, as well as the WeatherSite.h and WSProperty.h header le which are part of the WSKit bundle.
Executing a Query
You can use the WSPlugIn service object to execute queries against the database. This is useful for obtaining historical values of weather properties. The method to execute the query is as follows: - (NSDictionary *)executeQuery:(NSString *)sql; You can pass any standard SQLite query as a parameter. The resulting dictionary con- tains the following keys:
Key
result
Type
NSArray
Value
Array of WSProperty objects represent- ing the result set
returnMessage
NSString
returnCode
NSNumber
70
71
72