edfghjk

Dependencies:   mbed

main.cpp

Committer:
yizumi1012xxx
Date:
2013-12-12
Revision:
0:ba7db18ab507

File content as of revision 0:ba7db18ab507:

#include "mbed.h"

Serial device(p9, p10); // tx, rx
Serial pc(USBTX, USBRX); // tx, rx


int main() {
    pc.printf("a");
    device.printf("a");
    while(1) {
        if(pc.readable()) {
            device.putc(pc.getc());
            
            pc.putc(pc.getc());
        }
        if(device.readable()) {
            pc.putc(device.getc());
        }
    }
}