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
Fork of _B14_Lektion05b by
Revision 0:c2a3df878b8a, committed 2014-11-13
- Comitter:
- Enenkel
- Date:
- Thu Nov 13 18:20:59 2014 +0000
- Child:
- 1:b94490b97a6a
- Commit message:
- RGB LED und blaue LED
Changed in this revision
| 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 |
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp Thu Nov 13 18:20:59 2014 +0000
@@ -0,0 +1,43 @@
+/***********************************
+name: BERTL_2014_TEST
+author: Gottfried Enenkel HTL BULME
+email: ene@bulme.at
+description:
+ 3 Blaue LEDs ON
+ Die RGB LED leuchtet rot grün blau
+ je 1 sec
+***********************************/
+#include "mbed.h"
+// ************ DEKLARATIONEN **************
+DigitalOut LED_blue(P1_28); // Alle Blauen LED gehen auf einen Anschluß
+ // P1..Port1 _28 Anschluß 28
+DigitalOut RGB_bl(P1_24); // BLAU
+ // am uP -> P1..Port1
+ // -> 24..IO Anschluss 24
+DigitalOut RGB_rt(P1_23); // ROT
+DigitalOut RGB_gr(P1_25); // GRÜN P26 geht zum uP Port P1_25
+
+// ************ HAUPT PROGRAMM **************
+int main() {
+ RGB_bl=1; //blau AUS
+ RGB_rt=1; //rot
+ RGB_gr=1; //grün
+
+ while(1) {
+ LED_blue=1; //blaue LED AUS!
+ wait(1);
+ LED_blue=0; //blaue LED EIN
+ RGB_bl=0; //blau
+ wait(1);
+ RGB_bl=1;
+ RGB_gr=0; //grün
+ wait(1);
+ RGB_gr=1;
+ RGB_rt=0; //rot
+ wait(1);
+ RGB_rt=1;
+ wait(1);
+ }
+ }
+
+ // ***************** ENDE ********************
\ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Thu Nov 13 18:20:59 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/5e5da4a5990b \ No newline at end of file
