IQRF Gateway Daemon
Public Types | Public Member Functions | Static Public Attributes | List of all members
PrfPulseMeter Class Reference

#include <PrfPulseMeter.h>

Inheritance diagram for PrfPulseMeter:
PrfPulseMeterJson

Public Types

enum  Cmd { Cmd::READ_COUNTERS = 0, Cmd::STORE_COUNTER = 1, Cmd::DISABLE_AUTO_SLEEP = 2 }
 
enum  FrcCmd { FrcCmd::ALIVE = 0, FrcCmd::ALIVE_STOP_AUTOSLEEP = 1, FrcCmd::ALIVE_START_AUTOSLEEP = 2 }
 
enum  CntNum { CntNum::CNT_1 = 1, CntNum::CNT_2 = 2 }
 

Public Member Functions

 PrfPulseMeter ()
 
virtual ~PrfPulseMeter ()
 
void commandReadCounters (const std::chrono::seconds &sec)
 
void commandStoreCounter (CntNum cntNum, uint32_t value)
 
void commandDisableAutosleep (bool enable)
 
void parseResponse (const DpaMessage &response) override
 
void parseCommand (const std::string &command) override
 
const std::string & encodeCommand () const override
 
uint8_t getThermometerType () const
 
double getTemperature () const
 
uint8_t getPowerVoltageType () const
 
double getPowerVoltage () const
 
double getIqrfSuplyVoltage () const
 
int getRssi () const
 
int getCntLen () const
 
int getCnts () const
 
int getCounter (CntNum cntNum) const
 
uint8_t getCntSum () const
 
uint8_t getDataSum () const
 
bool getStoreCounterResult () const
 
bool getDisableAutosleepResult () const
 
Cmd getCmd () const
 

Static Public Attributes

static const std::string PRF_NAME
 

Detailed Description

Copyright 2016-2017 MICRORISC s.r.o.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Member Enumeration Documentation

◆ Cmd

enum PrfPulseMeter::Cmd
strong
Enumerator
READ_COUNTERS 
STORE_COUNTER 
DISABLE_AUTO_SLEEP 

◆ CntNum

enum PrfPulseMeter::CntNum
strong
Enumerator
CNT_1 
CNT_2 

◆ FrcCmd

enum PrfPulseMeter::FrcCmd
strong
Enumerator
ALIVE 
ALIVE_STOP_AUTOSLEEP 
ALIVE_START_AUTOSLEEP 

Constructor & Destructor Documentation

◆ PrfPulseMeter()

PrfPulseMeter::PrfPulseMeter ( )

◆ ~PrfPulseMeter()

PrfPulseMeter::~PrfPulseMeter ( )
virtual

Member Function Documentation

◆ commandDisableAutosleep()

void PrfPulseMeter::commandDisableAutosleep ( bool  enable)

◆ commandReadCounters()

void PrfPulseMeter::commandReadCounters ( const std::chrono::seconds &  sec)

◆ commandStoreCounter()

void PrfPulseMeter::commandStoreCounter ( CntNum  cntNum,
uint32_t  value 
)

◆ encodeCommand()

const std::string & PrfPulseMeter::encodeCommand ( ) const
override

◆ getCmd()

PrfPulseMeter::Cmd PrfPulseMeter::getCmd ( ) const

◆ getCntLen()

int PrfPulseMeter::getCntLen ( ) const
inline

◆ getCnts()

int PrfPulseMeter::getCnts ( ) const
inline

◆ getCntSum()

uint8_t PrfPulseMeter::getCntSum ( ) const
inline

◆ getCounter()

int PrfPulseMeter::getCounter ( CntNum  cntNum) const

◆ getDataSum()

uint8_t PrfPulseMeter::getDataSum ( ) const
inline

◆ getDisableAutosleepResult()

bool PrfPulseMeter::getDisableAutosleepResult ( ) const
inline

◆ getIqrfSuplyVoltage()

double PrfPulseMeter::getIqrfSuplyVoltage ( ) const
inline

◆ getPowerVoltage()

double PrfPulseMeter::getPowerVoltage ( ) const
inline

◆ getPowerVoltageType()

uint8_t PrfPulseMeter::getPowerVoltageType ( ) const
inline

◆ getRssi()

int PrfPulseMeter::getRssi ( ) const
inline

◆ getStoreCounterResult()

bool PrfPulseMeter::getStoreCounterResult ( ) const
inline

◆ getTemperature()

double PrfPulseMeter::getTemperature ( ) const
inline

◆ getThermometerType()

uint8_t PrfPulseMeter::getThermometerType ( ) const
inline

◆ parseCommand()

void PrfPulseMeter::parseCommand ( const std::string &  command)
override

◆ parseResponse()

void PrfPulseMeter::parseResponse ( const DpaMessage &  response)
override

Member Data Documentation

◆ PRF_NAME

const std::string PrfPulseMeter::PRF_NAME
static

Copyright 2016-2017 MICRORISC s.r.o.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.


The documentation for this class was generated from the following files: