diff --git a/VortexEngine/src/Serial/Serial.cpp b/VortexEngine/src/Serial/Serial.cpp index c5ec65be2d..f858954b39 100644 --- a/VortexEngine/src/Serial/Serial.cpp +++ b/VortexEngine/src/Serial/Serial.cpp @@ -55,15 +55,15 @@ bool SerialComs::checkSerial() if (!Vortex::vcallbacks()->serialCheck()) { return false; } - Vortex::vcallbacks()->serialBegin(9600); + Vortex::vcallbacks()->serialBegin(SERIAL_BAUD_RATE); #else // This will check if the serial communication is open - if (!Serial) { + if (!Serial.available()) { // serial is not connected return false; } // Begin serial communications - Serial.begin(9600); + Serial.begin(SERIAL_BAUD_RATE); #endif #endif // serial is now connected diff --git a/VortexEngine/src/VortexConfig.h b/VortexEngine/src/VortexConfig.h index 6dc584cb6a..fd02ec5702 100644 --- a/VortexEngine/src/VortexConfig.h +++ b/VortexEngine/src/VortexConfig.h @@ -299,6 +299,11 @@ #define VAL_OPTION_3 170 #define VAL_OPTION_4 255 +// Serial Baud Rate +// +// The serial connection baud rate for the editor and anything else serial +#define SERIAL_BAUD_RATE 9600 + // =================================================================== // Boolean Configurations (0 or 1)