You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
943 B
C++
47 lines
943 B
C++
/*
|
|
* FaultDecrease.h
|
|
*
|
|
* Author: Aleksey Gerasimenko
|
|
* gerasimenko.aleksey.n@gmail.com
|
|
*/
|
|
|
|
#include "Alert/AlertBase.h"
|
|
|
|
#ifndef ALERT_FAULTDECREASE_H_
|
|
#define ALERT_FAULTDECREASE_H_
|
|
|
|
namespace ALERT
|
|
{
|
|
|
|
class FaultDecrease: public ALERT::AlertBase
|
|
{
|
|
public:
|
|
// enum state_t {UNKNOWN, NORMAL, FAULT};
|
|
private:
|
|
// state_t m_state;
|
|
bool m_fault;
|
|
public:
|
|
bool fault;
|
|
public:
|
|
FaultDecrease();
|
|
void setup(float time_sample);
|
|
void configure(const ALERT::AlertBaseConfiguration& config);
|
|
public:
|
|
// state_t get_state() const;
|
|
// bool compare_state(state_t state) const;
|
|
// bool is_fault();
|
|
public:
|
|
void reset();
|
|
public:
|
|
void execute(float reference);
|
|
private:
|
|
void (FaultDecrease::*_execute)(float reference);
|
|
void _execute_undef(float reference);
|
|
void _execute_operational(float reference);
|
|
//
|
|
};//FaultDecrease()
|
|
|
|
} /* namespace ALERT */
|
|
|
|
#endif /* ALERT_FAULTDECREASE_H_ */
|