Query Server

Overview
Using The Server
Commands
User Log


Overview

The APRS Query Server allows APRS stations to query the server for specific weather data stored by the server. Using simple two-letter commands and an on-line help system, a user is capable of retrieving most of the data stored in the database.

While optimized for the D7A Kenwood handheld and the D700A mobile, it can be used by any APRS system equipped to handle messaging.

Additionally, the server appends the appropriate string character to the response so that a Kenwood D700A equipped with a speech synthesizer can speak the response. This is a useful enhancement for mobile users.

Section Contents


Using The Server

The request for information is sent using standard text in an APRS message.

The "To:" field in the APRS message format is simply the server's CALLSIGN-SSID or can optionally be an alias as configured in wxncommon.conf.

The body of the message is the two character command code for the data desired. Note that multiple commands can be entered in the same message by separating each with a space.

While the next section lists all the commands in detail, the on-line help system can help the user navigate through the menus. Help comes in three formats:

Cmd Response
? Lists major command areas (single character). Table below gives meanings for returned data
c Where c is the command area character as given in the table that follows. Lists the commands available within that area or points to secondary commands to list the actual commands. Sounds like convoluted, but was necessary to accomodate the small screen of the D7A HT.
?cc Where cc is the two letter command that returns data. Describes what type of data is returned by the command.

The following table lists all the major command areas:

Cmd Char Area
t Temperature
w Wind
b Barometric Pressure
h Humidity
e EMP (lightning)
r Background Radiation
m Miscellaneous
q QTH (location)

Commands to access the WRSAME data will be added when that server is completed.

Section Contents


Commands

Temperature Wind Barometric Pressure
Precipitation EMP (Lightning) Humidity
Background Radiation Miscellaneous QTH

Temperature

Values returned are in degrees Fahrenheit.

Command Description
t Lists commands for temperature command help (t1, t2)
t1 Lists most frequently used temperature commands.
t2 Lists less frequently used temperature commands
tc Current temperature
th High temperature since midnight local time
tl Low temperature since midnight local time
tr Temperature hourly rate of change
td Temperature 24-hour rate of change
ti Current inside temperature
ts Current soil temperature
tt Yesterday's high temperature
tb Yesterday's low temperature
ca Current wind chill average
cg Current wind chill gust
hx Current head index
dh Heating degree days for yesterday
dc Cooling degree days for yesterday

Sub-Section Contents

Wind

Values returned are in MPH and degrees relative to true north.

Command Description
w Shows command to get wind commands (w1)
w1 Lists wind commands (wc, wg, wh, wl, wt)
wc Current wind average speed and direction
wg Current wind gust speed and direction
wh High wind avereage speed and direction since midnight local time
wl Low wind avereage speed and direction since midnight local time
wt High wind gust speed and direction since midnight local time

Sub-Section Contents

Barometric Pressure

Values returned are in tenths of millibars (i.e., 10 = 1 mb)

Command Description
b Shows command to get barometric pressure commands (b1)
b1 Lists barometric pressure commands (bc, bh, bl, br, bd)
bc Current barometric pressure
bh High barometric pressure since midnight local time
bl Low barometric pressure since midnight local time
br Barometric pressure hourly rate of change
bd Barometric pressure 24-hour rate of change

Sub-Section Contents

Precipitation

All values returned are in hundredths of an inch (i.e., 100 = 1.00")

Command Description
p Shows command to get precipitation commands (p1)
p1 Lists precipitation commands (pc, pi, ph, pl, pd, py, pm, pa)
pc Current precipitation total since midnight local time
pi Shows instantaneous hourly precipitation rate (based on rate for last five minutes)
ph Precipitation rate for last hour (true 60 minute span)
pl Shows amount of precipitation that has fallen in the last hour (taken at the top of the hour)
pd Amount of precipitation fallen in the last 24-hour period
py Precipitation total for yesterday
pm Precipitation total for the current month
pa Precipitation total for the current year

Sub-Section Contents

EMP (Lightning)

Values returned are the number of hits detected.

Command Description
e Shows command to get EMP commands (e1)
e1 Lists EMP commands (ec, eq, es, eh, ed, ea)
ec Number of hits for the last five minutes
eq Number of hits for the last 15 minutes
es Number of hits for the last 30 minutes
eh Number of hits for the last 60 minutes
ed Number of hits since midnight local time
ea All EMP commands (i.e., same as 'ec eq es eh ed')

Sub-Section Contents

Humidity

Units are in % relative humidity.

Command Description
h Shows command to get humidity commands (h1)
h1 Lists humidity commands (hc, hh, hl, hr, hd, hi)
hc Current relative humidity
hh High relative humidity since midnight
hl Low relative humidity since midnight
hr Relative humidity hourly rate of change
hd Relative humidity 24-hour rate of change
hi Inside relative humidity

Sub-Section Contents

Background Radiation

Values returned are in micro-Roentgens/hour.

Command Description
r Shows command to get background radiation commands (r1)
r1 Lists background radiation commands (rc, rh, rd, ra)
rc Current background radiation count (five minutes)
rh Hourly background radiation count average
rd Daily background radaiation count average
ra Returns three values: max radiation count for day, number of radiation alarms tripped since midnight local time and the alarm trip point.

Sub-Section Contents

Miscellaneous

Command Description
m Shows command to get miscellaneous commands (m1)
m1 Lists miscellaneous commands (fo, dp, sr, an, dz, dl)
fo Returns if the conditions are favorable for fog (or not)
dp Returns the curren dewpoint
sr Returns the sunrise and sunset times for the current day
an Whether or not a NWS watch or warnning is in effect (future - will be implemented when wxnsamed daemon is completed)
dz UTC date-time of last weather station reading
dl Local date-time of last weather station reading

Sub-Section Contents

QTH (Location)

Command Description
q Shows command to get QTH commands (q1)
q1 Lists QTH commands (qt, qh, qe, qn)
qt Returns city and state of the node's location
qh Returns the FIPS code, county and state of the node's location
qe Returns the elevation and HAAT for anememometer of the node
qn Returns the AFOS identifier for NWS office covering the area the node is located in

Sub-Section Contents

Section Contents


User Log

When a user connects to the query server, the CALLSIGN-SSID along with the commands executed are written to the queryd table in the database. The following describes the structure of each record in the table:

Field Description
dtg_local Date-time of the query
call_ssid The CALLSIGN-SSID of the user making the query
query_cmd The commands sent to the query server
node future (currently unused)

Section Contents