EW306 Motor Position Control with SVFB

Dependencies:   mbed mbedWSEsbc

Files at this revision

API Documentation at this revision

Comitter:
jdawkins
Date:
Thu Apr 11 13:46:38 2019 +0000
Parent:
2:a5d160c21ec4
Commit message:
Update Encoder Constant to 4096

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r a5d160c21ec4 -r 7e67c946f279 main.cpp
--- a/main.cpp	Wed Apr 10 13:43:06 2019 +0000
+++ b/main.cpp	Thu Apr 11 13:46:38 2019 +0000
@@ -88,7 +88,7 @@
                     float enc = (float)LS7366_read_counter(2);
                     
                     // Convert from counts to radians
-                    ang = 2*PI*enc/1024;
+                    ang = 2*PI*enc/4096;
                     
                     // Estimate States