Class AdvancedRealtimeDataContainer

The more feature rich version of the realtime data container providing HighsAndLows and DetailedRealtimeData. Only works on Vantage Pro 2 and Vue (having firmware dated after April 24, 2002 / v1.90 or above).

What are realtime data containers?

Realtime data containers provide another level of abstraction to interact with your weather station. Instead of manually calling methods like WeatherStationAdvanced.getHighsAndLows or WeatherStationAdvanced.getDetailedRealtimeData, you just access the attributes of an instance of this class. E.g. to get the current outside temperature you just create a realtime interface and access it using realtime.tempOut.

Internally this works via an update cycle. Every container.settings.updateInterval seconds the interface requests data from your weather station to update its attributes. As the realtime interface is an EventEmitter, you can listen to the "update" event. Additionally there is the "valid-update" event which only fires if no error occurrs.

Hierarchy

Implements

Constructors

Properties

altimeter: null | number = null

The altimeter setting

chill: null | number = null

The current wind chill

consoleBatteryVoltage: null | number = null

The console's battery voltage

dew: null | number = null

The calculated dew point

etDay: null | number = null

Measured evapotranspiration (ET) of the day

etMonth: null | number = null

Measured evapotranspiration (ET) in the current month

etYear: null | number = null

Measured evapotranspiration (ET) in the current year

forecast: null | "Mostly Clear" | "Partly Cloudy" | "Mostly Cloudy" | "Mostly Cloudy, Rain within 12 hours" | "Mostly Cloudy, Snow within 12 hours" | "Mostly Cloudy, Rain or Snow within 12 hours" | "Partly Cloudy, Rain within 12 hours" | "Partly Cloudy, Snow within 12 hours" | "Partly Cloudy, Rain or Snow within 12 hours" = null

Current forecast computed by the connected vantage console

There are the following options:

  • Sun
  • Partly Cloudy
  • Mostly Cloudy
  • Mostly Cloudy, Rain within 12 hours
  • Mostly Cloudy, Snow within 12 hours
  • Partly Cloudy, Rain or Snow within 12 hours
  • Partly Cloudy, Rain within 12 hours
  • Partly Cloudy, Snow within 12 hours
  • Partly Cloudy, Rain or Snow within 12 hours
forecastID: null | 2 | 3 | 7 | 8 | 6 | 18 | 19 | 22 | 23 = null

The calculated forecast encoded as number:

  • 8 => Mostly Clear
  • 6 => Partly Cloudy
  • 2 => Mostly Cloudy
  • 3 => Mostly Cloudy, Rain within 12 hours
  • 18 => Mostly Cloudy, Snow within 12 hours
  • 19 => Partly Cloudy, Rain or Snow within 12 hours
  • 7 => Partly Cloudy, Rain within 12 hours
  • 22 => Partly Cloudy, Snow within 12 hours
  • 23 => Partly Cloudy, Rain or Snow within 12 hours
forecastRule: null | number = null

Not documented. Please create an issue on github if you know more about this.

heat: null | number = null

The measured heat index

highsAndLows: HighsAndLows = ...

Holds daily, monthly and yearly highs and lows for all weather elements / sensors.

humExtra: [null | number, null | number, null | number, null | number, null | number, null | number, null | number] = ...

Measured extra humidities (from up to 7 sensors)

humIn: null | number = null

Current inside humidity in percent

humOut: null | number = null

Current outside humidity in percent

leafTemps: [null | number, null | number, null | number, null | number] = ...

Measured leaf temperatures (from up to 4 sensors)

leafWetnesses: [null | number, null | number, null | number, null | number] = ...

Measured leaf wetness from up to 4 sensors

press: null | number = null

Current pressure

pressAbs: null | number = null

Absolute barometric pressure. Equals to the raw sensor (pressRaw) reading plus user entered offset (pressUserOffset).

pressCalibrationOffset: null | number = null

The barometer calibration number

pressRaw: null | number = null

Barometric sensor raw reading

pressReductionMethod: null | "user offset" | "altimeter setting" | "NOAA bar reduction" = null

The used barometric reduction method to calculate the ground pressure. There are three different settings:

  • user offset
  • altimeter setting
  • NOAA bar reduction
pressReductionMethodID: null | 0 | 1 | 2 = null

The used barometric reduction method encoded as number. 0 is user offset, 1 is altimeter setting and 2 is NOAA bar reduction.

pressTrend: null | "Falling Rapidly" | "Falling Slowly" | "Steady" | "Rising Slowly" | "Rising Rapidly" = null

The pressure's trend. There are five possible trends:

  • Falling Rapidly
  • Falling Slowly
  • Steady
  • Rising Slowly
  • Rising Rapidly
pressTrendID: null | 0 | 60 | -60 | 20 | -20 = null

The pressure's trend encoded as number.

  • -60 stands for Falling Rapidly
  • -20 stands for Falling Slowly
  • 0 stands for Steady
  • 20 stands for Rising Slowly
  • 60 stands for Rising Rapidly
pressUserOffset: null | number = null

The user-entered barometric offset

rain15m: null | number = null

The amount of rain that has fallen in the recent 15 minutes

rain1h: null | number = null

The amount of rain that has fallen in the recent hour

rain24h: null | number = null

The amount of rain that has fallen in the recent 24 hours

rainDay: null | number = null

The amount of rain that fell today

rainMonth: null | number = null

The amount of rain that has fallen in this month

rainRate: null | number = null

The current rain rate

rainYear: null | number = null

The amount of rain that has fallen in this year

The realtime interface's settings. Immutable.

soilMoistures: [null | number, null | number, null | number, null | number] = ...

Measured soil moisture from up to 4 sensors

soilTemps: [null | number, null | number, null | number, null | number] = ...

Measured soil temperatures (from up to 4 sensors)

solarRadiation: null | number = null

Currently measured solar radiation

stormRain: null | number = null

The most recent rainstorm's amount of rain

stormStartDate: null | Date = null

The most recent rainstorm's start date (without time)

sunrise: null | Date = null

The today's sunrise time (e.g. "06:35")

sunset: null | Date = null

The today's sunset time (e.g. "19:35")

tempExtra: [null | number, null | number, null | number, null | number, null | number, null | number, null | number] = ...

Measured extra temperatures (from up to 7 sensors)

tempIn: null | number = null

Current inside temperature (the console's temperature)

tempOut: null | number = null

Current outside temperature

thsw: null | number = null

The currently measured THSW index. Requires a solar radiation sensor.

time: Date = ...

The time the record was created

transmitterBatteryStatus: null | number = null

The transmitter's battery status (poorly documented)

uv: null | number = null

Currently measured UV index

wind: null | number = null

Currently measured wind speed

windAvg10m: null | number = null

Average wind speed in the recent ten minutes

windAvg2m: null | number = null

Average wind speed in the recent two minutes

windDir: null | "NNE" | "NE" | "ENE" | "E" | "ESE" | "SE" | "SSE" | "S" | "SSW" | "SW" | "WSW" | "W" | "WNW" | "NW" | "NNW" | "N" = null

Currently measured wind direction encoded as string. Possible values are:

  • NNE
  • NE
  • ENE
  • E
  • ESE
  • SE
  • SSE
  • S
  • SSW
  • SW
  • WSW
  • W
  • WNW
  • NW
  • NNW
  • N
windDirDeg: null | number = null

The wind speed direction in degrees (from 1 to 360). 90° is East, 180° is South, 270°is West and 360° is North.

windGust: null | number = null

Speed of the heaviest gust in the recent 10 minutes

windGustDir: null | "NNE" | "NE" | "ENE" | "E" | "ESE" | "SE" | "SSE" | "S" | "SSW" | "SW" | "WSW" | "W" | "WNW" | "NW" | "NNW" | "N" = null

The heaviest wind gust's (windGust) direction encoded as string. Possible values are:

  • NNE
  • NE
  • ENE
  • E
  • ESE
  • SE
  • SSE
  • S
  • SSW
  • SW
  • WSW
  • W
  • WNW
  • NW
  • NNW
  • N
windGustDirDeg: null | number = null

The heaviest wind gust's (windGust) direction in degrees (from 1 to 360). 90° is East, 180° is South, 270°is West and 360° is North.

defaultMaxListeners: number

By default, a maximum of 10 listeners can be registered for any single event. This limit can be changed for individual realtime interface instances using the setMaxListeners method.

To change the default for all instances, this property can be used. If this value is not a positive number, a RangeError is thrown.

Methods

  • Synchronously calls each of the listeners registered for the event eventName, in the order they were registered, passing the supplied arguments to each. Returns true if the event had listeners, false otherwise.

    Type Parameters

    Parameters

    Returns boolean

    whether the event had listeners

  • Returns an array listing the events for which the realtime interface has registered listeners.

    Type Parameters

    Returns U[]

    an array listing the events for which the realtime interface has registered listeners

  • Waits for the next update on the realtime interface. If an error occurrs while updating an error is returned (not thrown!). This can be used to handle errors optionally. See RealtimeInterfaceEvents.

    Returns Promise<any>

    Example

    const err = await container.waitForUpdate();
    

Generated using TypeDoc