Allen Smith
/
firstTest
somme dumb test
Revision 1:ea80f6d915c1, committed 2013-09-04
- Comitter:
- asmithmd1
- Date:
- Wed Sep 04 14:05:52 2013 +0000
- Parent:
- 0:a180484467e1
- Commit message:
- Just a test
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r a180484467e1 -r ea80f6d915c1 main.cpp --- a/main.cpp Mon Jul 22 14:38:47 2013 +0000 +++ b/main.cpp Wed Sep 04 14:05:52 2013 +0000 @@ -5,8 +5,20 @@ DigitalOut myled2(LED3); DigitalOut myled3(LED4); +Serial pc(USBTX, USBRX); // tx, rx + int main() { + int i = 0; + char d; + char buffer[128]; + while(1) { + + pc.printf("Hello World! %d \n\r", i); + ++i; + pc.gets(buffer, 4); + pc.printf("I got '%s'\n", buffer); + myled0 = 1; wait(0.1); myled0 = 0;