A Dummy Encoder implementation. More...
#include <FakeEncoder.hpp>
Public Member Functions | |
FakeEncoder (unsigned int resolution=4096, bool upcounting=true) | |
virtual int | positionGet () const |
Get the position within the current turn. | |
virtual int | turnGet () const |
Get the current turn. | |
virtual void | positionSet (int p) |
Set the position within the current turn. | |
virtual void | turnSet (int t) |
Set the current turn. | |
virtual int | resolution () const |
Return the position resolution. | |
virtual bool | upcounting () const |
Returns true if after a positive turn increment, position increments positively. |
A Dummy Encoder implementation.
Definition at line 38 of file FakeEncoder.hpp.
virtual int resolution | ( | ) | const [inline, virtual] |
Return the position resolution.
This number can be negative or positive and denotes the the maximal or minimal value positionGet().
Definition at line 76 of file FakeEncoder.hpp.
virtual bool upcounting | ( | ) | const [inline, virtual] |
Returns true if after a positive turn increment, position increments positively.
Meaning from 0 to |resolution()| or from resolution() to zero if resolution() < 0
Definition at line 84 of file FakeEncoder.hpp.