def __init__(self, main): self.main = main IrisUtil.Assert_ZeroSerialNotAllowed(self) IrisUtil.Format_UserInputSerialAnts(self) IrisUtil.Assert_Tx_Required(self) # require at least one tx # init sdr object IrisUtil.Init_CollectSDRInstantNeeded(self, clockRate=80e6) # create gains and set them IrisUtil.Init_CreateDefaultGain_WithDevFE(self) self.rate = 10e6 # save this for later build tx tone IrisUtil.Init_CreateBasicGainSettings(self, rate=self.rate, bw=30e6, freq=2.35e9, dcoffset=True) # create streams (but not activate them) IrisUtil.Init_CreateRxStreams_RevB(self) # sync trigger and clock IrisUtil.Init_SynchronizeTriggerClock(self) self.txFrameSize = 1024 # immutable self.numSamples = 1024 # could be changed during runtime self.showSamples = 8192 # init max show samples self.selfparameters = {"numSamples": int, "showSamples": int} # this will automatically added to UI # add postcode support IrisUtil.Gains_AddPostcodeGains(self) IrisUtil.Gains_LoadGainKeyException(self, rxGainKeyException=IrisUtil.Gains_GainKeyException_RxPostcode) # repeat sequence generate IrisUtil.Init_CreateRepeatorSinusoidSequence(self) # set repeat IrisUtil.Process_TxActivate_WriteFlagAndDataToTxStream_RepeatFlag(self)
def __init__(self, main): self.main = main IrisUtil.Assert_ZeroSerialNotAllowed(self) IrisUtil.Format_UserInputSerialAnts(self) IrisUtil.Assert_Tx_Required(self) # require at least one tx # import waveform file IrisUtil.Format_LoadWaveFormFile( self, 'LTE_OneRepeator_SyncWatcher_DevFE_RevB_180902_Waveform.csv') # init sdr object IrisUtil.Init_CollectSDRInstantNeeded(self, clockRate=80e6) # create gains and set them IrisUtil.Init_CreateDefaultGain_WithDevFE(self) IrisUtil.Init_CreateBasicGainSettings(self, bw=5e6, freq=2.35e9, dcoffset=True, txrate=1.5e6, rxrate=9e6) # create streams (but not activate them) IrisUtil.Init_CreateRxStreams_RevB(self) # sync trigger and clock IrisUtil.Init_SynchronizeTriggerClock(self) self.numSamples = 1024 # could be changed during runtime self.showSamples = 8192 # init max show samples serial, ant = IrisUtil.Format_SplitSerialAnt(self.tx_serials_ant[0]) if ant == 2: self.txSelect = "%s-0" % serial # select one to send, other set 0 else: self.txSelect = "%s-%d" % (serial, ant) self.alignOffset = 0 self.selfparameters = { "numSamples": int, "showSamples": int, "txSelect": lambda x: IrisUtil.Format_CheckSerialAntInTx( self, x), # use closure to send "self" object in "alignOffset": int } # this will automatically added to UI # add postcode support IrisUtil.Gains_AddPostcodeGains(self) IrisUtil.Gains_LoadGainKeyException( self, rxGainKeyException=IrisUtil.Gains_GainKeyException_RxPostcode) # repeat sequence generate IrisUtil.Init_CreateRepeatorOnehotWaveformSequence(self) # set repeat IrisUtil.Process_TxActivate_WriteFlagAndDataToTxStream_RepeatFlag(self)