Software usado para produção de dois movimentos trapezoidais consecutivos.

Dependencies:   mbed X_NUCLEO_IHM01A1

Files at this revision

API Documentation at this revision

Comitter:
jonasl1
Date:
Wed Oct 27 02:53:07 2021 +0000
Parent:
38:3e9aca2ce6c5
Commit message:
Cod correto

Changed in this revision

main_APS2_MEA.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r 3e9aca2ce6c5 -r a932189cfaa6 main_APS2_MEA.cpp
--- a/main_APS2_MEA.cpp	Tue Oct 26 12:09:18 2021 +0000
+++ b/main_APS2_MEA.cpp	Wed Oct 27 02:53:07 2021 +0000
@@ -14,7 +14,7 @@
 InterruptIn user_b(USER_BUTTON);
 
 /* Number of steps. */
-#define STEPS_1 1600   /* 1 revolution given a 400 steps motor configured at 1/8 microstep mode. */
+#define STEPS_1 800   /* 1 revolution given a 400 steps motor configured at 1/8 microstep mode. */
 
 /* Delay in milliseconds. */
 #define DELAY_1 1000
@@ -38,7 +38,7 @@
 L6474_init_t init = {
     1000,                              /* Acceleration rate in pps^2. Range: (0..+inf). */
     1000,                              /* Deceleration rate in pps^2. Range: (0..+inf). */
-    1000,                             /* Maximum speed in pps. Range: (30..10000]. */
+    800,                             /* Maximum speed in pps. Range: (30..10000]. */
     0,                              /* Minimum speed in pps. Range: [30..10000). */
     250,                              /* Torque regulation current in mA. Range: 31.25mA to 4000mA. */
     L6474_OCD_TH_750mA,               /* Overcurrent threshold (OCD_TH register). */