LED_Programm

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
mSeiser
Date:
Thu Apr 16 11:48:29 2015 +0000
Commit message:
LED_BLINKER;

Changed in this revision

If_Task.cpp Show annotated file Show diff for this revision Revisions of this file
If_Task.h Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
ur_Bertl.lib Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/If_Task.cpp	Thu Apr 16 11:48:29 2015 +0000
@@ -0,0 +1,21 @@
+#include "mbed.h"
+#include "ur_Bertl.h"
+#include "If_Task.h"
+
+
+void GamePlayer::CaptureTheBeeper()
+{
+  Move();
+  if(NextToABeeper())
+  {
+    PickBeeper();
+    TurnAround();
+  }
+  Move();
+}
+void GamePlayer :: TurnAround()
+{
+    TurnLeft();
+    TurnLeft();
+    
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/If_Task.h	Thu Apr 16 11:48:29 2015 +0000
@@ -0,0 +1,14 @@
+#include "mbed.h"
+#include "ur_Bertl.h"
+
+
+#ifndef GAMEPLAYER_H
+#define GAMEPLAYER_H
+
+class GamePlayer : public ur_Bertl
+{
+    public:
+    void CaptureTheBeeper();
+    void TurnAround();
+};
+#endif
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Thu Apr 16 11:48:29 2015 +0000
@@ -0,0 +1,22 @@
+#include "mbed.h"
+#include "ur_Bertl.h"
+#include "If_Task.h"
+#include "const.h"
+
+
+
+
+int main()
+{
+   GamePlayer robot;
+   
+   robot.WaitUntilButtonPressed();
+   robot.CaptureTheBeeper();
+   robot.BlueLedsON();
+   robot.MoveBackwards(); 
+   robot.BlueLedsOFF(); 
+   robot.NibbleLeds(0x0A);
+   robot.NibbleLeds(0x0F);
+   robot.NibbleLeds(0x01);
+   robot.ShutOff();
+};
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Thu Apr 16 11:48:29 2015 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/487b796308b0
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ur_Bertl.lib	Thu Apr 16 11:48:29 2015 +0000
@@ -0,0 +1,1 @@
+http://developer.mbed.org/teams/BERTL_CHEL_18/code/ur_Bertl/#e7f74f072564