speedservo

Dependents:   nhk_auto_06

Files at this revision

API Documentation at this revision

Comitter:
kenken0721
Date:
Sat Jan 19 14:55:27 2019 +0000
Parent:
0:b583163ca5b3
Commit message:

Changed in this revision

speedservo.cpp Show annotated file Show diff for this revision Revisions of this file
speedservo.h Show annotated file Show diff for this revision Revisions of this file
--- a/speedservo.cpp	Fri Jan 18 03:57:28 2019 +0000
+++ b/speedservo.cpp	Sat Jan 19 14:55:27 2019 +0000
@@ -16,8 +16,9 @@
 
 }
 
-void Servo::SetPosition(int Pos)             //servo go to position
+void Servo::SetPosition(int Pos,int _speed)             //servo go to position
 {
+    SpeedConvert(_speed);
     NewPosition = Pos;
 }
 
--- a/speedservo.h	Fri Jan 18 03:57:28 2019 +0000
+++ b/speedservo.h	Sat Jan 19 14:55:27 2019 +0000
@@ -74,7 +74,7 @@
      *
      * @param NewPos The new value of the servos position (us)
      */
-    void SetPosition(int NewPos);
+    void SetPosition(int NewPos, int _speed);
     
     /** speed oonversion from arbitary range of 1-50 to us to set Ticker Speed rate.
     * used in Enable function