Added serial.available() control in for loop of serialReader in order to know if at least one byte is available.
Modified function serialReader. We read a buffer of size 100 and data received are stored in an string variable before sent to JS.
Added notify("disconnect") & CodebenderccAPI::disconnect() in exceptions of functions serialReader() and serialWrite.
When an exception is thrown we ask javascript to close serial monitor window and then we call disconnect() to close serial port.
Unified Timeout used in openPort function for Windows and Linux.
Added serialMonitor mutex in functions serialReader and disconnect.