From 90368415a6f24b458fc0cbf54acf255d259388f3 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Wed, 29 Jul 2015 11:11:16 +0800 Subject: [PATCH] ttl: remove timestamp function The general idea is that functions that work with absolute timestamps exist only in machine units versions, to help prevent floating point losses of precision. Time differences should be computed in machine units and then converted, e.g. mu_to_seconds(t2-t1). This function would have had problems after ~50 days of running the device. --- artiq/coredevice/ttl.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/artiq/coredevice/ttl.py b/artiq/coredevice/ttl.py index b2399786a..866e884e5 100644 --- a/artiq/coredevice/ttl.py +++ b/artiq/coredevice/ttl.py @@ -203,16 +203,6 @@ class TTLInOut: """ return syscall("ttl_get", self.channel, self.i_previous_timestamp) - @kernel - def timestamp(self): - """Poll the RTIO input and returns an event timestamp (in seconds), - according to the gating. - - If the gate is permanently closed, returns a negative value. - """ - return mu_to_seconds( - syscall("ttl_get", self.channel, self.i_previous_timestamp)) - class TTLClockGen: """RTIO TTL clock generator driver.