.
Dependencies: L432KC_SPI_Pey_Lal
main.hpp@114:c1f7be27aa5d, 2022-05-18 (annotated)
- Committer:
- voltxd
- Date:
- Wed May 18 16:12:59 2022 +0000
- Revision:
- 114:c1f7be27aa5d
ratio;
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
voltxd | 114:c1f7be27aa5d | 1 | #ifndef MAIN_HPP |
voltxd | 114:c1f7be27aa5d | 2 | #define MAIN_HPP |
voltxd | 114:c1f7be27aa5d | 3 | |
voltxd | 114:c1f7be27aa5d | 4 | //Define PWM |
voltxd | 114:c1f7be27aa5d | 5 | #define PWM_PROP D9 |
voltxd | 114:c1f7be27aa5d | 6 | #define PWM_DIR D10 |
voltxd | 114:c1f7be27aa5d | 7 | |
voltxd | 114:c1f7be27aa5d | 8 | //Define interrupt Input |
voltxd | 114:c1f7be27aa5d | 9 | #define SPEED_CAPTOR A4 |
voltxd | 114:c1f7be27aa5d | 10 | |
voltxd | 114:c1f7be27aa5d | 11 | //Define COEF |
voltxd | 114:c1f7be27aa5d | 12 | #define POINT_PER_TURN 5.0 |
voltxd | 114:c1f7be27aa5d | 13 | #define WHEEL_DIAMETER 0.069 |
voltxd | 114:c1f7be27aa5d | 14 | #define DISTANCE_FOR_HALF_TURN (PI * WHEEL_DIAMETER / POINT_PER_TURN) //TODO: mettre vrai valeur |
voltxd | 114:c1f7be27aa5d | 15 | #define CONTROL_RATE 1000.0 |
voltxd | 114:c1f7be27aa5d | 16 | |
voltxd | 114:c1f7be27aa5d | 17 | //fontion interrupt |
voltxd | 114:c1f7be27aa5d | 18 | void onRxInterrupt(); |
voltxd | 114:c1f7be27aa5d | 19 | void onSpeedCaptorInterrupt(); |
voltxd | 114:c1f7be27aa5d | 20 | void onTickerAsservissementInterrupt(); |
voltxd | 114:c1f7be27aa5d | 21 | |
voltxd | 114:c1f7be27aa5d | 22 | #endif |