![](/media/cache/profiles/b67245cccae7128e11b41880910d4fd0.jpg.50x50_q85.png)
Nucleo_DigitalInput
main.cpp
- Committer:
- anoney180133
- Date:
- 2015-12-11
- Revision:
- 0:e66a2abcf59d
File content as of revision 0:e66a2abcf59d:
#include "mbed.h" DigitalOut Nucleo_GREEN_LED(LED1); DigitalIn Push_Button(PC_13,PullNone); int main() { while(1) { if(Push_Button.read() == 0) // pressed button { Nucleo_GREEN_LED = 1; // LED is ON } else { Nucleo_GREEN_LED = 0; // LED is OFF } } }