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:9326024c4b59, committed 2015-02-10
- Comitter:
- mbedschool
- Date:
- Tue Feb 10 02:26:59 2015 +0000
- Commit message:
- DCMotor
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 Tue Feb 10 02:26:59 2015 +0000
@@ -0,0 +1,29 @@
+#include "mbed.h"
+
+DigitalOut ledForPower1(LED1);
+DigitalOut ledForPower2(LED2);
+DigitalOut ledForPower3(LED3);
+DigitalOut ledForPower4(LED4);
+PwmOut motor(p21);
+
+int main() {
+
+ motor=0;
+ wait(2);
+
+ motor=0.4;
+ ledForPower1=1;
+ wait(2);
+
+ motor=0.6;
+ ledForPower2=1;
+ wait(2);
+
+ motor=0.8;
+ ledForPower3=1;
+ wait(2);
+
+ motor=1;
+ ledForPower4=1;
+
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Tue Feb 10 02:26:59 2015 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/e188a91d3eaa \ No newline at end of file