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
shell.h@8:b715912d684b, 2014-04-14 (annotated)
- Committer:
- silverpanda
- Date:
- Mon Apr 14 16:41:57 2014 +0000
- Revision:
- 8:b715912d684b
- Parent:
- 5:03b7c237c4c4
- Child:
- 9:f9efd3a69c2d
added inputBuffer
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
silverpanda | 5:03b7c237c4c4 | 1 | #ifndef shell__h__ |
silverpanda | 5:03b7c237c4c4 | 2 | #define shell__h__ |
silverpanda | 5:03b7c237c4c4 | 3 | |
silverpanda | 8:b715912d684b | 4 | #define ItsInputBufferSize_ 20 |
silverpanda | 8:b715912d684b | 5 | |
silverpanda | 5:03b7c237c4c4 | 6 | class Shell { |
silverpanda | 5:03b7c237c4c4 | 7 | public: |
silverpanda | 5:03b7c237c4c4 | 8 | Shell(uint32_t); |
silverpanda | 5:03b7c237c4c4 | 9 | void sendHelloWorld(); |
silverpanda | 5:03b7c237c4c4 | 10 | void scanUSBSerialRx(); |
silverpanda | 5:03b7c237c4c4 | 11 | |
silverpanda | 5:03b7c237c4c4 | 12 | private: |
silverpanda | 5:03b7c237c4c4 | 13 | void sendText(char *); |
silverpanda | 8:b715912d684b | 14 | void addCharacterToBuffer(char); |
silverpanda | 8:b715912d684b | 15 | void finishCharacterBuffer(); |
silverpanda | 5:03b7c237c4c4 | 16 | |
silverpanda | 5:03b7c237c4c4 | 17 | Serial *usbSerial; |
silverpanda | 8:b715912d684b | 18 | char inputBuffer[ItsInputBufferSize_]; |
silverpanda | 8:b715912d684b | 19 | uint32_t characterCount, characterPointer; |
silverpanda | 5:03b7c237c4c4 | 20 | }; |
silverpanda | 5:03b7c237c4c4 | 21 | |
silverpanda | 5:03b7c237c4c4 | 22 | #endif |