diff --git a/Devices/Control/Firmware/lib/Communicator/Communicator.cpp b/Devices/Control/Firmware/lib/Communicator/Communicator.cpp index 42fbea3..ffa6c8f 100644 --- a/Devices/Control/Firmware/lib/Communicator/Communicator.cpp +++ b/Devices/Control/Firmware/lib/Communicator/Communicator.cpp @@ -16,12 +16,12 @@ int Communicator::getBufferSize() return this->bufferSize; } -int Communicator::calculateMessageOutSize(int numberOfValues) +__SIZE_TYPE__ Communicator::calculateMessageOutSize(__SIZE_TYPE__ numberOfValues) { return numberOfValues + (numberOfValues - 1) + 1; } -void Communicator::parseIDs(int *values, int numberOfValues, char *output) +void Communicator::parseIDs(int *values, __SIZE_TYPE__ numberOfValues, char *output) { __SIZE_TYPE__ outputSize = calculateMessageOutSize(numberOfValues); __SIZE_TYPE__ outputCharPointer = 0; @@ -33,4 +33,16 @@ void Communicator::parseIDs(int *values, int numberOfValues, char *output) if (outputCharPointer < outputSize - 1) output[outputCharPointer++] = ','; } +} + +void Communicator::sendMessage(int *values, __SIZE_TYPE__ numberOfValues) +{ +} +void Communicator::sendMessage(char *message) +{ +} + +char *Communicator::receiveMessage() +{ + return ""; } \ No newline at end of file diff --git a/Devices/Control/Firmware/lib/Communicator/Communicator.h b/Devices/Control/Firmware/lib/Communicator/Communicator.h index 91d59a3..bc4ab19 100644 --- a/Devices/Control/Firmware/lib/Communicator/Communicator.h +++ b/Devices/Control/Firmware/lib/Communicator/Communicator.h @@ -6,11 +6,11 @@ private: public: Communicator(__SIZE_TYPE__ bufferSize); - virtual void sendMessage(int *values, int numberOfValues); + virtual void sendMessage(int *values, __SIZE_TYPE__ numberOfValues); virtual void sendMessage(char *message); virtual char *receiveMessage(); char *getBuffer(); int getBufferSize(); - void parseIDs(int *values, int numberOfValues, char *out); - int calculateMessageOutSize(int numberOfValues); + void parseIDs(int *values, __SIZE_TYPE__ numberOfValues, char *out); + __SIZE_TYPE__ calculateMessageOutSize(__SIZE_TYPE__ numberOfValues); }; \ No newline at end of file