# [Station]

This section covers options relating to your weather station setup.

## General Settings

These options apply to every type of station.

#### ==location==

The station location should be a UTF-8 string that describes the geography of
where your weather station is located. Required. No default.

``` ini
location = "A small ranch in Kentucky"
```

#### ==latitude==
#### ==longitude==

The lat/lon should be set in decimal degrees, negative for southern and western
hemispheres, respectively. Required. No default.

``` ini
latitude = 38.8977
longitude = -77.0366
```

#### ==altitude==

Normally the altitude is downloaded from your hardware, but not all stations
support this. Set to the altitude of your console and the unit used to measure
that altitude.

!!! Note

    If you live in a high-rise building, the altitude of the console (which is
    where the pressure gauge is located), can be considerably different from
    the ground altitude. You want the altitude of the console.

Example:

``` ini
altitude = 700, foot
```

An example in meters:
``` ini
altitude = 220, meter
```

#### ==station_type==

Set to the type of hardware you are using.

``` ini
station_type = Simulator
```

!!! note
    Whatever option you choose, **you must have a matching section** in your
    configuration file. For example, if you choose `station_type = Simulator`,
    then you will need a **[Simulator]** section. While you can do this by
    hand, it is tedious and error-prone. The better way to add the needed
    section is by using the utility [`weectl station reconfigure`](../../utilities/weectl-station.md#reconfigure-an-existing-station).
    If the needed section is missing, this utility will automatically inject
    it into the configuration file.

Valid station types include:

| Option            | Description                                                             |
|-------------------|-------------------------------------------------------------------------|
| **Simulator**     | A software weather station simulator. Useful for testing and debugging. |
| **AcuRite**       | AcuRite 5-in-1 stations with USB interface.                             |
| **CC3000**        | RainWise CC3000 data logger.                                            |
| **FineOffsetUSB** | Fine Offset 10xx, 20xx, and 30xx stations.                              |
| **TE923**         | Hideki TE923 stations.                                                  |
| **Ultimeter**     | PeetBros Ultimeter stations                                             |
| **Vantage**       | Davis Vantage weather stations.                                         |
| **WMR100**        | Oregon Scientific WMR100 series stations.                               |
| **WMR300**        | Oregon Scientific WMR300 series stations.                               |
| **WMR9x8**        | Oregon Scientific WMR-918/968 series stations                           |
| **WS1**           | Argent Data Systems WS1 stations.                                       |
| **WS23xx**        | La Crosse 23xx stations.                                                |
| **WS28xx**        | La Crosse 28xx stations.                                                |


#### ==station_url==

If you have a website, you may optionally specify an URL for its HTML server.
It will be included in the RSS file generated by WeeWX and, if you choose to
opt into the [station registry](stdrestful.md#stationregistry), it will also
be included in the [map of WeeWX stations](https://www.weewx.com/stations.html).
It must be a valid URL. In particular, it must start with either `http://`
or `https://`.

Example:

``` ini
station_url = https://www.mywebsite.com
```
#### rain_year_start

Normally the start of the rain year is downloaded from your hardware, but not
all stations support this. Set to the start of your rain year, for example, if
your rain year starts in October, set it to `10`. Default is `1`.

``` ini
rain_year_start = 1
```

#### week_start

Start of the week. `0`=Monday, `1`= Tuesday, ... , `6` = Sunday. Default is
`6` (Sunday).

``` ini
week_start = 6
```


## [Simulator]

This section is for options relating to the software weather station simulator
that comes with WeeWX.

#### loop_interval

The time (in seconds) between emitting loop packets. Default is `2.5`.

#### mode

One of either `simulator` or `generator`. Default is `simulator`.

| mode        | Description                                                  |
|-------------|--------------------------------------------------------------|
| `simulator` | Real-time simulator. It will sleep between emitting packets. |
| `generator` | Emit packets as fast as it can. Useful for testing.          |

#### start

The local start time for the generator in the format `YYYY-mm-ddTHH:MM`. An
example would be `2012-03-30T18:30`. This would code 30-March-2012, at 6:30pm,
local time. Optional. Default is the present time.


## [AcuRite]

This section is for options relating to the AcuRite 5-in-1 series of weather
stations with USB connectors.

#### model

Set to the station model. For example, "AcuRite 01035", "AcuRite 01036", or
"02032C"

#### use_constants

Some stations (01035, 01036) use the HP038 sensor, which contains constants
that define how the pressure and temperature should be interpreted. Other
stations (02032, 02064) use the MS5607 sensor, which requires a different
calculation to determine the pressure and temperature from the sensor. When
`use_constants=True`, the driver will use the constants to determine which
type of sensor is in the station and will adjust the calculation accordingly.
A value of `False` causes the driver to use a linear approximation, regardless
of the type of sensors. The default is `True`.


## [CC3000]

This section is for options relating to the RainWise Mark III weather stations
and CC3000 data logger.

#### port

The serial port, e.g., `/dev/ttyS0`. When using a USB-Serial converter, the
port will be something like `/dev/ttyUSB0`. Default is `/dev/ttyUSB0`

#### debug_serial
#### debug_openclose
#### debug_checksum

The `debug_serial`, `debug_openclose`, and `debug_checksum` can be set to one
to produce debugging information in the WeeWX log. The defaults for these
options are zero.

#### logger_threshold

The `logger_threshold` specifies the number of records in the CC3000 station's
memory at which the station memory's should be cleared. If logger_threshold is
not specified, or if zero is specified, the station's memory will never be
cleared. In this case, when the memory fills up, new archive records will no
longer be saved in memory. Note: the CC3000's memory will hold about 35,000
records. The default is 0 (i.e., never clear memory).

#### max_tries

The `max_tries` option specifies how many times WeeWX should retry
communicating with the CC3000 station when a serial communications error
occurs. The default is `5`.

#### model

The option `model` specifies the name of the hardware reported to WeeWX. The
default is `CC3000`.

#### polling_interval

The `polling_interval` determines how often WeeWX will query the station for
data in seconds. The default is `2`. Note: 2 seconds is a good choice as this
is the rate at which the CC3000 receives updates from the Rainwise Mark III
Weather Station.

#### sensor_map

This option defines the mapping between temperature values in the database and
the remote sensors. Two additional temperature sensors are supported.

For example, this would associate `extraTemp1` with the second optional
temperature sensor:

```
[[sensor_map]]
    extraTemp1 = TEMP 2
```

See the [CC3000 Station data table](../../hardware/cc3000.md#cc3000_data)
in the *Hardware guide* for a complete listing of sensor names and the default
database fields for each sensor.

#### use_station_time

The `use_station_time` specifies whether the loop packets read by weewx should
use the time specified in the CC3000 station packet or the computer time. The
default is `True` (*i.e.*, to use CC3000 station time).


## [FineOffsetUSB]

This section is for options relating to the Fine Offset series of weather stations with USB connectors.

!!! warning
    The following settings are highly recommended for Fine Offset stations.
    Using hardware record generation or adaptive polling is more likely to
    cause USB communication failure. Using hardware record generation will
    cause delays in report generation.

```
[FineOffsetUSB]
    polling_mode = PERIODIC
    polling_interval = 60
[StdArchive]
    record_generation = software
```

#### model

Set to the station model. For example, `WH1080`, `WS2080`, `WH3081`, *etc.*

#### polling_mode

One of `PERIODIC` or `ADAPTIVE`. In `PERIODIC` mode, WeeWX queries the console
at regular intervals determined by the polling_interval. In `ADAPTIVE` mode,
WeeWX attempts to query the console at times when it is not reading data from
the sensors or writing data to memory. See the section [*Polling mode and
interval*](../../hardware/fousb.md#polling-mode-and-interval)
in the *Hardware Guide* for more details. The default is `PERIODIC`.


#### polling_interval

The frequency, in seconds, at which WeeWX will poll the console for data. This
setting applies only when the polling_mode is `PERIODIC`. Default is `60`.

#### data_format

There are two classes of hardware, the 10xx/20xx consoles and the 30xx
consoles. Unlike the 10xx/20xx consoles, the 30xx consoles record luminosity
and UV, so they have a different data format. Use the `data_format` to
indicate which type of hardware you have. Possible values are `1080` (for the
10xx and 20xx consoles) and `3080` (for the 30xx consoles). Default is `1080`.


## [TE923]

This section is for options relating to the Hideki TE923 series of weather
stations.

#### model

Set to the station model. For example, Meade TE923W or TFA Nexus. Default is
`TE923`.

#### sensor_map

This option defines the mapping between temperature / humidity values in the
database and the remote sensors. Up to 5 remote sensors are supported. A
switch on each sensor determines which of 5 channels that sensor will use. For
example, if the switch on the sensor is set to 3, the temperature from that
sensor will be `t_3` and the humidity from that sensor will be `h_3`.

For example, this would associate `outTemp` and `outHumidity` with sensor 4:

``` ini
[[sensor_map]]
    outTemp = t_4
    outHumidity = h_4
```

See the [*TE923*](../../hardware/te923.md) section of the *Hardware Guide*
for a complete listing of sensor names and their corresponding default
database field.


## [Ultimeter]

This section is for options relating to the PeetBros Ultimeter weather
stations.

#### port

The serial port, e.g., `/dev/ttyS0`. When using a USB-Serial converter, the
port will be something like `/dev/ttyUSB0`. Default is `/dev/ttyUSB0`

#### model

Set to the station model. For example, `Ultimeter 2000` or `Ultimeter 800`.
Default is `Ultimeter`.


## [Vantage]

This section is for options relating to the Davis Vantage series of hardware
(VantagePro, VantagePro2 or VantageVue).

#### type

Set to either `serial`, for a serial or USB connection to the VantagePro (by
far the most common), or to `ethernet` for the WeatherLinkIP. No default.

#### port

If you chose `serial`, for `type`, then set to the serial port name used by
the station. For example, `/dev/ttyUSB0` is a common location for USB ports,
`/dev/ttyS0` for serial ports. Otherwise, not required. No default.

#### host

If you chose `ethernet`, then specify either the IP address (_e.g._,
`192.168.0.1`) or hostname (_e.g._, `console.mydomain.com`) to the console.
Otherwise, not required. No default.

#### baudrate

Set to the baudrate of the station. The default is `19200`.

#### tcp_port

The port where WeatherLinkIP will be listening. Default is `22222`.

#### tcp_send_delay

How long to wait in seconds after sending a socket packet to the WeatherLinkIP
before looking for input. Default is `0.5`.

#### loop_request

The type of LOOP packet to use for LOOP data. Options are `1` (type **LOOP1**);
`2` (type **LOOP2**); or `3` (alternate between). 

Type **LOOP2** packets have the advantage of including gauge pressure,
altimeter, heat index, THSW, and a few other types, so they do not have to be
calculated in software. On the other hand, they do not include any of the
extra Davis sensors, such as soil moisture, leaf temperature, *etc*.

If you decide to alternate between packet types (option `3`), then the console
will send a type **LOOP1** packet, followed by a type **LOOP2** packet. This
means that for certain types, and depending on the options specified in
`[StdWXCalculate]`, the value that is used by WeeWX can flip between hardware
and software values with every packet. In this case, you should be sure to
specify option `hardware` for types `pressure`, `altimeter`, `dewpoint`,
`windchill`, and `heatindex`. This way, only hardware values will be used.

!!! info
    Not all stations support LOOP2 data. You need firmware version 1.90 or
    later.

Default is `1` (use **LOOP1** type packets).

#### iss_id

Set to the ID number of the Integrated Sensor Suite (ISS). This is used in the
formula to calculate reception quality for wireless stations. Default is `1`.

#### timeout

How many seconds to wait for a response from the station before giving up.
Default is `4`.

#### wait_before_retry

How many seconds to wait before retrying. Unless you have a good reason to
change it, this value should be left at the default, as it is long enough for
the station to offer new data, but not so long as to go into a new loop packet
(which arrive every 2 seconds). Default is `1.2`.

#### max_tries

How many times to try again before giving up. Default is `4`.


## [WMR100]

This section is for options relating to the Oregon Scientific WMR100 series
of weather stations with USB connectors.

#### model

Set to the station model. For example, `WMR100` or `WMRS200`.

#### sensor_map

This option defines the mapping between observations from remote sensors and
the fields in the database.

For example, this would associate `extraTemp1` with the remote T/H sensor on channel 5:

```
[[sensor_map]]
    extraTemp1 = temperature_5
```

See the [*WMR100*](../../hardware/wmr100.md) section of the *Hardware guide*
for a complete listing of sensor names and the default database fields for
each sensor.


## [WMR300]

This section is for options relating to the Oregon Scientific WMR300 series
of weather stations with USB connectors.

#### model

Set to the station model. For example, `WMR300` or `WMR300A`.

#### sensor_map

This option defines the mapping between temperature / humidity values in the
database and the remote sensors. Up to 8 remote sensors are supported.

For example, this would associate `outTemp` and `outHumidity` with sensor 4:

```
[[sensor_map]]
    outTemp = temperature_4
    outHumidity = humidity_4
```

See the [*WMR300*](../../hardware/wmr300.md) section of the *Hardware guide*
for a complete listing of sensor names and the default database fields for
each sensor.


## [WMR9x8]

This section is for options relating to the Oregon Scientific WMR-918/968
series of weather stations with serial connectors.

#### type

For the moment, only `serial` is supported.

#### port

Along with the serial option above, you must set the serial port name used by
the station. For example, `/dev/ttyUSB0` is a common location for USB ports,
`/dev/ttyS0` for serial ports. No default.

#### model

Set to the station model. For example, `WMR968` or `WMR918`.

#### sensor_map

This option defines the mapping between observations from remote sensors and
the fields in the database.

For example, this would associate `extraTemp1` with the remote T/H sensor on
channel 5:

```
[[sensor_map]]
    extraTemp1 = temperature_5
    extraHumid1 = humidity_5
```

See the [*WMR9x8*](../../hardware/wmr9x8.md) sectioin of the *Hardware guide*
for a complete listing of sensor names and the default database fields for
each sensor.


## [WS1]

This section is for options relating to the Argent Data Systems WS1 weather
stations.

#### mode

Select whether to connect via a serial line (option `serial`), or via an IP
connection using TCP (option `tcp`), or UDP (option `udp`). Default is
`serial`.

#### port

The port to be used. For a serial connection, this will be something like
`/dev/ttyUSB0`. For a TCP or UDP connection, it will be an IP address and
port, such as `192.168.1.12:3000` Default is `/dev/ttyUSB0`.

#### polling_interval

The `polling_interval` determines how often in seconds that WeeWX will query
the station for data. The default is `1`.


## [WS23xx]

This section is for options relating to the La Crosse WS-23xx series of
weather stations.

#### port

The serial port, *e.g.*, `/dev/ttyS0`. When using a USB-Serial converter, the
port will be something like `/dev/ttyUSB0`. Default is `/dev/ttyUSB0`

#### model

Set to the station model. For example, `WS-2315`, `LaCrosse WS2317`, *etc*.
Default is `LaCrosse WS23xx`.

#### polling_interval

The `polling_interval` determines how often WeeWX will query the station for
data. If `polling_interval` is not specified (the default), WeeWX will
automatically use a polling interval based on the type of connection between
the station and the sensors (wired or wireless). When connected with a wire,
the console updates sensor data every 8 seconds. When connected wirelessly,
the console updates from 16 to 128 seconds, depending on sensor activity.


## [WS28xx]

This section is for options relating to the La Crosse WS-28xx series of
weather stations.

#### transceiver_frequency

Radio frequency to use between USB transceiver and console. Specify either
`US` or `EU`. `US` uses 915 MHz, `EU` uses 868.3 MHz. Default is `US`.

#### model

Set to the station model. For example, `LaCrosse WS2810`, `TFA Primus`, *etc*.
Default is `LaCrosse WS28xx`.
