robot

Dependencies:   FastPWM3 mbed

Committer:
bwang
Date:
Sun Nov 27 11:36:54 2016 +0000
Revision:
37:ba7ebf4f8a78
Parent:
36:cac9785c91cb
Child:
38:07cb4ae6c1bd
updated get_mtpa_dq to be always give the correct ratio of id to iq; NOT TESTED: switched get_dq to use the get_mtpa* functions as altermotter requires huge amounts of d-axis amps

Who changed what in which revision?

UserRevisionLine numberNew contents of line
bwang 15:b583cd30b063 1 #ifndef __CONFIG_MOTOR_H
bwang 15:b583cd30b063 2 #define __CONFIG_MOTOR_H
bwang 15:b583cd30b063 3
bwang 15:b583cd30b063 4 #define POLE_PAIRS 3.0f
bwang 24:5e18a87a0e95 5 #define POS_OFFSET 5.88f
bwang 15:b583cd30b063 6 #define RESOLVER_LOBES 3.0f
bwang 15:b583cd30b063 7 #define CPR 4096
bwang 29:50e6e4e46580 8
bwang 32:b31423041c4e 9 #define Ld 0.000876f //Henries
bwang 32:b31423041c4e 10 #define Lq 0.002068f
bwang 33:93a0d621a095 11 #define FLUX_LINKAGE 0.1f //Vs
bwang 30:c25c5bf0d951 12
bwang 36:cac9785c91cb 13 #define KT 0.6f //Nm/A -- filler value until the LUT is made
bwang 30:c25c5bf0d951 14
bwang 29:50e6e4e46580 15 #define W_LIMIT 1000.0f
bwang 29:50e6e4e46580 16
bwang 15:b583cd30b063 17 #define PI 3.141593f
bwang 15:b583cd30b063 18
bwang 15:b583cd30b063 19 #endif