buat ambil data dribbler
Dependencies: cmps_dagoz motor_dagoz encoder_dagoz ros_lib_kinetic EncoderMotorInterrupt
Constanta.h@1:3cc942422d2f, 2019-02-09 (annotated)
- Committer:
- calmantara186
- Date:
- Sat Feb 09 13:27:40 2019 +0000
- Revision:
- 1:3cc942422d2f
initial commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
calmantara186 | 1:3cc942422d2f | 1 | #ifndef CONSTANTA_H |
calmantara186 | 1:3cc942422d2f | 2 | #define CONSTANTA_H |
calmantara186 | 1:3cc942422d2f | 3 | |
calmantara186 | 1:3cc942422d2f | 4 | #include "mbed.h" |
calmantara186 | 1:3cc942422d2f | 5 | /***************************** |
calmantara186 | 1:3cc942422d2f | 6 | CONSTANTS |
calmantara186 | 1:3cc942422d2f | 7 | *****************************/ |
calmantara186 | 1:3cc942422d2f | 8 | // Robot Components |
calmantara186 | 1:3cc942422d2f | 9 | const double PI = 3.141593; //PI constanta |
calmantara186 | 1:3cc942422d2f | 10 | const double LOCOMOTIONWHEEL = 0.05; //Metres |
calmantara186 | 1:3cc942422d2f | 11 | const double DRIBBLERWHEEL = 0.035; //Metres |
calmantara186 | 1:3cc942422d2f | 12 | // Locomotion Components |
calmantara186 | 1:3cc942422d2f | 13 | const float KVFF = 1.0; //Velocity Feedforward for Locomotion |
calmantara186 | 1:3cc942422d2f | 14 | const float KAFF = 1.0; //Acceleration Feedforward for Locomotion |
calmantara186 | 1:3cc942422d2f | 15 | const float ACCT = 2.0; //Acceleration for robot Translation |
calmantara186 | 1:3cc942422d2f | 16 | const float ACCR = 2.0; //Acceleration for robot rotation |
calmantara186 | 1:3cc942422d2f | 17 | // Right Dribbler Components |
calmantara186 | 1:3cc942422d2f | 18 | const float RK1FB = 1.0; //Right Dribbler Pot to Omega feedback |
calmantara186 | 1:3cc942422d2f | 19 | const float RK2FB = 1.0; //Right Dribbler Error to pwm feedback |
calmantara186 | 1:3cc942422d2f | 20 | const float RKVFF = 1.0; //Right Dribbler velocity feedforward |
calmantara186 | 1:3cc942422d2f | 21 | const float RKXFF = 1.0; //Right Dribbler x velocity feedforward |
calmantara186 | 1:3cc942422d2f | 22 | const float RKYFF = 1.0; //Right Dribbler y velocity feedforward |
calmantara186 | 1:3cc942422d2f | 23 | const float RKTFF = 1.0; //Right Dribbler w velocity feedforward |
calmantara186 | 1:3cc942422d2f | 24 | const float RTARGET = 1.0; //Right Dribbler potensio target |
calmantara186 | 1:3cc942422d2f | 25 | // Left Dribbler Components |
calmantara186 | 1:3cc942422d2f | 26 | const float LK1FB = 1.0; //Left Dribbler Pot to Omega feedback |
calmantara186 | 1:3cc942422d2f | 27 | const float LK2FB = 1.0; //Left Dribbler Error to pwm feedback |
calmantara186 | 1:3cc942422d2f | 28 | const float LKVFF = 1.0; //Left Dribbler velocity feedforward |
calmantara186 | 1:3cc942422d2f | 29 | const float LKXFF = 1.0; //Left Dribbler x velocity feedforward |
calmantara186 | 1:3cc942422d2f | 30 | const float LKYFF = 1.0; //Left Dribbler y velocity feedforward |
calmantara186 | 1:3cc942422d2f | 31 | const float LKTFF = 1.0; //Left Dribbler w velocity feedforward |
calmantara186 | 1:3cc942422d2f | 32 | const float LTARGET = 1.0; //Left Dribbler potensio target |
calmantara186 | 1:3cc942422d2f | 33 | /***************************** |
calmantara186 | 1:3cc942422d2f | 34 | Global Variable |
calmantara186 | 1:3cc942422d2f | 35 | *****************************/ |
calmantara186 | 1:3cc942422d2f | 36 | //Compass Global Varible |
calmantara186 | 1:3cc942422d2f | 37 | float compassValue = 0; //Compass value |
calmantara186 | 1:3cc942422d2f | 38 | //Odometry global variable |
calmantara186 | 1:3cc942422d2f | 39 | double locomotionRVel = 0; |
calmantara186 | 1:3cc942422d2f | 40 | double locomotionLVel = 0; |
calmantara186 | 1:3cc942422d2f | 41 | double locomotionBVel = 0; |
calmantara186 | 1:3cc942422d2f | 42 | double locomotionRRot = 0; |
calmantara186 | 1:3cc942422d2f | 43 | double locomotionLRot = 0; |
calmantara186 | 1:3cc942422d2f | 44 | double locomotionBRot = 0; |
calmantara186 | 1:3cc942422d2f | 45 | double locomotionRVtarget = 0; |
calmantara186 | 1:3cc942422d2f | 46 | double locomotionLVtarget = 0; |
calmantara186 | 1:3cc942422d2f | 47 | double locomotionBVtarget = 0; |
calmantara186 | 1:3cc942422d2f | 48 | //Dribbler global variabel |
calmantara186 | 1:3cc942422d2f | 49 | double dribblerRVel = 0; |
calmantara186 | 1:3cc942422d2f | 50 | double dribblerLVel = 0; |
calmantara186 | 1:3cc942422d2f | 51 | double dribblerRRot = 0; |
calmantara186 | 1:3cc942422d2f | 52 | double dribblerLRot = 0; |
calmantara186 | 1:3cc942422d2f | 53 | double dribblerRVtarget = 0; |
calmantara186 | 1:3cc942422d2f | 54 | double dribblerLVtarget = 0; |
calmantara186 | 1:3cc942422d2f | 55 | //Kicker global variable |
calmantara186 | 1:3cc942422d2f | 56 | double kickPowerTarget = 0; |
calmantara186 | 1:3cc942422d2f | 57 | float distance = 0; |
calmantara186 | 1:3cc942422d2f | 58 | |
calmantara186 | 1:3cc942422d2f | 59 | #endif |