Grundfunktionen für Micromouse
Dependencies: AutomationElements mbed
main.cpp@1:4808f55970e8, 2018-04-22 (annotated)
- Committer:
- wengefa1
- Date:
- Sun Apr 22 09:55:40 2018 +0000
- Revision:
- 1:4808f55970e8
- Parent:
- 0:e38b500d6e74
Grundfunktionen funktionieren
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
wengefa1 | 0:e38b500d6e74 | 1 | #include "mbed.h" |
wengefa1 | 0:e38b500d6e74 | 2 | #include "Controller.h" |
wengefa1 | 0:e38b500d6e74 | 3 | #include "MotorDriver.h" |
wengefa1 | 0:e38b500d6e74 | 4 | #include "ReadFinalLine.h" |
wengefa1 | 0:e38b500d6e74 | 5 | #include "ReadSensor.h" |
wengefa1 | 0:e38b500d6e74 | 6 | |
wengefa1 | 0:e38b500d6e74 | 7 | |
wengefa1 | 1:4808f55970e8 | 8 | |
wengefa1 | 0:e38b500d6e74 | 9 | int answer; |
wengefa1 | 0:e38b500d6e74 | 10 | |
wengefa1 | 0:e38b500d6e74 | 11 | int main() |
wengefa1 | 0:e38b500d6e74 | 12 | { |
wengefa1 | 0:e38b500d6e74 | 13 | startup(); |
wengefa1 | 1:4808f55970e8 | 14 | /*while(1) |
wengefa1 | 1:4808f55970e8 | 15 | { |
wengefa1 | 1:4808f55970e8 | 16 | |
wengefa1 | 1:4808f55970e8 | 17 | printf("%f\n", ReadSensorValue(1)); |
wengefa1 | 1:4808f55970e8 | 18 | }*/ |
wengefa1 | 1:4808f55970e8 | 19 | |
wengefa1 | 1:4808f55970e8 | 20 | while(1){ |
wengefa1 | 1:4808f55970e8 | 21 | driveOne(3,2); |
wengefa1 | 1:4808f55970e8 | 22 | wait(1); |
wengefa1 | 1:4808f55970e8 | 23 | turnRight(1); |
wengefa1 | 1:4808f55970e8 | 24 | turnRight(1); |
wengefa1 | 0:e38b500d6e74 | 25 | } |
wengefa1 | 0:e38b500d6e74 | 26 | } |
wengefa1 | 1:4808f55970e8 | 27 |