 	setSyncProvider(RTC.get);
 	setSyncInterval(2);
 	if(timeStatus()!= timeSet) 
+	{
 		Serial.println("Unable to sync with the RTC");
-	else
+	} else
+	{
 		Serial.println("RTC has set the system time"); 
+		fsmState = ERROR_MODE;
+	}
 	
 	pinMode(ALARM_PIN, INPUT_PULLUP);
 	setRtcAlarm(8,30);

				disableRtcAlarm();
				for (int i = 0; i < N; i++)
					display.disableDecimalPoint(i);
			} else 
			{
				enableRtcAlarm();
				for (int i = 0; i < N; i++)
					display.enableDecimalPoint(i);
			}
			break;


			break;

		case ERROR_MODE:
			if (oldFsmState != fsmState)
			{	
				display.writeMessage("ERRO");
				Serial.println("Error detected, disabling buttons.");
				Serial.println("Error detected, disabling RTC alarm.");
				disableRtcAlarm();
			}
			break;

		default:
			break;
	}
