Creates an instance of the Anemometer class, which interfaces with a PCF8583 module.
A function that calculates WindSpeed based on pulse count and time.
Optional configuration options for the Anemometer.
Indicator of whether a connection has been established and the data is being read..
true
if the connection is ready; otherwise, false
.
Closes the i2c connection and stops the reading process.
A promise that resolves when the connection is successfully closed.
Calculates the average wind speed over a specified time period. The average wind speed is computed from the total pulses and the time span of the data records.
Optional time conditions to filter the data.
The average wind speed calculated from the data records.
Calculates the average wind speed of the past x seconds.
The offset for which to retrieve wind speed data.
The average WindSpeed data for the specified time.
Retrieves data records based on the specified conditions.
The conditions to filter and retrieve the data records.
An copied array of data records. Each record includes a value and a timestamp.
Finds the peak wind gust within a specified time period. The peak wind gust is determined by finding the largest increase in pulse values and the corresponding time span.
Optional time conditions to filter the data.
The peak wind gust calculated from the data records.
Opens the i2c connection and start the reading data.
A promise that resolves when the connection is successfully opened.
Represents an Anemometer device for measuring wind speed using a PCF8583 real-time clock module. This class allows you to read wind speed data, calculate wind speed values, and maintain a history of pulse counts to determine wind speed over time.