import numpy as np import os import SoapySDR from SoapySDR import * from util import simulation # soapysdr is not on pip, it is a python binding to a c++ library soapy1 = SoapySDR.Device_enumerate()[-1] #class Simulated: # def __init__(self, name='receiver'): # self.name = name # self.sim = simulation(name) # self.tuner = Simulated.Tuner(self, name + '_tuner') # def enable(self): # def disable(self): # self.sim = None # def read(self): # return self.sim.read() # class Tuner: # def __init__(self, fn): # self.sim = simulation(name) # self.last = self.sim.read() class Receiver: def __init__(self, soapy_device_data=soapy1,
def devs(): return list(map(dict, sdr.Device_enumerate()))