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: mbed-rtos mbed QEI BNO055 MPU6050_DMP_Nucleo-I2Cdev virgo3_imuHandler MAX17048 Servo MODSERIAL
Fork of Orion_PCB_test_Faulhaber_gear_ratio41_waypoint_cmd by
02_Localization/localization.h@5:099cb2e76c7d, 2016-01-25 (annotated)
- Committer:
- akashvibhute
- Date:
- Mon Jan 25 07:28:40 2016 +0000
- Revision:
- 5:099cb2e76c7d
- Parent:
- 2:761e3c932ce0
all threads populated
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| akashvibhute | 2:761e3c932ce0 | 1 | #ifndef localization_H |
| akashvibhute | 2:761e3c932ce0 | 2 | #define localization_H |
| akashvibhute | 2:761e3c932ce0 | 3 | |
| akashvibhute | 5:099cb2e76c7d | 4 | #include "mbed.h" |
| akashvibhute | 2:761e3c932ce0 | 5 | #include "generalFunctions.h" |
| akashvibhute | 5:099cb2e76c7d | 6 | #include "config.h" |
| akashvibhute | 5:099cb2e76c7d | 7 | |
| akashvibhute | 2:761e3c932ce0 | 8 | |
| akashvibhute | 2:761e3c932ce0 | 9 | class localization |
| akashvibhute | 2:761e3c932ce0 | 10 | { |
| akashvibhute | 2:761e3c932ce0 | 11 | public: |
| akashvibhute | 5:099cb2e76c7d | 12 | localization(); |
| akashvibhute | 2:761e3c932ce0 | 13 | void getPosition(float *position_out[2], float heading, float revolutions[2]); //[x,y] position, heading in rad |
| akashvibhute | 2:761e3c932ce0 | 14 | void setPosition(float position_in[2]); //[x,y] position |
| akashvibhute | 2:761e3c932ce0 | 15 | |
| akashvibhute | 2:761e3c932ce0 | 16 | private: |
| akashvibhute | 2:761e3c932ce0 | 17 | float position[2]; |
| akashvibhute | 2:761e3c932ce0 | 18 | float prevRevolutions[2]; //store previous iteration's revolutions |
| akashvibhute | 2:761e3c932ce0 | 19 | float wheelDia; |
| akashvibhute | 2:761e3c932ce0 | 20 | float trackWidth; |
| akashvibhute | 2:761e3c932ce0 | 21 | float incrementalDistance; |
| akashvibhute | 2:761e3c932ce0 | 22 | }; |
| akashvibhute | 2:761e3c932ce0 | 23 | |
| akashvibhute | 2:761e3c932ce0 | 24 | |
| akashvibhute | 2:761e3c932ce0 | 25 | #endif |
