Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: NaturalTinyShell_ice libmDot-12Sept mbed-rtos mbed
Fork of ICE by
src/ConfigurationHandler/Controls/ManualControl.h
- Committer:
- jmarkel44
- Date:
- 2016-09-30
- Revision:
- 164:7cecd731882e
- Parent:
- 131:a290a3934132
- Child:
- 217:d5a2ff093319
File content as of revision 164:7cecd731882e:
/******************************************************************************
*
* File: ManualControl.h
* Desciption: ICE Manual Control Class
*
*****************************************************************************/
#ifndef MANUALCONTROL_H
#define MANUALCONTROL_H
#include <string>
using namespace std;
class ManualControl
{
private:
string controlFile; // name of the control file
string id; // identifier
string output; // output
unsigned int type; // timed, continuous, setpoint
unsigned int priority; // control priority
unsigned int duration;
float setpoint;
unsigned int state; // ON or OFF
unsigned int percent; // analog/manual value
enum State {
STATE_INIT,
STATE_STARTUP,
STATE_CONTROL_ON,
STATE_CONTROL_OFF
};
State currentState;
public:
ManualControl() {};
~ManualControl() {
printf("\r%s destructor invoked\n", __func__);
}
// load a control from the control file
bool load(string filename);
string getControlFile(void) const {
return controlFile;
}
void start(void);
int update(void);
int powerOutput(void);
int unregisterControl();
void display(void);
};
#endif
