mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-22 02:32:23 +00:00
18 lines
484 B
C
18 lines
484 B
C
|
|
#include "../mesh/generated/meshtastic/telemetry.pb.h"
|
||
|
|
#include "TelemetrySensor.h"
|
||
|
|
#include "VoltageSensor.h"
|
||
|
|
|
||
|
|
class RAK9154Sensor : public TelemetrySensor, VoltageSensor
|
||
|
|
{
|
||
|
|
private:
|
||
|
|
protected:
|
||
|
|
virtual void setup() override;
|
||
|
|
|
||
|
|
public:
|
||
|
|
RAK9154Sensor();
|
||
|
|
virtual int32_t runOnce() override;
|
||
|
|
virtual bool getMetrics(meshtastic_Telemetry *measurement) override;
|
||
|
|
virtual uint16_t getBusVoltageMv() override;
|
||
|
|
int getBusBatteryPercent();
|
||
|
|
bool isCharging();
|
||
|
|
};
|