diff --git a/FofbTool/Operation.py b/FofbTool/Operation.py
index 510600c6d1c8221264f0ccc901bd939e05bb8e57..922588a023aaf93fce8fdd883b1e92b46334c034 100644
--- a/FofbTool/Operation.py
+++ b/FofbTool/Operation.py
@@ -44,19 +44,19 @@ def align_ccn(nodename):
     # Loop until two consecutives identical measures
     N=[7,3]
     while N[-2] != N[-1]:
+        if len(N) > 7:
+            logger.error("Could not measure sequence offset.")
+            return False
+
         logger.debug("Latch two sequence numbers without offset")
         prx.ccnpack0_control=1 # let it roll a bit to collect data
-        time.sleep(2)
+        time.sleep(2+np.random.uniform())
         prx.ccnpack0_control=2 # latch it
         time.sleep(2)
         N.append(prx.ccnpack0_latchedseq1-prx.ccnpack0_latchedseq2)
 
         logger.debug("seq ({}, {}, {})".format(prx.ccnpack0_latchedseq1, prx.ccnpack0_latchedseq2, N[-1]))
 
-        if len(N) > 5:
-            logger.error("Could not measure sequence offset.")
-            return False
-
 
     N=N[-1]
 
@@ -508,7 +508,7 @@ def sync_all_bpm():
     This will use the timing system (central and local board).
 
     """
-    EVN=66 # Event number
+    EVN=240 # Event number
 
     # Get FofbManager proxy, only for its properties
     p = tango.DeviceProxy(FofbTool.Configuration.config["tangopath"]["fofb-manager"])