Totale Testversion
Dependencies: mbed
Fork of DrehungMitStopp by
Diff: MotorEncoder.h
- Revision:
- 1:d40ff07e2fe0
diff -r 96f88638114b -r d40ff07e2fe0 MotorEncoder.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/MotorEncoder.h Wed May 10 09:14:12 2017 +0000 @@ -0,0 +1,23 @@ +#ifndef MOTOR_ENCODER_H +#define MOTOR_ENCODER_H + +#include <cstdlib> +#include <mbed.h> + +//E. Hess +//MotorEncoder.h + +class MotorEncoder { + public: + MotorEncoder(PinName a, PinName b); + virtual ~MotorEncoder(); + void reset(); + void reset(short offset); + short read(); + operator short(); + + private: + TIM_TypeDef* TIM; +}; + +#endif \ No newline at end of file