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.
Dependencies: mbed
main.cpp
00001 #include "mbed.h" 00002 00003 BusOut myled(LED1,LED2,LED3,LED4); 00004 DigitalIn sw(p5); 00005 Serial pc(USBTX,USBRX); 00006 int main() { 00007 char a; 00008 while(1) { 00009 00010 00011 a=pc.getc(); 00012 if(a=='y'){ 00013 00014 myled = 0b1010; 00015 } 00016 00017 if(a=='n'){ 00018 myled = 0b0101; 00019 //wait(0.2); 00020 } 00021 } 00022 }
Generated on Mon Aug 8 2022 23:57:26 by
1.7.2