Tobis Programm forked to not destroy your golden files

Dependencies:   mbed

Fork of Robocode by PES 2 - Gruppe 1

Revision:
80:92b9d083322d
Parent:
75:dba260cb5ae4
Child:
81:956f65714207
--- a/source/Robot.cpp	Tue Apr 25 11:42:45 2017 +0000
+++ b/source/Robot.cpp	Wed Apr 26 07:30:03 2017 +0000
@@ -54,7 +54,7 @@
 //Periphery for distance sensors
 AnalogIn distance(PB_1);
 AnalogIn distance2(PA_1);
-DigitalOut enable(PC_1);
+DigitalOut IRenable(PC_1);
 DigitalOut bit0(PH_1);
 DigitalOut bit1(PC_2);
 DigitalOut bit2(PC_3);
@@ -185,6 +185,8 @@
 {
     for( int ii = 0; ii<6; ++ii)
         sensors[ii].init(&distance,&distance2, &bit0, &bit1, &bit2, ii);
+    
+    IRenable = 1;
 }
 
 float getDistanceIR(int number)
@@ -246,7 +248,6 @@
 void init_servo(int freq)
 {
     char data[2];
-
     //Reset
     data[0] = (char) MODE1;
     data[1] = (char) SLEEP;