robot

Dependencies:   FastPWM3 mbed

Revision:
26:955a1dfc2705
Parent:
25:3f2b585ae72d
Child:
27:7e073122ddf8
--- a/main.cpp	Sat Nov 05 15:49:11 2016 +0000
+++ b/main.cpp	Sun Nov 06 04:25:40 2016 +0000
@@ -85,7 +85,7 @@
 //fill in d, q ref based on torque cmd and current velocity
 void get_dq(float torque, float w, float *d, float *q) {
     *d = 0.0f;
-    *q = Q_MAX;//torque / KT < Q_MAX ? torque / KT : Q_MAX;
+    *q = torque / KT < Q_MAX ? torque / KT : Q_MAX;
 }
 
 void commutate() {