From 6a0bc19279209438071f8636f59de65763657792 Mon Sep 17 00:00:00 2001 From: Robert Jordens Date: Mon, 23 Mar 2015 20:31:37 -0600 Subject: [PATCH] pdq2/driver: document a few units --- artiq/devices/pdq2/driver.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/artiq/devices/pdq2/driver.py b/artiq/devices/pdq2/driver.py index f3f1b609f..1dd218003 100644 --- a/artiq/devices/pdq2/driver.py +++ b/artiq/devices/pdq2/driver.py @@ -66,11 +66,22 @@ class Segment: return coef def bias(self, amplitude=[], **kwargs): + """Append a bias line to this segment. + + Amplitude in volts + """ coef = self.compensate([self.out_scale*a for a in amplitude]) data = self.pack([0, 1, 2, 2], coef) self.line(typ=0, data=data, **kwargs) def dds(self, amplitude=[], phase=[], **kwargs): + """Append a dds line to this segment. + + Amplitude in volts, + phase[0] in turns, + phase[1] in turns*sample_rate, + phase[2] in turns*(sample_rate/2**shift)**2 + """ scale = self.out_scale/self.cordic_gain coef = self.compensate([scale*a for a in amplitude]) if phase: