Mayu Wire Winding Setup With stepper motor ans Servos

Dependencies:   BufferedSerial Servo X_NUCLEO_IHM01A1 mbed

Fork of WireWinding_Stepper by Shock_Team

Revision:
26:d6a21152f6cc
Parent:
25:7f8fd0790b13
--- a/main.cpp	Mon May 23 14:23:19 2016 +0000
+++ b/main.cpp	Mon Dec 05 08:16:26 2016 +0000
@@ -38,7 +38,7 @@
 int32_t StepperSetPos=0;
 /* Number of steps to move. */
 #define STEPS2Rotation 3200
-
+#define NUM_Windings 750 //600 - first try
 
 Ticker ServoCorrect;
 /* Variables -----------------------------------------------------------------*/
@@ -166,7 +166,7 @@
     ServoCorrect.attach(&ServoUpdate,0.1f);
     
     /* Requesting to go to a specified position. */
-        StepperSetPos=600*STEPS2Rotation;
+        StepperSetPos=NUM_Windings*STEPS2Rotation;
         motor->GoTo(StepperSetPos);
         motor->WaitWhileActive();
         StepperPos = motor->GetPosition();