![](/media/cache/profiles/b5c4ec91390a6fbccf8d918d443563ed.jpg.50x50_q85.jpg)
acd52832 blinky example
Revision 5:9ca5e2a69411, committed 2018-11-07
- Comitter:
- jurica238814
- Date:
- Wed Nov 07 09:40:14 2018 +0000
- Branch:
- TestBranch
- Parent:
- 4:de5cf6b1e96b
- Commit message:
- nano module blinky
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Sun May 13 20:03:40 2018 +0000 +++ b/main.cpp Wed Nov 07 09:40:14 2018 +0000 @@ -1,16 +1,15 @@ -/* Copyright (c) 2018 Aconno. All Rights Reserved. - * - * Licensees are granted free, non-transferable use of the information. NO - * WARRANTY of ANY KIND is provided. This heading must NOT be removed from - * the file. - * - */ - #include "mbed.h" -DigitalOut led(p23); +#define RED_LED_PIN (p12) + +DigitalOut redLed(RED_LED_PIN); -int main(){ - led = !led; - wait_ms(250); -} \ No newline at end of file +int main() +{ + while(true) + { + redLed = !redLed; + wait_ms(500); + } + } + \ No newline at end of file