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.
Revision 0:f9a53979b663, committed 2014-10-18
- Comitter:
- chenlaoshi
- Date:
- Sat Oct 18 03:02:41 2014 +0000
- Commit message:
- ???
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 |
diff -r 000000000000 -r f9a53979b663 main.cpp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp Sat Oct 18 03:02:41 2014 +0000
@@ -0,0 +1,33 @@
+#include "mbed.h"
+
+DigitalOut myled(PA_5);
+void delay(long int i);
+int main()
+ {
+ int ledx ,cycle=4000;
+ while(1)
+ {
+
+ for(ledx=0;ledx<cycle;ledx++)
+ {
+ myled = 1; // LED is ON
+ delay(ledx);
+ myled = 0; // LED is ON
+ delay(cycle-ledx);
+ }
+
+ for(ledx=cycle;ledx>0;ledx--)
+ {
+ myled = 1; // LED is ON
+ delay(ledx);
+ myled = 0; // LED is ON
+ delay(cycle-ledx);
+ }
+ }
+
+}
+void delay(long int i)
+{
+ while(i--);
+}
+
diff -r 000000000000 -r f9a53979b663 mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Sat Oct 18 03:02:41 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/552587b429a1 \ No newline at end of file