Shellminator V3.0.1
Simple Terminal
Loading...
Searching...
No Matches
Shellminator Class Reference

Shellminator object. More...

#include <Shellminator.hpp>

Inheritance diagram for Shellminator:
Collaboration diagram for Shellminator:

Classes

struct  shellEvent_t
 Shell event structure. More...
 

Public Types

enum  textColor_t {
  BLACK = 30 , RED = 31 , GREEN = 32 , YELLOW = 33 ,
  BLUE = 34 , MAGENTA = 35 , CYAN = 36 , WHITE = 37
}
 VT100 color codes. More...
 
enum  backgroundColor_t {
  BG_BLACK = 40 , BG_RED = 41 , BG_GREEN = 42 , BG_YELLOW = 43 ,
  BG_BLUE = 44 , BG_MAGENTA = 45 , BG_CYAN = 46 , BG_WHITE = 47
}
 VT100 color codes. More...
 
enum  textStyle_t {
  REGULAR = 0 , BOLD = 1 , LOW_INTENSITY = 2 , ITALIC = 3 ,
  UNDERLINE = 4 , BLINKING = 5 , REVERSE = 6 , BACKGROUND = 7 ,
  INVISIBLE = 8
}
 VT100 font sytles. More...
 
enum  shellEventType_t {
  SHELL_EVENT_EMPTY , SHELL_EVENT_RESIZE , SHELL_EVENT_MOUSE , SHELL_EVENT_KEY ,
  SHELL_EVENT_CODED_KEY , SHELL_EVENT_SCREEN_SWAP
}
 Shell Event enumeration. More...
 
enum  eventCodes_t {
  EVENT_CODE_EMPTY , EVENT_CODE_RETURN , EVENT_CODE_MOUSE_LEFT_PRESSED , EVENT_CODE_MOUSE_LEFT_RELEASED ,
  EVENT_CODE_MOUSE_RIGHT_PRESSED , EVENT_CODE_MOUSE_RIGHT_RELEASED , EVENT_CODE_MOUSE_MIDDLE_PRESSED , EVENT_CODE_MOUSE_MIDDLE_RELEASED ,
  EVENT_CODE_MOUSE_WHEEL_UP , EVENT_CODE_MOUSE_WHEEL_DOWN , EVENT_CODE_UP_ARROW , EVENT_CODE_DOWN_ARROW ,
  EVENT_CODE_LEFT_ARROW , EVENT_CODE_RIGHT_ARROW , EVENT_CODE_HOME , EVENT_CODE_END
}
 Coded event enumeration. More...
 

Public Member Functions

 Shellminator (Stream *stream_p)
 Shell object constructor. More...
 
bool enableBuffering (uint8_t *buffer, int bufferSize)
 Enable buffering to gain speed. More...
 
void attachExecFunc (void(*execution_fn_p)(char *, Shellminator *))
 Register a function callback for command execution. More...
 
void attachNeofetchFunc (void(*neofetch_fn_p)(Shellminator *))
 Register a function callback for neofetch command. More...
 
void begin (const char *banner_p)
 Shellminator initialization function. More...
 
void sendBackspace ()
 Sends a backspace. More...
 
void clear ()
 Clear screen. More...
 
void update ()
 Update function. More...
 
void logOut ()
 
void format (Stream *stream_p, int firstArg)
 Basic text formatting. More...
 
void format (Stream *stream_p, int firstArg, int secondArg)
 
void format (Stream *stream_p, int firstArg, int secondArg, int thirdArg)
 
void hideCursor ()
 Hide the cursor. More...
 
void showCursor ()
 Show the cursor. More...
 
bool getCursorPosition (int *x, int *y, uint32_t timeout=250)
 Get the position of the cursor. More...
 
void setCursorPosition (int x, int y)
 Set the position of the cursor. More...
 
bool getTerminalSize (int *width, int *height)
 
void drawLogo ()
 Draws the startup logo. More...
 
void printBanner ()
 This function prints the banner text. More...
 
void printHistory ()
 Print command history. More...
 
void printHelp ()
 Print help text. More...
 
void setBannerText (const char *banner_p)
 This function sets the banner text. More...
 
void setBannerPathText (const char *bannerPath_p)
 This function sets the banner path text. More...
 
void attachLogo (const char *logo_p)
 This function attaches a logo to the terminal. More...
 
void attachLogo (__FlashStringHelper *progmemLogo_p)
 This function attaches a logo to the terminal. More...
 
void overrideUpArrow (void(*func)(Shellminator *))
 Override up arrow key behaviour. More...
 
void overrideDownArrow (void(*func)(Shellminator *))
 Override down arrow key behaviour. More...
 
void overrideLeftArrow (void(*func)(Shellminator *))
 Override left arrow key behaviour. More...
 
void overrideRightArrow (void(*func)(Shellminator *))
 Override right arrow key behaviour. More...
 
void overrideAbortKey (void(*func)(Shellminator *))
 Override abort key behaviour. More...
 
void overridePageUpKey (void(*func)(Shellminator *))
 Override Page-Up key behaviour. More...
 
void overridePageDownKey (void(*func)(Shellminator *))
 Override Page-Down key behaviour. More...
 
void overrideHomeKey (void(*func)(Shellminator *))
 Override Home key behaviour. More...
 
void overrideEndKey (void(*func)(Shellminator *))
 Override End key behaviour. More...
 
void overrideLogoutKey (void(*func)(Shellminator *))
 Override Logout key behaviour. More...
 
void overrideSearchKey (void(*func)(Shellminator *))
 Override Search key behaviour. More...
 
void freeUpArrow ()
 Reset up arrow key functionality to default. More...
 
void freeDownArrow ()
 Reset down arrow key functionality to default. More...
 
void freeLeftArrow ()
 Reset left arrow key functionality to default. More...
 
void freeRightArrow ()
 Reset right arrow key functionality to default. More...
 
void freeAbortKey ()
 Reset abort key functionality to default. More...
 
void freePageUpKey ()
 Reset Page-Up key functionality to default. More...
 
void freePageDownKey ()
 Reset Page-Down key functionality to default. More...
 
void freeHomeKey ()
 Reset Home key functionality to default. More...
 
void freeEndKey ()
 Reset End key functionality to default. More...
 
void freeLogoutKey ()
 Reset Logout key functionality to default. More...
 
void freeSearchKey ()
 Reset Search key functionality to default. More...
 
void setPassword (uint8_t *hashData, int hashSize)
 Enable login password. More...
 
void setPasswordHashFunction (void(*hashFunc_p)(uint8_t *, int, uint8_t *, int))
 Replace the built-in CRC32 hash generator. More...
 
void beginScreen (ShellminatorScreen *screen_p, int updatePeriod=250)
 Register Screen object to draw. More...
 
void endScreen ()
 Abort Screen session. More...
 
void swapScreen (ShellminatorScreen *screen_p, int updatePeriod=250)
 
void swapScreenAndClear (ShellminatorScreen *screen_p, int updatePeriod=250)
 
void requestRedraw ()
 Redraw request from a Screen object. More...
 
int eventAvailable ()
 Get the number of events available for reading from the eventBuffer. More...
 
shellEvent_t readEvent ()
 Read an event. More...
 
void popEvent ()
 Remove the current element from the buffer. More...
 
void mouseBegin ()
 Enable mouse reports. More...
 
void mouseEnd ()
 Disable mouse reports. More...
 
void input (char *buffer, int bufferSize, const char *instruction, void(*callback)(char *, int, Shellminator *), bool secret=false)
 Input prompt. More...
 
void beep ()
 Select list. More...
 
void printLoginScreen ()
 
ShellminatorBufferedPrintergetBufferedPrinter ()
 Get the buffered printer object address. More...
 
void attachColorizer (DefaultColorizer *colorizer_p)
 
void autoDetectTerminal ()
 

Static Public Member Functions

static void setFormat (Stream *stream_p, int firstArg)
 Basic text formatting. More...
 
static void setFormat (Stream *stream_p, int firstArg, int secondArg)
 
static void setFormat (Stream *stream_p, int firstArg, int secondArg, int thirdArg)
 
static void hideCursor (Stream *stream_p)
 Hide the cursor. More...
 
static void showCursor (Stream *stream_p)
 Show the cursor. More...
 
static void setCursorPosition (Stream *channel_p, int x, int y)
 Set the position of the cursor. More...
 
static ShellminatorcastVoidToShellminator (void *ptr)
 This is a helper function for pointer casting. More...
 
static bool waitForKey (Stream *source, char key, uint32_t timeout=0)
 Wait for specific keypress. More...
 
static bool waitForKey (Stream *source, char *keys, uint32_t timeout=0)
 Wait for specific keypress. More...
 

Public Attributes

shellEvent_t eventBuffer [EVENT_BUFFER_SIZE]
 The events are stored in this buffer. More...
 
uint8_t eventBufferWritePtr
 Write position for the eventBuffers circular structure. More...
 
uint8_t eventBufferReadPtr
 Read position for the eventBuffers circular structure. More...
 
int terminalWidth = 30
 Stores the width of the terminal in characters. More...
 
int terminalHeight = 12
 Stores the height of the terminal in characters. More...
 
char mouseEventBuffer [SHELLMINATOR_MOUSE_PARSER_BUFFER_SIZE]
 This buffer is used to parse the mouse coordinates form the host terminals answer. More...
 
uint8_t mouseEventBufferCounter = 0
 This variable traks the next free characters location in the mouseEventBuffer. More...
 
bool enableFormatting = true
 This flag enables or disables character formatting. More...
 
bool mute = false
 If set, the buzzer will be silent. More...
 
Stream * channel = NULL
 Pointer to the communication class. More...
 

Static Public Attributes

static const char * version = SHELLMINATOR_VERSION
 String, that holds the version information. More...
 

Protected Member Functions

virtual void printCommandParserHelp (Stream *channel_p, bool formatting_p)
 Print command parser Help. More...
 
virtual void checkCommandFraction ()
 Check the command with the command parser to get some useful information. More...
 
virtual bool hasCommandParser ()
 
virtual void executeWithCommandParser ()
 
virtual void autoCompleteWithCommandParser ()
 
void redrawLine ()
 

Protected Attributes

char cmd_buff [SHELLMINATOR_BUFF_DIM][SHELLMINATOR_BUFF_LEN+1] = {{0}}
 Text buffer. More...
 
uint32_t cmd_buff_dim = 1
 This variable tracks the index of the previous command while you browsing the command history. More...
 
uint32_t cmd_buff_cntr = 0
 This variable tracks the end of the input message. More...
 
uint32_t cursor = 0
 This variable tracks the location of the next character. More...
 
bool commandFound = false
 This flag must be set true in checkCommandFraction function when the command parser contains the command. More...
 

Private Member Functions

bool checkPassword (const char *password)
 Check the password. More...
 
void ShellminatorDefaultState (char new_char)
 
void ShellminatorEnterKeyState ()
 
void ShellminatorBackspaceState ()
 
void ShellminatorBeginningOfLineState ()
 
void ShellminatorEndOfLineState ()
 
void ShellminatorLogoutState ()
 
void ShellminatorReverseSearchState ()
 
void ShellminatorClearScreenState ()
 
void ShellminatorAutoCompleteState ()
 
void ShellminatorAbortState ()
 
void ShellminatorEscapeCharacterState (char new_char)
 
void ShellminatorEscapeBracketState (char new_char)
 
void ShellminatorUpArrowKeyState ()
 
void ShellminatorDownArrowKeyState ()
 
void ShellminatorLeftArrowKeyState ()
 
void ShellminatorRightArrowKeyState ()
 
void ShellminatorHomeKeyState ()
 
void ShellminatorHomeKeyState (char new_char)
 
void ShellminatorEndKeyState ()
 
void ShellminatorEndKeyState (char new_char)
 
void ShellminatorDelKeyState ()
 
void ShellminatorDelKeyState (char new_char)
 
void ShellminatorPageUpKeyState ()
 
void ShellminatorPageUpKeyState (char new_char)
 
void ShellminatorPageDownKeyState ()
 
void ShellminatorPageDownKeyState (char new_char)
 
void ShellminatorProcessRegularCharacter (char new_char, bool draw=true)
 
void ShellminatorMouseEventParserState (char new_char)
 
void ShellminatorTwoByteUnicodeDataState (char new_char)
 
void ShellminatorThreeByteUnicodeFirstDataState (char new_char)
 
void ShellminatorThreeByteUnicodeSecondDataState (char new_char)
 
void ShellminatorFourByteUnicodeFirstDataState (char new_char)
 
void ShellminatorFourByteUnicodeSecondDataState (char new_char)
 
void ShellminatorFourByteUnicodeThirdDataState (char new_char)
 
void pushEvent (shellEvent_t event)
 Push a new event to the event buffer. More...
 
void parseMouseData ()
 Parse mouse data. More...
 
void process (char new_char)
 This function processes a new character. More...
 
void historySearchBackward ()
 This function is used to search the previous matching command in the history. More...
 
void historySearchForward ()
 This function is used to search the next matching command in the history. More...
 
void redrawHistorySearch ()
 If reverse search mode is active, this function is used to print the text correctly. More...
 
int substring (char *str1, char *str2)
 Basic substring function. More...
 

Private Attributes

ShellminatorBufferedPrinter bufferedPrinter
 It can be used to accelerate the data sending process. More...
 
bool bufferMemoryAllocated = false
 If memory is allocated, this will be true;. More...
 
ShellminatorScreenscreen = NULL
 Pointer to a ShellminatorScreen object. More...
 
unsigned long screenTimerStart = 0
 The screen is drawn within a pre-defined periods. More...
 
unsigned long sizeTimerStart = 0
 
int screenUpdatePeriod
 The time interval between two drawings. More...
 
bool screenRedraw
 This flag shows if a request come from the Screen object to issue a draw function call. More...
 
DefaultColorizer defaultColorizer
 
DefaultColorizercolorizer = &this->defaultColorizer
 
uint8_t * passwordHash = NULL
 Stores the address of the password hash array. More...
 
int passwordHashSize = 0
 Stores the password hash array size. More...
 
bool loggedIn = false
 If logging in is required this flag will be true. More...
 
void(* passwordHashFunc )(uint8_t *, int, uint8_t *, int) = NULL
 Pointer to the hash function. More...
 
void(Shellminator::* currentState )(char) = &Shellminator::ShellminatorDefaultState
 Function pointer to the current state of the main state-machine. More...
 
char * logo = NULL
 Pointer to a string that holds the startup logo. More...
 
__FlashStringHelper * progmemLogo = NULL
 On AVR there is an oprion to store the logo in the program memory. More...
 
void(* execution_fn )(char *, Shellminator *)
 This function-pointer stores the execution function pointer. More...
 
void(* neofetch_fn )(Shellminator *)
 This function-pointer stores the neofetch function pointer. More...
 
uint32_t escape_state = 0
 This variable tracks the state of the VT100 decoder state-machine. More...
 
char banner [SHELLMINATOR_BANNER_LEN] = {'\0'}
 This character array stores the banner text. More...
 
char bannerPath [SHELLMINATOR_BANNER_PATH_LEN] = "$"
 This character array stores the banner path text. More...
 
uint8_t lastBannerSize = 0
 Size of the last printed banner in characters. More...
 
void(* upArrowOverrideFunc )(Shellminator *) = NULL
 Function pointer for up arrow behaviour override. More...
 
void(* downArrowOverrideFunc )(Shellminator *) = NULL
 Function pointer for down arrow behaviour override. More...
 
void(* leftArrowOverrideFunc )(Shellminator *) = NULL
 Function pointer for left arrow behaviour override. More...
 
void(* rightArrowOverrideFunc )(Shellminator *) = NULL
 Function pointer for right arrow behaviour override. More...
 
void(* abortKeyFunc )(Shellminator *) = NULL
 Function pointer for abort key behaviour override. More...
 
void(* pageUpKeyFunc )(Shellminator *) = NULL
 Function pointer for Page-Up key behaviour override. More...
 
void(* pageDownKeyFunc )(Shellminator *) = NULL
 Function pointer for Page-Down key behaviour override. More...
 
void(* homeKeyFunc )(Shellminator *) = NULL
 Function pointer for Home key behaviour override. More...
 
void(* endKeyFunc )(Shellminator *) = NULL
 Function pointer for End key behaviour override. More...
 
void(* logoutKeyFunc )(Shellminator *) = NULL
 Function pointer for Logout key behaviour override. More...
 
void(* searchKeyFunc )(Shellminator *) = NULL
 Function pointer for Search key behaviour override. More...
 
bool inSearch = false
 If reverse search mode is active, this flag will be true. More...
 
int searchMatch
 Used to parse reverse search. More...
 
bool inputActive = false
 This flag will be true when an input prompt is active. More...
 
int inputInstuctionSize = 0
 This will store the length of the instruction text size in an input. More...
 
char * inputDestinationBuffer
 Pointer to a buffer that will be used to store the text, that is typed to an input. More...
 
int inputDestinationBufferSize
 Size of the buffer that is attached to an input. More...
 
bool inputSecretMode
 If secret mode is activated on an input, this flag will be true. More...
 
void(* inputCallback )(char *, int, Shellminator *)
 This function will be called when an input is finished. More...
 
uint32_t lastKeyPressTime = 0
 Last time in ms when a key was pressed. More...
 

Friends

class ShellminatorProgress
 
class ShellminatorUT
 

Detailed Description

Shellminator object.

It can be used to interface with a VT100 compatible terminal like PuTTY, Terra Term or minicom. The module requires an Arduino-like Serial object.

Definition at line 105 of file Shellminator.hpp.

Member Enumeration Documentation

◆ backgroundColor_t

VT100 color codes.

This enum holds all of the VT100 compatible background color codes.

Enumerator
BG_BLACK 

Black text color.

BG_RED 

Red text color.

BG_GREEN 

Green text color.

BG_YELLOW 

Yellow text color.

BG_BLUE 

Blue text color.

BG_MAGENTA 

Magenta text color.

BG_CYAN 

Cyane text color.

BG_WHITE 

White text color.

Definition at line 127 of file Shellminator.hpp.

◆ eventCodes_t

Coded event enumeration.

Enumerator
EVENT_CODE_EMPTY 

This is used to handle default or empty values. If this value is assigned to an event, it won't do anything.

EVENT_CODE_RETURN 

Return or Enter key is pressed.

EVENT_CODE_MOUSE_LEFT_PRESSED 

Left Mouse Button Pressed.

EVENT_CODE_MOUSE_LEFT_RELEASED 

Left Mouse Button Released.

EVENT_CODE_MOUSE_RIGHT_PRESSED 

Right Mouse Button Pressed.

EVENT_CODE_MOUSE_RIGHT_RELEASED 

Right Mouse Button Released.

EVENT_CODE_MOUSE_MIDDLE_PRESSED 

Middle Mouse Button Pressed.

EVENT_CODE_MOUSE_MIDDLE_RELEASED 

Middle Mouse Button Released.

EVENT_CODE_MOUSE_WHEEL_UP 

Mouse Wheel Scrolled Up.

EVENT_CODE_MOUSE_WHEEL_DOWN 

Mouse Wheel Scrolled Down.

EVENT_CODE_UP_ARROW 

Up Arrow Pressed.

EVENT_CODE_DOWN_ARROW 

Down Arrow Pressed.

EVENT_CODE_LEFT_ARROW 

Left Arrow Pressed.

EVENT_CODE_RIGHT_ARROW 

Right Arrow Pressed.

EVENT_CODE_HOME 

Home Button Pressed.

EVENT_CODE_END 

End Button Pressed.

Definition at line 697 of file Shellminator.hpp.

◆ shellEventType_t

Shell Event enumeration.

Enumerator
SHELL_EVENT_EMPTY 

This is used to handle default or empty values. If this value is assigned to an event, it won't do anything.

SHELL_EVENT_RESIZE 

If the object detects a resize event, it will be available to the Screen object with this flag.

SHELL_EVENT_MOUSE 

To identify mouse related events.

SHELL_EVENT_KEY 

To identify simple key events like: A, b...

Note
Case sensitive!
SHELL_EVENT_CODED_KEY 

To identify special, coded keys like: Up Arrow, HOME...

SHELL_EVENT_SCREEN_SWAP 

Definition at line 687 of file Shellminator.hpp.

◆ textColor_t

VT100 color codes.

This enum holds all of the VT100 compatible color codes.

Enumerator
BLACK 

Black text color.

RED 

Red text color.

GREEN 

Green text color.

YELLOW 

Yellow text color.

BLUE 

Blue text color.

MAGENTA 

Magenta text color.

CYAN 

Cyane text color.

WHITE 

White text color.

Definition at line 112 of file Shellminator.hpp.

◆ textStyle_t

VT100 font sytles.

This enum holds all of the VT100 compatible font styles.

Enumerator
REGULAR 

Regular text style.

BOLD 

Bold text style.

LOW_INTENSITY 

Low intensity text style.

ITALIC 

Italic text style.

UNDERLINE 

Underline text style.

BLINKING 

Blinking text style.

REVERSE 

Reverse text style.

BACKGROUND 

Background text style.

INVISIBLE 

Invisible text style.

Definition at line 142 of file Shellminator.hpp.

Constructor & Destructor Documentation

◆ Shellminator()

Shellminator::Shellminator ( Stream *  stream_p)

Shell object constructor.

This is a simple constructor for a Shellminator object.

Parameters
stream_pPointer to a Stream object which will be used for communication.

Definition at line 38 of file Shellminator.cpp.

Member Function Documentation

◆ attachColorizer()

void Shellminator::attachColorizer ( DefaultColorizer colorizer_p)

Definition at line 1968 of file Shellminator.cpp.

◆ attachExecFunc()

void Shellminator::attachExecFunc ( void(*)(char *, Shellminator *)  execution_fn_p)

Register a function callback for command execution.

With this function you can attach an external function to the object This function will be called when a command is typed and the return key is pressed.

Parameters
execution_fn_pFunction pointer to the execution function.

The execution function prototype must be like this:

void myExecFunc( char* command, Shellminator* caller );
Shellminator object.

You can use any name you like, but the arguments and the return type has to be the same. Practical example for impementation:

void myExecFunc( char* command, Shellminator* caller ){
caller -> channel -> print( "Hurray! I got this: " );
caller -> channel -> println( command );
}
Stream * channel
Pointer to the communication class.

Definition at line 141 of file Shellminator.cpp.

◆ attachLogo() [1/2]

void Shellminator::attachLogo ( __FlashStringHelper *  progmemLogo_p)

This function attaches a logo to the terminal.

The logo is just a character array. To create custom startup logo: https://patorjk.com/software/taag/#p=display&f=Slant&t=Arduino To make it to a c-string: https://tomeko.net/online_tools/cpp_text_escape.php?lang=en Add '\r' to all line end.

Parameters
logo_pPointer to the logo's address.

Definition at line 126 of file Shellminator.cpp.

◆ attachLogo() [2/2]

void Shellminator::attachLogo ( const char *  logo_p)

This function attaches a logo to the terminal.

The logo is just a character array. To create costum startup logo: https://patorjk.com/software/taag/#p=display&f=Slant&t=Arduino To make it to a c-string: https://tomeko.net/online_tools/cpp_text_escape.php?lang=en Add '\r' to all line end.

Parameters
logo_pPointer to the logo's address.

Definition at line 134 of file Shellminator.cpp.

◆ attachNeofetchFunc()

void Shellminator::attachNeofetchFunc ( void(*)(Shellminator *)  neofetch_fn_p)

Register a function callback for neofetch command.

With this function you can attach an external function to the object This function will be called when a command is typed and the return key is pressed. You can find mor information about neofetch here.

Parameters
neofetch_fn_pFunction pointer to the neofetch callback function.

The neofetch callback function prototype must be like this:

void myNeofetch( Shellminator* caller );

You can use any name you like, but the arguments and the return type has to be the same. Practical example for impementation:

void myExecFunc( char* command, Shellminator* caller ){
caller -> channel -> println( "The simplest neofetch in the world!" );
}

Definition at line 148 of file Shellminator.cpp.

◆ autoCompleteWithCommandParser()

void Shellminator::autoCompleteWithCommandParser ( )
protectedvirtual

Reimplemented in ShellminatorCommanderInterface.

Definition at line 315 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ autoDetectTerminal()

void Shellminator::autoDetectTerminal ( )

Definition at line 1770 of file Shellminator.cpp.

◆ beep()

void Shellminator::beep ( )

Select list.

It is a simple input prompt to select elements from a list. There are two working modes:

  • Single element selection - In this mode you can navigate with the UP / DOWN arrow keys. If you selected the right option, just press enter to finish.
  • Multiple element selection - In this mode you can navigate with the UP / DOWN arrow keys, and you can select each element in the list with the space key. If you finished, just press the enter key.

To abort this prompt the following keys can be used:

  • Ctrl-C
  • Backspace
Parameters
sourcePointer to a source stream. The function will wait for a key to arrive on this channel.
lineTextCharacter array. You can specify the prompt instructions here.
numberOfElementsThe number of elements in the list.
listThe list of the options( string array )
timeoutTimeout in ms. If it is 0, that means no timeout.
selectionbool array to store the status of the selected elements. The size of this array should be equal to the size of the list. If an element is selected, the corresponding element in this array will be true. To enable multiple element selection mode, this pointer has to point to a valid array! [ optional, NULL by default( single element mode ) ]
Returns
In single element mode, it will return the index of the selected element. In multiple element mode, it will return the number of selected elements from the list. If timeout or abort event occurs, it will return -1. Generate a beep sound on the terminal device.

Definition at line 1014 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ begin()

void Shellminator::begin ( const char *  banner_p)

Shellminator initialization function.

This function initializes the object and prints the startup logo.

Note
The length of this string has to be less, or equal than SHELLMINATOR_BANNER_LEN. Leftover characters are truncated!
Warning
You have to call this function before all other member functions!
Parameters
banner_pthis is equivalent to a user name in linux like terminals. It is just a visual thing.

Definition at line 437 of file Shellminator.cpp.

Here is the call graph for this function:

◆ beginScreen()

void Shellminator::beginScreen ( ShellminatorScreen screen_p,
int  updatePeriod = 250 
)

Register Screen object to draw.

This function can be used to register a Screen object to the terminal. After the Screen object is registered, it will take over the control against the terminal interface.

Parameters
screen_pPointer to a screen object.
updatePeriodOptionally, you can specify the screen refresh time in milliseconds.
Note
To close the Screen, you have to press the return or the abort( ctrl+c ) key.
To close the Screen session from code, you can use the endScreen function.

Definition at line 1794 of file Shellminator.cpp.

Here is the call graph for this function:

◆ castVoidToShellminator()

Shellminator * Shellminator::castVoidToShellminator ( void *  ptr)
static

This is a helper function for pointer casting.

It is designed to be used with Commander-API, when you have to cast a void* to Shellminator*.

Parameters
ptrPointer to a Shellminator object in void*.
Warning
The address stored in ptr has to be a valid addres for a Shellminator object.
Returns
Casted pointer.
Todo:
track the created objects in an internal static array and compare their pointer values with the given one.

Definition at line 1766 of file Shellminator.cpp.

◆ checkCommandFraction()

void Shellminator::checkCommandFraction ( )
protectedvirtual

Check the command with the command parser to get some useful information.

Reimplemented in ShellminatorCommanderInterface.

Definition at line 307 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ checkPassword()

bool Shellminator::checkPassword ( const char *  password)
private

Check the password.

This function generates a hash from its argument string and compares it with the hash stored in the passwordHash array.

Parameters
passwordInput text to compare.
Returns
If the computed and the stored hash matches, it will return true.

Definition at line 352 of file Shellminator-Crypto.cpp.

Here is the caller graph for this function:

◆ clear()

void Shellminator::clear ( )

Clear screen.

This function clears the terminal screen.

Definition at line 68 of file Shellminator-Styles.cpp.

Here is the caller graph for this function:

◆ drawLogo()

void Shellminator::drawLogo ( )

Draws the startup logo.

Draws the startup logo in the terminal

Definition at line 975 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ enableBuffering()

bool Shellminator::enableBuffering ( uint8_t *  buffer,
int  bufferSize 
)

Enable buffering to gain speed.

With this function, a buffer can be attached to the object. It can be used to accelerate the printing process. Because this library meant to work on low power devices, with limited amount of dynamic memory, all rendering happens in place. It has one downside tough. The printing not happens in one time. Small independent printing actions renders the final result. The frontend on a PC can't handle this very well, if the data is coming fast. A much better solution is to collect the printed data into a buffer, and flush it, when we are finished. You can achieve this functionality with this function.

Parameters
bufferPointer to a buffer. It has to be uint8_t type.
bufferSizeThe size of the buffer in elements.
Returns
When the buffering is enabled successfully, it will return true.
Note
On low-end devices like an AVR, it might be too much. I suggest to use this functionality on systems that has at least 10kBytes of dynamic memory.

Definition at line 67 of file Shellminator.cpp.

◆ endScreen()

void Shellminator::endScreen ( )

Abort Screen session.

With this function you can abort a registered Screen session.

Definition at line 1895 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ eventAvailable()

int Shellminator::eventAvailable ( )

Get the number of events available for reading from the eventBuffer.

Returns
The number of events available to read.

Definition at line 54 of file Shellminator-Events.cpp.

◆ executeWithCommandParser()

void Shellminator::executeWithCommandParser ( )
protectedvirtual

Reimplemented in ShellminatorCommanderInterface.

Definition at line 311 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ format() [1/3]

void Shellminator::format ( Stream *  stream_p,
int  firstArg 
)

Basic text formatting.

You can use this function to modify the style or color of the printed text. This function can only be accessed with an object.

Note
It will only work with VT100 compatible terminal emulators. Sadly Arduino Serial monitor does not support these features.
Parameters
stream_pPointer to a Stream object.
firstArgThe first format specifier.
...All other format specifiers. The last argument must be a negative integer number!
Note
It will only do anything if the formatting is enabled on the corresponding object. Please check enableFormatting for more information.
Warning
There is a dedicated macro for this function, called format. Please use this macro to avoid problems.

Definition at line 111 of file Shellminator-Styles.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ format() [2/3]

void Shellminator::format ( Stream *  stream_p,
int  firstArg,
int  secondArg 
)

Definition at line 117 of file Shellminator-Styles.cpp.

Here is the call graph for this function:

◆ format() [3/3]

void Shellminator::format ( Stream *  stream_p,
int  firstArg,
int  secondArg,
int  thirdArg 
)

Definition at line 123 of file Shellminator-Styles.cpp.

Here is the call graph for this function:

◆ freeAbortKey()

void Shellminator::freeAbortKey ( )

Reset abort key functionality to default.

This function resets the abort key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 96 of file Shellminator-SpecialKeys.cpp.

◆ freeDownArrow()

void Shellminator::freeDownArrow ( )

Reset down arrow key functionality to default.

This function resets the down arrow functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 84 of file Shellminator-SpecialKeys.cpp.

◆ freeEndKey()

void Shellminator::freeEndKey ( )

Reset End key functionality to default.

This function resets the End key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 112 of file Shellminator-SpecialKeys.cpp.

◆ freeHomeKey()

void Shellminator::freeHomeKey ( )

Reset Home key functionality to default.

This function resets the Home key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 108 of file Shellminator-SpecialKeys.cpp.

◆ freeLeftArrow()

void Shellminator::freeLeftArrow ( )

Reset left arrow key functionality to default.

This function resets the left arrow functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 88 of file Shellminator-SpecialKeys.cpp.

◆ freeLogoutKey()

void Shellminator::freeLogoutKey ( )

Reset Logout key functionality to default.

This function resets the Logout key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 116 of file Shellminator-SpecialKeys.cpp.

◆ freePageDownKey()

void Shellminator::freePageDownKey ( )

Reset Page-Down key functionality to default.

This function resets the Page-Down key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 104 of file Shellminator-SpecialKeys.cpp.

◆ freePageUpKey()

void Shellminator::freePageUpKey ( )

Reset Page-Up key functionality to default.

This function resets the Page-Up key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 100 of file Shellminator-SpecialKeys.cpp.

◆ freeRightArrow()

void Shellminator::freeRightArrow ( )

Reset right arrow key functionality to default.

This function resets the right arrow functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 92 of file Shellminator-SpecialKeys.cpp.

◆ freeSearchKey()

void Shellminator::freeSearchKey ( )

Reset Search key functionality to default.

This function resets the Search key functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 120 of file Shellminator-SpecialKeys.cpp.

◆ freeUpArrow()

void Shellminator::freeUpArrow ( )

Reset up arrow key functionality to default.

This function resets the up arrow functionality to default. If you want to detach the override function for the key, you have to call this function.

Definition at line 80 of file Shellminator-SpecialKeys.cpp.

◆ getBufferedPrinter()

ShellminatorBufferedPrinter * Shellminator::getBufferedPrinter ( )

Get the buffered printer object address.

With this function the bufferedPrinter object can be accessed from outside.

Returns
If it returns NULL that means, the buffered printer is not enabled, or the memory allocation for it is failed. In this case it is not usable. If it is not NULL, you can use it.

Definition at line 88 of file Shellminator.cpp.

◆ getCursorPosition()

bool Shellminator::getCursorPosition ( int *  x,
int *  y,
uint32_t  timeout = 250 
)

Get the position of the cursor.

This function can be used to query the current location of the cursor. The result will be passed back on the arguments.

Parameters
xPointer to an integer. The horizontal coordinate will be written to the variable where this pointer points.
yPointer to an integer. The horizontal coordinate will be written to the variable where this pointer points.
timeoutYou can specify a maximum time to wait for the answer in milliseconds. the default value is 100ms.
Returns
If the query was successful it will return true. Otherwise the value in the variables corresponding to x and y is not usable.

The screen coordinate system works like this: Screen Coordinate System The origin is on the top left and it's coordinate is 1;1. The screen size can vary.

Definition at line 748 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ getTerminalSize()

bool Shellminator::getTerminalSize ( int *  width,
int *  height 
)

Definition at line 946 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hasCommandParser()

bool Shellminator::hasCommandParser ( )
protectedvirtual

Reimplemented in ShellminatorCommanderInterface.

Definition at line 319 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ hideCursor() [1/2]

void Shellminator::hideCursor ( )

Hide the cursor.

This function disables the cursor on the host terminal. This function can only be accessed with an object.

Note
It will only do anything if the formatting is enabled on the corresponding object. Please check enableFormatting for more information.

Definition at line 36 of file Shellminator-Styles.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hideCursor() [2/2]

void Shellminator::hideCursor ( Stream *  stream_p)
static

Hide the cursor.

This function disables the cursor on the host terminal. This function can be accessed outside of the class.

Parameters
stream_pPointer to a Stream object.

Definition at line 42 of file Shellminator-Styles.cpp.

◆ historySearchBackward()

void Shellminator::historySearchBackward ( )
private

This function is used to search the previous matching command in the history.

Definition at line 36 of file Shellminator-SearchModule.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ historySearchForward()

void Shellminator::historySearchForward ( )
private

This function is used to search the next matching command in the history.

Definition at line 86 of file Shellminator-SearchModule.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ input()

void Shellminator::input ( char *  buffer,
int  bufferSize,
const char *  instruction,
void(*)(char *, int, Shellminator *)  callback,
bool  secret = false 
)

Input prompt.

It is a simple prompt for user input. You can create simple queries with this function. This is a non-blocking function, and this means, that the it will take over the control from the terminal until the user finishes. It can be interrupted with the abort key( ctrl-c ).

Parameters
bufferPointer to a buffer. The typed text will be copied to this buffer. The result will be always terminated to make it compatible with str functions.
bufferSizeThe size of the buffer.
instructionInstruction text for the prompt. It can be helpful to instruct the user about what information is needed in this prompt.
callbackWhen the input typed the data and the return key is pressed, this function will be called. The typed text will be available on the arguments.
secretIf you has to request some sensitive data, you can set this flag to true. This way, the prompt will echo back * characters instead of the actual ones.

Example callback function:

void inputCallback( char* text, int textSize, Shellminator* parent ){
parent -> print( "Hurray! I got something: " );
parent -> print( text );
}
void(* inputCallback)(char *, int, Shellminator *)
This function will be called when an input is finished.

Definition at line 36 of file Shellminator-Input.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ logOut()

void Shellminator::logOut ( )

Definition at line 1972 of file Shellminator.cpp.

Here is the call graph for this function:

◆ mouseBegin()

void Shellminator::mouseBegin ( )

Enable mouse reports.

With this function you can enable X-term like mouse reporting on the host terminal.

Note
Sadly it won't work on the Windows emulator 😞. However it works with Xterm.js and PuTTY.

Definition at line 36 of file Shellminator-MouseInterface.cpp.

Here is the caller graph for this function:

◆ mouseEnd()

void Shellminator::mouseEnd ( )

Disable mouse reports.

Definition at line 47 of file Shellminator-MouseInterface.cpp.

Here is the caller graph for this function:

◆ overrideAbortKey()

void Shellminator::overrideAbortKey ( void(*)(Shellminator *)  func)

Override abort key behaviour.

With this function you can attach a function that will be called every time when the abort key is pressed. The default abort key is usually a Ctrl + C combo.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 52 of file Shellminator-SpecialKeys.cpp.

◆ overrideDownArrow()

void Shellminator::overrideDownArrow ( void(*)(Shellminator *)  func)

Override down arrow key behaviour.

With this function you can attach a function that will be called every time when the down arrow key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 40 of file Shellminator-SpecialKeys.cpp.

◆ overrideEndKey()

void Shellminator::overrideEndKey ( void(*)(Shellminator *)  func)

Override End key behaviour.

With this function you can attach a function that will be called every time when the End key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 68 of file Shellminator-SpecialKeys.cpp.

◆ overrideHomeKey()

void Shellminator::overrideHomeKey ( void(*)(Shellminator *)  func)

Override Home key behaviour.

With this function you can attach a function that will be called every time when the Home key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 64 of file Shellminator-SpecialKeys.cpp.

◆ overrideLeftArrow()

void Shellminator::overrideLeftArrow ( void(*)(Shellminator *)  func)

Override left arrow key behaviour.

With this function you can attach a function that will be called every time when the left arrow key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 44 of file Shellminator-SpecialKeys.cpp.

◆ overrideLogoutKey()

void Shellminator::overrideLogoutKey ( void(*)(Shellminator *)  func)

Override Logout key behaviour.

With this function you can attach a function that will be called every time when the Logout key is pressed. The default Logout key is usually a Ctrl + D combo.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 72 of file Shellminator-SpecialKeys.cpp.

◆ overridePageDownKey()

void Shellminator::overridePageDownKey ( void(*)(Shellminator *)  func)

Override Page-Down key behaviour.

With this function you can attach a function that will be called every time when the Page-Down key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 60 of file Shellminator-SpecialKeys.cpp.

◆ overridePageUpKey()

void Shellminator::overridePageUpKey ( void(*)(Shellminator *)  func)

Override Page-Up key behaviour.

With this function you can attach a function that will be called every time when the Page-Up key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 56 of file Shellminator-SpecialKeys.cpp.

◆ overrideRightArrow()

void Shellminator::overrideRightArrow ( void(*)(Shellminator *)  func)

Override right arrow key behaviour.

With this function you can attach a function that will be called every time when the right arrow key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 48 of file Shellminator-SpecialKeys.cpp.

◆ overrideSearchKey()

void Shellminator::overrideSearchKey ( void(*)(Shellminator *)  func)

Override Search key behaviour.

With this function you can attach a function that will be called every time when the Logout key is pressed. The default Search key is usually a Ctrl + R combo.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 76 of file Shellminator-SpecialKeys.cpp.

◆ overrideUpArrow()

void Shellminator::overrideUpArrow ( void(*)(Shellminator *)  func)

Override up arrow key behaviour.

With this function you can attach a function that will be called every time when the up arrow key is pressed.

Parameters
funcPointer to the function that will be called on keypress.

Definition at line 36 of file Shellminator-SpecialKeys.cpp.

◆ parseMouseData()

void Shellminator::parseMouseData ( )
private

Parse mouse data.

It is used by the main state machine. Its main task is to parse the mouse string and if it is parsed successfully, generate a new event in the event buffer for it.

Definition at line 95 of file Shellminator-MouseInterface.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ popEvent()

void Shellminator::popEvent ( )

Remove the current element from the buffer.

It has to be used after calling the update function of the attached Screen object. This way an event won't get parsed multiple times.

Definition at line 103 of file Shellminator-Events.cpp.

Here is the caller graph for this function:

◆ printBanner()

void Shellminator::printBanner ( )

This function prints the banner text.

Definition at line 155 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ printCommandParserHelp()

void Shellminator::printCommandParserHelp ( Stream *  channel_p,
bool  formatting_p 
)
protectedvirtual

Print command parser Help.

Reimplemented in ShellminatorCommanderInterface.

Definition at line 303 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ printHelp()

void Shellminator::printHelp ( )

Print help text.

Definition at line 324 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ printHistory()

void Shellminator::printHistory ( )

Print command history.

Definition at line 207 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ printLoginScreen()

void Shellminator::printLoginScreen ( )

Definition at line 1987 of file Shellminator.cpp.

Here is the call graph for this function:

◆ process()

void Shellminator::process ( char  new_char)
private

This function processes a new character.

This function handles every character that arrives from the terminal software. It called by the update function every time when the Serial buffer has some unprocessed characters.

Parameters
new_charThis is the nex character that has to be processed.

Definition at line 633 of file Shellminator.cpp.

Here is the caller graph for this function:

◆ pushEvent()

void Shellminator::pushEvent ( shellEvent_t  event)
private

Push a new event to the event buffer.

Definition at line 36 of file Shellminator-Events.cpp.

Here is the caller graph for this function:

◆ readEvent()

Shellminator::shellEvent_t Shellminator::readEvent ( )

Read an event.

With this function, you can read an event from the event buffer. Unlike Arduino-like read methods, this won't pop the event from the buffer after reading. This way a complex Screen layout is much easier to make.

Returns
The next available event from the event buffer.
Note
If there is no available event in the buffer, the returned event type will be SHELL_EVENT_EMPTY.

Definition at line 76 of file Shellminator-Events.cpp.

Here is the caller graph for this function:

◆ redrawHistorySearch()

void Shellminator::redrawHistorySearch ( )
private

If reverse search mode is active, this function is used to print the text correctly.

Definition at line 117 of file Shellminator-SearchModule.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ redrawLine()

void Shellminator::redrawLine ( )
protected

Definition at line 506 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ requestRedraw()

void Shellminator::requestRedraw ( )

Redraw request from a Screen object.

This function is used by the attached Screen object. The Screen object can signal the terminal interface with this function, to call the draw function in the next drawing session. The drawing only happens, when an event triggers it, to save some CPU time. This way the Screen drawing is much efficient.

Definition at line 1960 of file Shellminator.cpp.

◆ sendBackspace()

void Shellminator::sendBackspace ( )

Sends a backspace.

This function makes a backspace in the terminal application. Basically it deletes the last character in the terminal screen.

Definition at line 494 of file Shellminator.cpp.

◆ setBannerPathText()

void Shellminator::setBannerPathText ( const char *  bannerPath_p)

This function sets the banner path text.

It can be used when you want to change the banner path text runtime.

Parameters
banner_pString that contains the new banner text.
Note
the default banner path text is $

Banner Text Elements

Definition at line 115 of file Shellminator.cpp.

◆ setBannerText()

void Shellminator::setBannerText ( const char *  banner_p)

This function sets the banner text.

It can be used when you want to change the banner text runtime.

Parameters
banner_pString that contains the new banner text.

Banner Text Elements

Definition at line 103 of file Shellminator.cpp.

Here is the call graph for this function:

◆ setCursorPosition() [1/2]

void Shellminator::setCursorPosition ( int  x,
int  y 
)

Set the position of the cursor.

This function can be used to set the cursor location to a specified coordinate. This function can only be accessed with an object.

Parameters
xNew X-coordinate of the cursor.
yNew Y-coordinate of the cursor.

The screen coordinate system works like this: Screen Coordinate System The origin is on the top left and it's coordinate is 1;1. The screen size can vary.

Note
Setting an invalid cursor position is not possible, it is protected by the terminal interface and this function as well.

Definition at line 921 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setCursorPosition() [2/2]

void Shellminator::setCursorPosition ( Stream *  channel_p,
int  x,
int  y 
)
static

Set the position of the cursor.

This function can be used to set the cursor location to a specified coordinate. This function can be accessed outside of the class.

Parameters
channel_pPointer to a Stream object.
xNew X-coordinate of the cursor.
yNew Y-coordinate of the cursor.

The screen coordinate system works like this: Screen Coordinate System The origin is on the top left and it's coordinate is 1;1. The screen size can vary.

Note
Setting an invalid cursor position is not possible, it is protected by the terminal interface and this function as well.

Definition at line 927 of file Shellminator.cpp.

◆ setFormat() [1/3]

void Shellminator::setFormat ( Stream *  stream_p,
int  firstArg 
)
static

Basic text formatting.

You can use this function to modify the style or color of the printed text. This function can be accessed from outside of an object.

Note
It will only work with VT100 compatible terminal emulators. Sadly Arduino Serial monitor does not support these features.
Parameters
stream_pPointer to a Stream object.
firstArgThe first format specifier.
...All other format specifiers. The last argument must be a negative integer number!
Warning
There is a dedicated macro for this function, called setFormat. Please use this macro to avoid problems.
Note
If formatting is disabled on the object, it won't do anything.

Definition at line 75 of file Shellminator-Styles.cpp.

Here is the caller graph for this function:

◆ setFormat() [2/3]

void Shellminator::setFormat ( Stream *  stream_p,
int  firstArg,
int  secondArg 
)
static

Definition at line 85 of file Shellminator-Styles.cpp.

◆ setFormat() [3/3]

void Shellminator::setFormat ( Stream *  stream_p,
int  firstArg,
int  secondArg,
int  thirdArg 
)
static

Definition at line 97 of file Shellminator-Styles.cpp.

◆ setPassword()

void Shellminator::setPassword ( uint8_t *  hashData,
int  hashSize 
)

Enable login password.

With this function you can add a login password. There is a twist in the story tough. Instead of storing the password itself, we have to store a hash that is generated from the password. The reason for this is simple. If you store the password, it can be dumped from the compiled firmware and it is easily hackable. If you store a hash, that is generated from the password, it is much safer, because ideally, you can not generate the original password back from its hash.

The default implementation uses a crc32 hash generator. It is not the safest, and not the prettiest, but it can be run on low end hardware fairly well. You can replace this hash algorithm to a custom one with the setPasswordHashFunction.

Using this is fairly simple, you need to generate a hash from your password. You can find an online hash generator here. Set the input to ASCII and the output to HEX with CRC32 mode. For this demo I will use Password as password. The online tool calculated the result which is 0xCCB42483. This is all the information what we need.

Example code:

// We have to split the hash to bytes. The default CRC32
// hash function produces a 32-bit( 4-byte ) hash, so
// we have to split the hash into 4-bytes. Splitting
// 0xCCB42483 is easy.
uint8_t passwordHash[] = { 0xCC, 0xB4, 0x24, 0x83 };
// Attach the hash to the terminal object in the init section.
shell.setPassword( passwordHash, sizeof( passwordHash ) );
uint8_t * passwordHash
Stores the address of the password hash array.

Definition at line 342 of file Shellminator-Crypto.cpp.

Here is the call graph for this function:

◆ setPasswordHashFunction()

void Shellminator::setPasswordHashFunction ( void(*)(uint8_t *, int, uint8_t *, int)  hashFunc_p)

Replace the built-in CRC32 hash generator.

If you want some more modern solution instead of the good old CRC32, you can do this with this function. You need a hash function which looks like this:

void customHash( uint8_t* inputData, int inputDataSize, uint8_t* outputData, int outputDataSize );

The hash must be generated from the inputData, and it's must be generated to the outputData.

Warning
It is very, very important to specify the correct hash size with the setPassword function in the init section. This will determinate the allocated memory for the outputData buffer. If it not set correctly, it will cause buffer overflow!
Note
Hash functions usually produce a fixed length hash. For example CRC32 produces a 32-bit hash, SHA256 produces a 256-bit hash... Please select a hash function with fixed length result and use this length as the second argument for the setPassword function.

Definition at line 348 of file Shellminator-Crypto.cpp.

◆ ShellminatorAbortState()

void Shellminator::ShellminatorAbortState ( )
private

Definition at line 1495 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorAutoCompleteState()

void Shellminator::ShellminatorAutoCompleteState ( )
private

Definition at line 1485 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorBackspaceState()

void Shellminator::ShellminatorBackspaceState ( )
private

Definition at line 1199 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorBeginningOfLineState()

void Shellminator::ShellminatorBeginningOfLineState ( )
private

Definition at line 1416 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorClearScreenState()

void Shellminator::ShellminatorClearScreenState ( )
private

Definition at line 1474 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorDefaultState()

void Shellminator::ShellminatorDefaultState ( char  new_char)
private
Todo:
Finish the documentation for state-machine part.

Definition at line 1030 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorDelKeyState() [1/2]

void Shellminator::ShellminatorDelKeyState ( )
private

Definition at line 391 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorDelKeyState() [2/2]

void Shellminator::ShellminatorDelKeyState ( char  new_char)
private

Definition at line 425 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:

◆ ShellminatorDownArrowKeyState()

void Shellminator::ShellminatorDownArrowKeyState ( )
private

Definition at line 180 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorEndKeyState() [1/2]

void Shellminator::ShellminatorEndKeyState ( )
private

Definition at line 359 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorEndKeyState() [2/2]

void Shellminator::ShellminatorEndKeyState ( char  new_char)
private

Definition at line 379 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:

◆ ShellminatorEndOfLineState()

void Shellminator::ShellminatorEndOfLineState ( )
private

Definition at line 1424 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorEnterKeyState()

void Shellminator::ShellminatorEnterKeyState ( )
private

Definition at line 1253 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorEscapeBracketState()

void Shellminator::ShellminatorEscapeBracketState ( char  new_char)
private

Definition at line 1538 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorEscapeCharacterState()

void Shellminator::ShellminatorEscapeCharacterState ( char  new_char)
private

Definition at line 1526 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorFourByteUnicodeFirstDataState()

void Shellminator::ShellminatorFourByteUnicodeFirstDataState ( char  new_char)
private

Definition at line 1182 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorFourByteUnicodeSecondDataState()

void Shellminator::ShellminatorFourByteUnicodeSecondDataState ( char  new_char)
private

Definition at line 1187 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorFourByteUnicodeThirdDataState()

void Shellminator::ShellminatorFourByteUnicodeThirdDataState ( char  new_char)
private

Definition at line 1192 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorHomeKeyState() [1/2]

void Shellminator::ShellminatorHomeKeyState ( )
private

Definition at line 321 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorHomeKeyState() [2/2]

void Shellminator::ShellminatorHomeKeyState ( char  new_char)
private

Definition at line 343 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:

◆ ShellminatorLeftArrowKeyState()

void Shellminator::ShellminatorLeftArrowKeyState ( )
private

Definition at line 245 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorLogoutState()

void Shellminator::ShellminatorLogoutState ( )
private

Definition at line 1432 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorMouseEventParserState()

void Shellminator::ShellminatorMouseEventParserState ( char  new_char)
private

Definition at line 56 of file Shellminator-MouseInterface.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorPageDownKeyState() [1/2]

void Shellminator::ShellminatorPageDownKeyState ( )
private

Definition at line 472 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorPageDownKeyState() [2/2]

void Shellminator::ShellminatorPageDownKeyState ( char  new_char)
private

Definition at line 495 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:

◆ ShellminatorPageUpKeyState() [1/2]

void Shellminator::ShellminatorPageUpKeyState ( )
private

Definition at line 437 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorPageUpKeyState() [2/2]

void Shellminator::ShellminatorPageUpKeyState ( char  new_char)
private

Definition at line 460 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:

◆ ShellminatorProcessRegularCharacter()

void Shellminator::ShellminatorProcessRegularCharacter ( char  new_char,
bool  draw = true 
)
private

Definition at line 1598 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorReverseSearchState()

void Shellminator::ShellminatorReverseSearchState ( )
private

Definition at line 1454 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorRightArrowKeyState()

void Shellminator::ShellminatorRightArrowKeyState ( )
private

Definition at line 282 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorThreeByteUnicodeFirstDataState()

void Shellminator::ShellminatorThreeByteUnicodeFirstDataState ( char  new_char)
private

Definition at line 1170 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorThreeByteUnicodeSecondDataState()

void Shellminator::ShellminatorThreeByteUnicodeSecondDataState ( char  new_char)
private

Definition at line 1175 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorTwoByteUnicodeDataState()

void Shellminator::ShellminatorTwoByteUnicodeDataState ( char  new_char)
private

Definition at line 1163 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ShellminatorUpArrowKeyState()

void Shellminator::ShellminatorUpArrowKeyState ( )
private

Definition at line 124 of file Shellminator-SpecialKeys.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ showCursor() [1/2]

void Shellminator::showCursor ( )

Show the cursor.

This function enables the cursor on the host terminal. This function can only be accessed with an object.

Note
It will only do anything if the formatting is enabled on the corresponding object. Please check enableFormatting for more information.

Definition at line 52 of file Shellminator-Styles.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ showCursor() [2/2]

void Shellminator::showCursor ( Stream *  stream_p)
static

Show the cursor.

This function enables the cursor on the host terminal. This function can be accessed outside of the class.

Parameters
stream_pPointer to a Stream object.

Definition at line 58 of file Shellminator-Styles.cpp.

◆ substring()

int Shellminator::substring ( char *  str1,
char *  str2 
)
private

Basic substring function.

The original source can be found here

Definition at line 215 of file Shellminator-SearchModule.cpp.

Here is the caller graph for this function:

◆ swapScreen()

void Shellminator::swapScreen ( ShellminatorScreen screen_p,
int  updatePeriod = 250 
)

Definition at line 1857 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ swapScreenAndClear()

void Shellminator::swapScreenAndClear ( ShellminatorScreen screen_p,
int  updatePeriod = 250 
)

Definition at line 1850 of file Shellminator.cpp.

Here is the call graph for this function:

◆ update()

void Shellminator::update ( )

Update function.

This function handles all of the communication related stuff between the code and the terminal application.

Warning
This function has to be called periodically. If the calling of this function is not frequent enough it can cause buffer overflow in the Serial driver!

Definition at line 640 of file Shellminator.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ waitForKey() [1/2]

bool Shellminator::waitForKey ( Stream *  source,
char *  keys,
uint32_t  timeout = 0 
)
static

Wait for specific keypress.

It can be useful with a simple prompt like waiting for Y or N characters. It can be useful, for multiple key detection. For example upper and lower case detection as well.

Parameters
sourcePointer to a source stream. The function will wait for a key to arrive on this channel.
keysCharacter array. Array of characters for match detection.
timeoutTimeout in ms. If it is 0, that means no timeout. [ optional, 0 by default ]
Returns
True if any of the expected keys match.

Definition at line 1725 of file Shellminator.cpp.

◆ waitForKey() [2/2]

bool Shellminator::waitForKey ( Stream *  source,
char  key,
uint32_t  timeout = 0 
)
static

Wait for specific keypress.

It can be useful with a simple prompt like waiting for Y or N characters.

Parameters
sourcePointer to a source stream. The function will wait for a key to arrive on this channel.
keyExpected key. For example in a Yes/No prompt you expect 'Y' or 'y' to arrive.
timeoutTimeout in ms. If it is 0, that means no timeout. [ optional, 0 by default ]
Returns
True if the expected key is arrived.

Definition at line 1693 of file Shellminator.cpp.

Friends And Related Function Documentation

◆ ShellminatorProgress

friend class ShellminatorProgress
friend

Definition at line 893 of file Shellminator.hpp.

◆ ShellminatorUT

friend class ShellminatorUT
friend

Definition at line 1174 of file Shellminator.hpp.

Member Data Documentation

◆ abortKeyFunc

void(* Shellminator::abortKeyFunc) (Shellminator *) = NULL
private

Function pointer for abort key behaviour override.

Definition at line 1090 of file Shellminator.hpp.

◆ banner

char Shellminator::banner[SHELLMINATOR_BANNER_LEN] = {'\0'}
private

This character array stores the banner text.

Definition at line 1067 of file Shellminator.hpp.

◆ bannerPath

char Shellminator::bannerPath[SHELLMINATOR_BANNER_PATH_LEN] = "$"
private

This character array stores the banner path text.

default banner path text is $.

Definition at line 1071 of file Shellminator.hpp.

◆ bufferedPrinter

ShellminatorBufferedPrinter Shellminator::bufferedPrinter
private

It can be used to accelerate the data sending process.

With this, the output will be rendered once without flickering.

Definition at line 940 of file Shellminator.hpp.

◆ bufferMemoryAllocated

bool Shellminator::bufferMemoryAllocated = false
private

If memory is allocated, this will be true;.

Definition at line 943 of file Shellminator.hpp.

◆ channel

Stream* Shellminator::channel = NULL

Pointer to the communication class.

By default it points to the default response handler.

Definition at line 879 of file Shellminator.hpp.

◆ cmd_buff

char Shellminator::cmd_buff[SHELLMINATOR_BUFF_DIM][SHELLMINATOR_BUFF_LEN+1] = {{0}}
protected

Text buffer.

This array stores the incoming and the previous commands. The 0th element always reserved to hold the incoming data. All other elements are holds the previous commands. Every new command shifts the elements towards the higher index, and removes the highest index element. To navigate between the previous commands you can use the UP and DOWN arrows on the keyboard. To specify the 'memory' of the interface you have to configure the SHELLMINATOR_BUFF_DIM definition.

Warning
The value of the SHELLMINATOR_BUFF_DIM definition has to be at least 2!
Note
Be careful with the value of the definition. If it is to high your RAM will be eaten!

Definition at line 907 of file Shellminator.hpp.

◆ cmd_buff_cntr

uint32_t Shellminator::cmd_buff_cntr = 0
protected

This variable tracks the end of the input message.

Definition at line 913 of file Shellminator.hpp.

◆ cmd_buff_dim

uint32_t Shellminator::cmd_buff_dim = 1
protected

This variable tracks the index of the previous command while you browsing the command history.

Definition at line 910 of file Shellminator.hpp.

◆ colorizer

DefaultColorizer* Shellminator::colorizer = &this->defaultColorizer
private

Definition at line 964 of file Shellminator.hpp.

◆ commandFound

bool Shellminator::commandFound = false
protected

This flag must be set true in checkCommandFraction function when the command parser contains the command.

Definition at line 920 of file Shellminator.hpp.

◆ currentState

void(Shellminator::* Shellminator::currentState) (char) = &Shellminator::ShellminatorDefaultState
private

Function pointer to the current state of the main state-machine.

Definition at line 1027 of file Shellminator.hpp.

◆ cursor

uint32_t Shellminator::cursor = 0
protected

This variable tracks the location of the next character.

Definition at line 916 of file Shellminator.hpp.

◆ defaultColorizer

DefaultColorizer Shellminator::defaultColorizer
private

Definition at line 963 of file Shellminator.hpp.

◆ downArrowOverrideFunc

void(* Shellminator::downArrowOverrideFunc) (Shellminator *) = NULL
private

Function pointer for down arrow behaviour override.

Definition at line 1081 of file Shellminator.hpp.

◆ enableFormatting

bool Shellminator::enableFormatting = true

This flag enables or disables character formatting.

It can be useful when VT100 format parser is not available on the host device.

Definition at line 872 of file Shellminator.hpp.

◆ endKeyFunc

void(* Shellminator::endKeyFunc) (Shellminator *) = NULL
private

Function pointer for End key behaviour override.

Definition at line 1102 of file Shellminator.hpp.

◆ escape_state

uint32_t Shellminator::escape_state = 0
private

This variable tracks the state of the VT100 decoder state-machine.

Definition at line 1064 of file Shellminator.hpp.

◆ eventBuffer

shellEvent_t Shellminator::eventBuffer[EVENT_BUFFER_SIZE]

The events are stored in this buffer.

It uses a circular structure to store the events. Usually this buffer should not has to be big.

Definition at line 734 of file Shellminator.hpp.

◆ eventBufferReadPtr

uint8_t Shellminator::eventBufferReadPtr

Read position for the eventBuffers circular structure.

Definition at line 740 of file Shellminator.hpp.

◆ eventBufferWritePtr

uint8_t Shellminator::eventBufferWritePtr

Write position for the eventBuffers circular structure.

Definition at line 737 of file Shellminator.hpp.

◆ execution_fn

void(* Shellminator::execution_fn) (char *, Shellminator *)
private

This function-pointer stores the execution function pointer.

This function will be called when a command receives.

Definition at line 1057 of file Shellminator.hpp.

◆ homeKeyFunc

void(* Shellminator::homeKeyFunc) (Shellminator *) = NULL
private

Function pointer for Home key behaviour override.

Definition at line 1099 of file Shellminator.hpp.

◆ inputActive

bool Shellminator::inputActive = false
private

This flag will be true when an input prompt is active.

Definition at line 1148 of file Shellminator.hpp.

◆ inputCallback

void(* Shellminator::inputCallback) (char *, int, Shellminator *)
private

This function will be called when an input is finished.

Definition at line 1167 of file Shellminator.hpp.

◆ inputDestinationBuffer

char* Shellminator::inputDestinationBuffer
private

Pointer to a buffer that will be used to store the text, that is typed to an input.

Definition at line 1156 of file Shellminator.hpp.

◆ inputDestinationBufferSize

int Shellminator::inputDestinationBufferSize
private

Size of the buffer that is attached to an input.

Definition at line 1159 of file Shellminator.hpp.

◆ inputInstuctionSize

int Shellminator::inputInstuctionSize = 0
private

This will store the length of the instruction text size in an input.

Definition at line 1152 of file Shellminator.hpp.

◆ inputSecretMode

bool Shellminator::inputSecretMode
private

If secret mode is activated on an input, this flag will be true.

Definition at line 1163 of file Shellminator.hpp.

◆ inSearch

bool Shellminator::inSearch = false
private

If reverse search mode is active, this flag will be true.

Definition at line 1142 of file Shellminator.hpp.

◆ lastBannerSize

uint8_t Shellminator::lastBannerSize = 0
private

Size of the last printed banner in characters.

It's used to accelerate the redrawing process.

Definition at line 1075 of file Shellminator.hpp.

◆ lastKeyPressTime

uint32_t Shellminator::lastKeyPressTime = 0
private

Last time in ms when a key was pressed.

Definition at line 1170 of file Shellminator.hpp.

◆ leftArrowOverrideFunc

void(* Shellminator::leftArrowOverrideFunc) (Shellminator *) = NULL
private

Function pointer for left arrow behaviour override.

Definition at line 1084 of file Shellminator.hpp.

◆ loggedIn

bool Shellminator::loggedIn = false
private

If logging in is required this flag will be true.

Definition at line 973 of file Shellminator.hpp.

◆ logo

char* Shellminator::logo = NULL
private

Pointer to a string that holds the startup logo.

Simple text that holds the startup logo. You can create custom logos with a text to ASCII converter.

Warning
Make sure that the generated string is c/c++ compatible!

Definition at line 1034 of file Shellminator.hpp.

◆ logoutKeyFunc

void(* Shellminator::logoutKeyFunc) (Shellminator *) = NULL
private

Function pointer for Logout key behaviour override.

Definition at line 1105 of file Shellminator.hpp.

◆ mouseEventBuffer

char Shellminator::mouseEventBuffer[SHELLMINATOR_MOUSE_PARSER_BUFFER_SIZE]

This buffer is used to parse the mouse coordinates form the host terminals answer.

Definition at line 771 of file Shellminator.hpp.

◆ mouseEventBufferCounter

uint8_t Shellminator::mouseEventBufferCounter = 0

This variable traks the next free characters location in the mouseEventBuffer.

Definition at line 774 of file Shellminator.hpp.

◆ mute

bool Shellminator::mute = false

If set, the buzzer will be silent.

Definition at line 875 of file Shellminator.hpp.

◆ neofetch_fn

void(* Shellminator::neofetch_fn) (Shellminator *)
private

This function-pointer stores the neofetch function pointer.

This function will be called when the neofetch command receives.

Definition at line 1061 of file Shellminator.hpp.

◆ pageDownKeyFunc

void(* Shellminator::pageDownKeyFunc) (Shellminator *) = NULL
private

Function pointer for Page-Down key behaviour override.

Definition at line 1096 of file Shellminator.hpp.

◆ pageUpKeyFunc

void(* Shellminator::pageUpKeyFunc) (Shellminator *) = NULL
private

Function pointer for Page-Up key behaviour override.

Definition at line 1093 of file Shellminator.hpp.

◆ passwordHash

uint8_t* Shellminator::passwordHash = NULL
private

Stores the address of the password hash array.

Definition at line 967 of file Shellminator.hpp.

◆ passwordHashFunc

void(* Shellminator::passwordHashFunc) (uint8_t *, int, uint8_t *, int) = NULL
private

Pointer to the hash function.

Definition at line 976 of file Shellminator.hpp.

◆ passwordHashSize

int Shellminator::passwordHashSize = 0
private

Stores the password hash array size.

Definition at line 970 of file Shellminator.hpp.

◆ progmemLogo

__FlashStringHelper* Shellminator::progmemLogo = NULL
private

On AVR there is an oprion to store the logo in the program memory.

Note
I highly recommend using this on AVR to save some memory.

Definition at line 1052 of file Shellminator.hpp.

◆ rightArrowOverrideFunc

void(* Shellminator::rightArrowOverrideFunc) (Shellminator *) = NULL
private

Function pointer for right arrow behaviour override.

Definition at line 1087 of file Shellminator.hpp.

◆ screen

ShellminatorScreen* Shellminator::screen = NULL
private

Pointer to a ShellminatorScreen object.

It will be used when Screen drawing is enabled.

Definition at line 947 of file Shellminator.hpp.

◆ screenRedraw

bool Shellminator::screenRedraw
private

This flag shows if a request come from the Screen object to issue a draw function call.

Definition at line 961 of file Shellminator.hpp.

◆ screenTimerStart

unsigned long Shellminator::screenTimerStart = 0
private

The screen is drawn within a pre-defined periods.

This variable stores the last time when a drawing event occurred.

Definition at line 952 of file Shellminator.hpp.

◆ screenUpdatePeriod

int Shellminator::screenUpdatePeriod
private

The time interval between two drawings.

Definition at line 957 of file Shellminator.hpp.

◆ searchKeyFunc

void(* Shellminator::searchKeyFunc) (Shellminator *) = NULL
private

Function pointer for Search key behaviour override.

Definition at line 1108 of file Shellminator.hpp.

◆ searchMatch

int Shellminator::searchMatch
private

Used to parse reverse search.

Definition at line 1145 of file Shellminator.hpp.

◆ sizeTimerStart

unsigned long Shellminator::sizeTimerStart = 0
private

Definition at line 954 of file Shellminator.hpp.

◆ terminalHeight

int Shellminator::terminalHeight = 12

Stores the height of the terminal in characters.

Definition at line 767 of file Shellminator.hpp.

◆ terminalWidth

int Shellminator::terminalWidth = 30

Stores the width of the terminal in characters.

Definition at line 764 of file Shellminator.hpp.

◆ upArrowOverrideFunc

void(* Shellminator::upArrowOverrideFunc) (Shellminator *) = NULL
private

Function pointer for up arrow behaviour override.

Definition at line 1078 of file Shellminator.hpp.

◆ version

const char * Shellminator::version = SHELLMINATOR_VERSION
static

String, that holds the version information.

Definition at line 156 of file Shellminator.hpp.