Karl Nicolaus
/
4180_Lab1_P6
t
Diff: main.cpp
- Revision:
- 1:d1837531c318
- Parent:
- 0:2e5b82508aea
- Child:
- 2:1956c8e08cd3
diff -r 2e5b82508aea -r d1837531c318 main.cpp --- a/main.cpp Mon Feb 28 12:07:17 2011 +0000 +++ b/main.cpp Mon Feb 28 12:20:18 2011 +0000 @@ -1,15 +1,31 @@ +/* +Copyright (c) 2011 Anthony Buckton (abuckton [at] blackink [dot} net {dot} au) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. +*/ + #include <mbed.h> #include <string> #include <list> #include <mpr121.h> -DigitalOut led1(LED1); -DigitalOut led2(LED2); -DigitalOut led3(LED3); -DigitalOut led4(LED4); - - // Create the interrupt receiver object on pin 26 InterruptIn interrupt(p26); @@ -75,7 +91,7 @@ count++; } pc.printf("--------- \r\n\n"); - mpr121.setProximityMode(true); + // mpr121.setProximityMode(true); pc.printf("ELE_CFG=%x", mpr121.read(ELE_CFG)); @@ -86,7 +102,6 @@ wait(5); pc.printf("."); } - }