![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
use analogout
Fork of eic_brinky by
main.cpp
- Committer:
- lelect
- Date:
- 2014-05-13
- Revision:
- 0:f0ec394dd639
- Child:
- 1:d54988818b96
File content as of revision 0:f0ec394dd639:
#include "mbed.h" DigitalOut led[]= {LED1,LED2,LED3,LED4,LED3,LED2}; Serial pc(USBTX,USBRX);//tx,rx int main() { while(1) { for(int i=0; i<6; i=1+i) { led[i]=0; led[(i+1)%6]=1; pc.printf("led[%d] is ON\r\n",(i+1)%6); wait(0.2); } } }