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 Serial pc(USBTX, USBRX); 00004 Serial screen(PB9,PB10); 00005 00006 DigitalOut pc_activity(LED1); 00007 DigitalOut screen_activity(LED2); 00008 00009 int main(void) { 00010 screen.baud(9600); 00011 pc.printf("Hello World!\n\r"); 00012 00013 while(1) 00014 { 00015 if(screen.readable()) { 00016 pc.putc(screen.getc()); 00017 screen_activity = !screen_activity; 00018 } 00019 00020 if(pc.readable()) { 00021 /* 00022 screen.putc(0x01); 00023 screen.putc(0x06); 00024 screen.putc(0x01); 00025 screen.putc(0x00); 00026 screen.putc(0x01); 00027 screen.putc(0x1A); 00028 */ 00029 screen.putc(pc.getc()); 00030 pc_activity = !pc_activity; 00031 } 00032 00033 } 00034 }
Generated on Sat Jul 16 2022 19:34:18 by
1.7.2