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.
Fork of frdm_echo by
Diff: shell.cpp
- Revision:
- 7:19da09fe546b
- Parent:
- 5:03b7c237c4c4
- Child:
- 8:b715912d684b
--- a/shell.cpp Mon Apr 14 01:53:10 2014 +0000 +++ b/shell.cpp Mon Apr 14 03:04:28 2014 +0000 @@ -1,6 +1,9 @@ #include "mbed.h" +#include "LEDColors.h" #include "shell.h" +extern LEDColors *ledColors; + // create contructor Shell::Shell(uint32_t thisBaudRate) { @@ -33,10 +36,16 @@ // see if this is a semi colon or a carriage return // if so, give a new line cursor - if((character == ';') || (character == 13)) usbSerial->printf("\n> "); + if((character == ';') || (character == 13)) { + usbSerial->printf("\n> "); + ledColors->flashWhite(10); + } // if not, just print the character - else usbSerial->printf("%c", character); + else { + usbSerial->printf("%c", character); + ledColors->flashGreen(10); + } } } //-----------------------------------------------------------------------------