4180 lab 1

Dependencies:   mbed MCP23S17 PinDetect USBDevice

Files at this revision

API Documentation at this revision

Comitter:
emilywilson
Date:
Wed Jan 15 18:37:58 2020 +0000
Parent:
1:f121b88d9c85
Child:
3:d84f4a501915
Commit message:
pb interrupts;

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Wed Jan 15 18:21:55 2020 +0000
+++ b/main.cpp	Wed Jan 15 18:37:58 2020 +0000
@@ -14,10 +14,10 @@
 //PinName greenPin = p12;
 //PinName bluePin = p13;
 //
-PinDetect pb1(p8);
-PinDetect pb2(p9);
+PinDetect pb1(p21);
+PinDetect pb2(p22);
 
-float volatile p;
+float volatile p = 1.0f;
 
 void pb1_hit_callback() {
     if (p > 0) {