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.
main.cpp
00001 #include "mbed.h" 00002 00003 AnalogIn ain(A0); 00004 DigitalOut led1(LED1); 00005 DigitalOut led2(LED2); 00006 DigitalOut led3(LED3); 00007 DigitalOut led4(LED4); 00008 00009 int main() { 00010 while (1){ 00011 led1 = (ain > 0.2f) ? 1 : 0; 00012 led2 = (ain > 0.4f) ? 1 : 0; 00013 led3 = (ain > 0.6f) ? 1 : 0; 00014 led4 = (ain > 0.8f) ? 1 : 0; 00015 } 00016 }
Generated on Thu Aug 4 2022 16:46:17 by
1.7.2