Only need a sleep and wake since these DON'T use the default of powering up and down
- class Sensor
- The "Sensor" class is used for all sensor-level operations - waking, sleeping, and taking measurements.
Constructors, destructors, conversion operators
- String getSensorLocation(void ) override
- Get the pin or connection location between the mcu and the sensor.
- bool setup(void ) override
- Do any one-time preparations needed before the sensor will be able to take readings.
- bool startSingleMeasurement(void ) override
- Tell the sensor to start a single measurement, if needed.
- bool addSingleMeasurementResult(void ) override
- Get the results from a single measurement.
MaximDS3231(uint8_t measurementsToAverage = 1) explicit
Construct a new Maxim DS3231 object.
|measurementsToAverage||The number of measurements to take and average before giving a "final" result from the sensor; optional with a default value of 1.|
StringgetSensorLocation(void ) override
Get the pin or connection location between the mcu and the sensor.
|Returns||String Text describing how the sensor is attached to the mcu.|
boolsetup(void ) override
Do any one-time preparations needed before the sensor will be able to take readings.
|Returns||bool True if the setup was successful.|
This starts communication with the RTC (if it had not already been started). This will also turn off any interrupts currently scheduled on the RTC. The clock should be continuously powered, so we never need to worry about power up.
booladdSingleMeasurementResult(void ) override
Get the results from a single measurement.
|Returns||bool True if the function completed successfully.|
This asks the sensor for a new result, verifies that it passes sanity range checks, and then adds the value to the result array.