Henk Meewis / Mbed 2 deprecated USB_serial_LED_controller

Dependencies:   mbed

Fork of frdm_echo by Henk Meewis

shell.h

Committer:
silverpanda
Date:
2014-04-16
Revision:
11:4c6c6d6c0ebe
Parent:
9:f9efd3a69c2d
Child:
12:b846b64e3980

File content as of revision 11:4c6c6d6c0ebe:

#ifndef shell__h__
#define shell__h__

#define ItsInputBufferSize_ 24

class Shell {
public:
    Shell(uint32_t);
    void sendHelloWorld();
    void scanUSBSerialRx();
private:
    void sendText(char *);
    bool addCharacterToBuffer(char);
    void finishCharacterBuffer();
    void sendExample();
    char lowercase(char);

    Serial *usbSerial;
    char inputBuffer[ItsInputBufferSize_];
    uint32_t characterCount, characterPointer;
    bool findString(char *);
    void parseCommands();
    void parseLED();
};

#endif