Dan Anderson
/
frdm_Distance1
Fork of frdm_Distance by
main.cpp
- Committer:
- danderson8814
- Date:
- 2015-06-27
- Revision:
- 0:cfc5bd6037db
- Child:
- 1:0b176971be25
File content as of revision 0:cfc5bd6037db:
#include "mbed.h" DigitalOut led_red(LED_RED); DigitalIn Ec(PTD5); DigitalOut Trig(PTD7); DigitalOut Pwr(PTD6); DigitalIn sw2(SW2); void sw2_release(void) { led_red = !led_red; printf("On-board button SW2 was released.\n"); } int main() { sw2.rise(&sw2_release); while (true) { } }