Use Uart

Dependencies:   mbed

Fork of Serial_HelloWorld_Mbed by eunkyoung kim

Committer:
IOP
Date:
Thu Apr 20 09:28:30 2017 +0000
Revision:
6:3689cb2a18f4
Parent:
5:4e99dfae8dca
code update

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mbed_official 0:879aa9d0247b 1 #include "mbed.h"
IOP 4:3974a6c7b088 2
IOP 6:3689cb2a18f4 3 Serial pc(PC_02,PC_03);
IOP 4:3974a6c7b088 4
IOP 6:3689cb2a18f4 5 int main(){
IOP 6:3689cb2a18f4 6
IOP 6:3689cb2a18f4 7 pc.baud(115200);
IOP 4:3974a6c7b088 8
IOP 6:3689cb2a18f4 9 pc.printf("Hello World!\n");
IOP 4:3974a6c7b088 10
IOP 6:3689cb2a18f4 11 while(1)
IOP 6:3689cb2a18f4 12 {
IOP 6:3689cb2a18f4 13 pc.putc(pc.getc()+1);
mbed_official 0:879aa9d0247b 14 }
IOP 4:3974a6c7b088 15 }