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.
Diff: include/SerialPrompt.h
- Revision:
- 3:def8a92db030
- Child:
- 4:cc391b3f3e57
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/include/SerialPrompt.h Wed Jun 24 09:26:07 2015 +0000
@@ -0,0 +1,16 @@
+#ifndef SERIALPROMPT_H
+#define SERIALPROMPT_H
+#include "mbed.h"
+const char* prompt = "$>";
+void displayPrompt(Serial* pcConnection)
+{
+ pcConnection->printf(prompt);
+}
+int getInput(Serial* pcConnection)
+{
+ if(pcConnection->readable())
+ {
+ pcConnection->printf(pcConnection->getc());
+ }
+}
+#endif // SERIALPROMPT_H
\ No newline at end of file