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.
Dependencies: mbed
Revision 1:6f2984a38b99, committed 2015-02-08
- Comitter:
- jaredwil
- Date:
- Sun Feb 08 15:35:34 2015 +0000
- Parent:
- 0:272af4948198
- Commit message:
- commented;
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r 272af4948198 -r 6f2984a38b99 main.cpp
--- a/main.cpp Thu Jan 29 20:51:17 2015 +0000
+++ b/main.cpp Sun Feb 08 15:35:34 2015 +0000
@@ -1,16 +1,20 @@
#include "mbed.h"
+//Initialize Digital Out and Interrupt
InterruptIn pound(p25);
DigitalOut myled(LED1);
+//Define Interrupt Functions
void pON () {
myled = 1;
}
void pOFF() {
myled = 0;
- }
+ {
+
int main() {
myled = 0;
+ //Initialize Interrupt for rising and falling edge
pound.rise(&pON);
pound.fall(&pOFF);
while(1) {