2024-06-14 16:27:49 -05:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#ifndef _MT_DFROBOTLARKSENSOR_H
|
|
|
|
|
#define _MT_DFROBOTLARKSENSOR_H
|
2024-06-03 21:50:28 -05:00
|
|
|
#include "configuration.h"
|
|
|
|
|
|
|
|
|
|
#if !MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR
|
|
|
|
|
|
|
|
|
|
#include "../mesh/generated/meshtastic/telemetry.pb.h"
|
|
|
|
|
#include "TelemetrySensor.h"
|
|
|
|
|
#include <DFRobot_LarkWeatherStation.h>
|
|
|
|
|
#include <string>
|
|
|
|
|
|
|
|
|
|
class DFRobotLarkSensor : public TelemetrySensor
|
|
|
|
|
{
|
|
|
|
|
private:
|
|
|
|
|
DFRobot_LarkWeatherStation_I2C lark = DFRobot_LarkWeatherStation_I2C();
|
|
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
virtual void setup() override;
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
DFRobotLarkSensor();
|
|
|
|
|
virtual int32_t runOnce() override;
|
|
|
|
|
virtual bool getMetrics(meshtastic_Telemetry *measurement) override;
|
|
|
|
|
};
|
|
|
|
|
|
2024-06-14 16:27:49 -05:00
|
|
|
#endif
|
2024-06-03 21:50:28 -05:00
|
|
|
#endif
|