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.
Fork of mbed-os-example-mbed5-blinky by
main.cpp
- Committer:
- Jsquiroga
- Date:
- 2018-03-26
- Revision:
- 14:0357b4ab5699
- Parent:
- 8:bb09890333fe
File content as of revision 14:0357b4ab5699:
#include "mbed.h" //Define outputs DigitalOut blue(LED3); //Define interrupt inputs InterruptIn button(SW2); //interrupcion para el boton 2 void BlinkLed (){ blue=!blue; } int main() { __enable_irq(); //Enable Interrupts blue=0; //initialize output button.rise(&blinkLed); //The ISR activates with rising edge of button and activate the function. while(1) { // Write your code } }