![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Oppgave 5.1a
Diff: main.cpp
- Revision:
- 1:37a4f8f93b05
- Parent:
- 0:bf2a26f06012
--- a/main.cpp Tue Sep 26 11:08:14 2017 +0000 +++ b/main.cpp Tue Oct 03 10:31:51 2017 +0000 @@ -1,18 +1,21 @@ #include "mbed.h" DigitalOut myled(LED1); +void blink1(void); -int main() - { - int n = 20; - while(n>0) { +int main() +{ + int n = 20; + while(n>0) { blink1(); n--; - }return 0; + } + return 0; } -void blink1(void){ +void blink1(void) +{ myled =1; wait(0.2); myled =0; wait(0.3); - } \ No newline at end of file +} \ No newline at end of file