EEROS  0.4.1.0
API for the EEROS Real-Time Robotics Framework
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
SysFsDigOut.hpp
Go to the documentation of this file.
1 #ifndef ORG_EEROS_HAL_SYSFSDIGOUT_HPP_
2 #define ORG_EEROS_HAL_SYSFSDIGOUT_HPP_
3 
5 #include <fstream>
6 #include <string>
7 
8 namespace eeros {
9  namespace hal {
10  class SysFsDigOut : public PeripheralOutput<bool> {
11  public:
12  SysFsDigOut(std::string id, unsigned int gpio, bool inverted = false);
13  ~SysFsDigOut();
14  virtual bool get();
15  virtual void set(bool value);
16 
17  private:
18  bool inverted;
19  std::string basePath;
20  std::fstream valueFile;
21  };
22 
23  };
24 };
25 
26 #endif /* ORG_EEROS_HAL_SYSFSDIGOUT_HPP_ */
Definition: PeripheralOutput.hpp:17
virtual void set(bool value)
Definition: SysFsDigOut.cpp:44
SysFsDigOut(std::string id, unsigned int gpio, bool inverted=false)
Definition: SysFsDigOut.cpp:6
Definition: SysFsDigOut.hpp:10
~SysFsDigOut()
Definition: SysFsDigOut.cpp:33