Servo
Dependents: catchCats catchCats
Fork of Servo by
Revision 4:9188280ec20c, committed 2015-09-22
- Comitter:
- eunkyoungkim
- Date:
- Tue Sep 22 07:44:27 2015 +0000
- Parent:
- 3:36b69a7ced07
- Commit message:
- Catch cats - Toy of cats
Changed in this revision
Servo.cpp | Show annotated file Show diff for this revision Revisions of this file |
Servo.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/Servo.cpp Thu Sep 02 17:34:43 2010 +0000 +++ b/Servo.cpp Tue Sep 22 07:44:27 2015 +0000 @@ -24,7 +24,7 @@ #include "Servo.h" #include "mbed.h" -static float clamp(float value, float min, float max) { +static double clamp(float value, float min, float max) { if(value < min) { return min; } else if(value > max) { @@ -55,7 +55,7 @@ _degrees = degrees; } -float Servo::read() { +double Servo::read() { return _p; }
--- a/Servo.h Thu Sep 02 17:34:43 2010 +0000 +++ b/Servo.h Tue Sep 22 07:44:27 2015 +0000 @@ -68,7 +68,7 @@ * * @param returns A normalised number 0.0-1.0 representing the full range. */ - float read(); + double read(); /** Set the servo position *