////////////////////////////////////////////////////////////////////////////// /// /// Detect the second operand /// ////////////////////////////////////////////////////////////////////////////// bool controller::isOperand2Detected(unsigned char* ptr) { unsigned char length = getLFPosition(ptr) - getOperationPosition(ptr) - 1; unsigned char* trimPtr = trimSpaces(ptr + getOperationPosition(ptr) + 1, &length); return isNumber(trimPtr, length); }
////////////////////////////////////////////////////////////////////////////// /// /// Detect a line feed /// ////////////////////////////////////////////////////////////////////////////// bool controller::isLFDetected(unsigned char* ptr) { return getLFPosition(ptr) != -1; }