Exemple #1
0
 def set_freq(self, freq):
     print("\tSetting frequency")
     parameters.set_freq(freq)
     gsocket.write(struct.pack('<I', 1 << 28 | int(1.0e6 * freq)))
     # 2^28 = 268,435,456 for frequency setting
     if not self.idle:
         print("Acquiring data")
Exemple #2
0
 def set_freq(self, freq):
     # Setting frequency without triggering aquisition: parameters.set_freq
     print("Setting frequency.")
     parameters.set_freq(freq)
     gsocket.write(struct.pack('<I', 1 << 28 | int(1.0e6 * freq)))
     # 2^28 = 268,435,456 for frequency setting
     if not self.idle:
         print("\tAcquiring data.")