cleaned up motor class with separate header and .cpp files
Dependencies: mbed
Dependents: TerraBot_Drive_2D TerraBot_Drive_2D TerraBot_Drive_2D_FINAL DUMP_TRUCK_Test ... more
Motor.h
- Committer:
- simplyellow
- Date:
- 2016-10-24
- Revision:
- 2:7674afbf8e53
- Parent:
- 0:0a5af2965205
- Child:
- 4:e87768d3cd09
File content as of revision 2:7674afbf8e53:
#ifndef MOTOR_H #define MOTOR_H #include "mbed.h" class Motor { public: Motor(PinName pwm, PinName dir); void write(float Val); float read(); private: PwmOut pwmPin; DigitalOut dirPin; float lastVal; }; #endif