Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: FXOS8700CQ SDFileSystem mbed
Fork of AVC_Robot_Controled_Navigation by
lib/motors.h@0:3a322aad8c88, 2014-10-16 (annotated)
- Committer:
- gerardo_carmona
- Date:
- Thu Oct 16 01:59:21 2014 +0000
- Revision:
- 0:3a322aad8c88
First release.
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| gerardo_carmona | 0:3a322aad8c88 | 1 | #ifndef motors_h |
| gerardo_carmona | 0:3a322aad8c88 | 2 | #define motors_h |
| gerardo_carmona | 0:3a322aad8c88 | 3 | |
| gerardo_carmona | 0:3a322aad8c88 | 4 | // ----- Constants ------------------------------------------------------------------ |
| gerardo_carmona | 0:3a322aad8c88 | 5 | #define MOVE_FWD 'w' |
| gerardo_carmona | 0:3a322aad8c88 | 6 | #define MOVE_REV 's' |
| gerardo_carmona | 0:3a322aad8c88 | 7 | #define MOVE_LEF 'a' |
| gerardo_carmona | 0:3a322aad8c88 | 8 | #define MOVE_RIG 'd' |
| gerardo_carmona | 0:3a322aad8c88 | 9 | #define MOVE_STO 'q' |
| gerardo_carmona | 0:3a322aad8c88 | 10 | #define MOVE_90L 'o' |
| gerardo_carmona | 0:3a322aad8c88 | 11 | #define MOVE_90R 'p' |
| gerardo_carmona | 0:3a322aad8c88 | 12 | |
| gerardo_carmona | 0:3a322aad8c88 | 13 | // ----- Functions ------------------------------------------------------------------ |
| gerardo_carmona | 0:3a322aad8c88 | 14 | void move_motors(char _move_command, int _power_left, int _power_right); // Move motor function |
| gerardo_carmona | 0:3a322aad8c88 | 15 | void motor_fwd(int _power_left, int _power_right); |
| gerardo_carmona | 0:3a322aad8c88 | 16 | void motor_rev(int _power_left, int _power_right); |
| gerardo_carmona | 0:3a322aad8c88 | 17 | void motor_move_90(int direction); |
| gerardo_carmona | 0:3a322aad8c88 | 18 | void motor_left(int _power_left, int _power_right); |
| gerardo_carmona | 0:3a322aad8c88 | 19 | void motor_right(int _power_left, int _power_right); |
| gerardo_carmona | 0:3a322aad8c88 | 20 | void motor_stop(); |
| gerardo_carmona | 0:3a322aad8c88 | 21 | |
| gerardo_carmona | 0:3a322aad8c88 | 22 | #endif |
