 				// check if the job was more than 5 seconds
 				if (pulseCount > minCount) {
 					// calculate elapsed time in seconds
-					return (millis() - startTime)/1000;
+					return calculateTime(startTime);
 				}
 				pulseCount = 0;
 			}

			if (pollCounter == pollTimeout) {
				soundFeedback(isReject);
				Serial.print(messages.cancel);
				sendCount = (millis() - startTime)/1000;

				// Any valid accumulated time will be returned
				if (pulseCount > minCount) {

	if (elapsedTime > 0) {
		sendCommand(CMD_WRITE, blockID, machineID, keyA, elapsedTime + existingTime);
		delay(waitforWriteResponse);
		isValidResponse = getResponse(readData);
		if (!isValidResponse) {
			Serial.print(messages.errorRead);
		}
		else {
