trx_toolkit/rand_burst_gen.py: fix compatibility with Python 3
Change-Id: I362881af83664f94be09d40f43dfb23d18a35136
This commit is contained in:
parent
06e3b4fa54
commit
d206f0cc2f
|
@ -46,6 +46,7 @@ class RandBurstGen:
|
|||
# Pick a random TSC for a given burst type
|
||||
def get_rand_tsc(self, bt):
|
||||
tsc_list = filter(lambda seq: seq.bt == bt, list(TrainingSeqGMSK))
|
||||
tsc_list = list(tsc_list) # In Python 3 filter() returns an iterator
|
||||
return random.choice(tsc_list)
|
||||
|
||||
# Generate a normal burst
|
||||
|
|
Loading…
Reference in New Issue