Skip to content

Commit 9036841

Browse files
committedJul 29, 2015
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.
1 parent 2640a57 commit 9036841

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed
 

Diff for: ‎artiq/coredevice/ttl.py

-10
Original file line numberDiff line numberDiff line change
@@ -203,16 +203,6 @@ def timestamp_mu(self):
203203
"""
204204
return syscall("ttl_get", self.channel, self.i_previous_timestamp)
205205

206-
@kernel
207-
def timestamp(self):
208-
"""Poll the RTIO input and returns an event timestamp (in seconds),
209-
according to the gating.
210-
211-
If the gate is permanently closed, returns a negative value.
212-
"""
213-
return mu_to_seconds(
214-
syscall("ttl_get", self.channel, self.i_previous_timestamp))
215-
216206

217207
class TTLClockGen:
218208
"""RTIO TTL clock generator driver.

0 commit comments

Comments
 (0)
Please sign in to comment.