![](/media/cache/group/bulme_y5UPVgJ.gif.50x50_q85.jpg)
Lauflicht led 1-4
Dependencies: mbed
Lauflicht.cpp@0:11c4ec07937f, 2015-03-05 (annotated)
- Committer:
- SebiStr99
- Date:
- Thu Mar 05 13:03:00 2015 +0000
- Revision:
- 0:11c4ec07937f
- Child:
- 1:201c99e74ae0
DigitalOut_LED1-4 Lauflicht
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
SebiStr99 | 0:11c4ec07937f | 1 | #include "mbed.h" |
SebiStr99 | 0:11c4ec07937f | 2 | |
SebiStr99 | 0:11c4ec07937f | 3 | DigitalOut led1(LED1); |
SebiStr99 | 0:11c4ec07937f | 4 | DigitalOut led2(LED2); |
SebiStr99 | 0:11c4ec07937f | 5 | DigitalOut led3(LED3); |
SebiStr99 | 0:11c4ec07937f | 6 | DigitalOut led4(LED4); |
SebiStr99 | 0:11c4ec07937f | 7 | |
SebiStr99 | 0:11c4ec07937f | 8 | int main () |
SebiStr99 | 0:11c4ec07937f | 9 | { |
SebiStr99 | 0:11c4ec07937f | 10 | while (1) |
SebiStr99 | 0:11c4ec07937f | 11 | { |
SebiStr99 | 0:11c4ec07937f | 12 | |
SebiStr99 | 0:11c4ec07937f | 13 | led3 = 0; |
SebiStr99 | 0:11c4ec07937f | 14 | wait (0.25); |
SebiStr99 | 0:11c4ec07937f | 15 | led4 = 0; |
SebiStr99 | 0:11c4ec07937f | 16 | wait (0.25); |
SebiStr99 | 0:11c4ec07937f | 17 | led1 = 1; |
SebiStr99 | 0:11c4ec07937f | 18 | wait (0.25); |
SebiStr99 | 0:11c4ec07937f | 19 | led2 = 1; |
SebiStr99 | 0:11c4ec07937f | 20 | wait (0.25); |
SebiStr99 | 0:11c4ec07937f | 21 | led1 = 0; |
SebiStr99 | 0:11c4ec07937f | 22 | led3 = 1; |
SebiStr99 | 0:11c4ec07937f | 23 | wait (0.25); |
SebiStr99 | 0:11c4ec07937f | 24 | led2 = 0; |
SebiStr99 | 0:11c4ec07937f | 25 | led4 = 1; |
SebiStr99 | 0:11c4ec07937f | 26 | wait (0.25); |
SebiStr99 | 0:11c4ec07937f | 27 | |
SebiStr99 | 0:11c4ec07937f | 28 | } |
SebiStr99 | 0:11c4ec07937f | 29 | |
SebiStr99 | 0:11c4ec07937f | 30 | |
SebiStr99 | 0:11c4ec07937f | 31 | |
SebiStr99 | 0:11c4ec07937f | 32 | |
SebiStr99 | 0:11c4ec07937f | 33 | } |