libwallaby  v24
The wallaby standard library
servo.hpp
Go to the documentation of this file.
1 /*
2  * servo.hpp
3  *
4  * Created on: Nov 5, 2015
5  * Author: Joshua Southerland
6  */
7 
8 #ifndef INCLUDE_WALLABY_SERVO_HPP_
9 #define INCLUDE_WALLABY_SERVO_HPP_
10 
11 class Servo
12 {
13 public:
14  typedef unsigned int ticks_t;
15 
16  Servo(int port);
17 
19 
20  ticks_t position() const;
21 
22  void disable();
23  void enable();
24  void setEnabled(bool enabled);
25  bool isEnabled() const;
26 private:
27  int m_port;
28 };
29 
30 #endif /* INCLUDE_WALLABY_SERVO_HPP_ */
Servo::position
ticks_t position() const
Servo::setPosition
void setPosition(ticks_t position)
Servo::setEnabled
void setEnabled(bool enabled)
Servo::ticks_t
unsigned int ticks_t
Definition: servo.hpp:14
Servo::isEnabled
bool isEnabled() const
Servo
Definition: servo.hpp:11
Servo::Servo
Servo(int port)
Servo::enable
void enable()
Servo::disable
void disable()