Modified Motor Driver Firmware to include Flash + Thermal
Dependencies: FastPWM3 mbed-dev-STM-lean
Config/motor_config_U12.h@60:0c8caaa91182, 2020-11-02 (annotated)
- Committer:
- saloutos
- Date:
- Mon Nov 02 20:08:14 2020 +0000
- Revision:
- 60:0c8caaa91182
- Parent:
- Config/motor_config.h@58:32e8927fe39f
- Child:
- 61:33f2dc2b589f
Split motor config files for U10, U12. Will need another file for the R60 motor eventually
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
benkatz | 20:bf9ea5125d52 | 1 | #ifndef MOTOR_CONFIG_H |
benkatz | 20:bf9ea5125d52 | 2 | #define MOTOR_CONFIG_H |
benkatz | 20:bf9ea5125d52 | 3 | |
saloutos | 60:0c8caaa91182 | 4 | // WHOLE FILE NEEDS UPDATING FOR U12 MOTORS |
saloutos | 60:0c8caaa91182 | 5 | |
saloutos | 58:32e8927fe39f | 6 | #define R_PHASE 0.4f //approx with multimeter //0.13f //Ohms |
saloutos | 58:32e8927fe39f | 7 | #define L_D 0.00008f //needs update //Henries |
saloutos | 58:32e8927fe39f | 8 | #define L_Q 0.00008f //needs update //Henries |
saloutos | 58:32e8927fe39f | 9 | #define KT 0.0398f // correct? //.075f //N-m per peak phase amp, = WB*NPP*3/2 |
saloutos | 58:32e8927fe39f | 10 | #define NPP 21 //11 //Number of pole pairs |
saloutos | 58:32e8927fe39f | 11 | #define GR 6.0f //2.0f //Gear ratio |
saloutos | 58:32e8927fe39f | 12 | #define KT_OUT 0.239f //0.036f //KT*GR |
saloutos | 58:32e8927fe39f | 13 | #define WB 0.0013 // from KT //0.00287f //Flux linkage, Webers. |
saloutos | 58:32e8927fe39f | 14 | #define R_TH 1.25f //needs update //Kelvin per watt |
saloutos | 58:32e8927fe39f | 15 | #define INV_M_TH 0.02825f //needs update //Kelvin per joule |
saloutos | 58:32e8927fe39f | 16 | #define T_AMBIENT 25.0f // ambient temperature during temp calibration |
benkatz | 22:60276ba87ac6 | 17 | |
saloutos | 58:32e8927fe39f | 18 | // new motor has KV40 ...use to calculate Kt |
benkatz | 20:bf9ea5125d52 | 19 | |
saloutos | 58:32e8927fe39f | 20 | // new actuator has 36 stator slots, 42 pole magnets |
saloutos | 58:32e8927fe39f | 21 | // so, 21 elec revs per mech rev |
saloutos | 58:32e8927fe39f | 22 | // 36*21 steps per elec rev if using traditional commutation |
benkatz | 20:bf9ea5125d52 | 23 | |
benkatz | 20:bf9ea5125d52 | 24 | #endif |