hack to allow 6K correlation sigs

git-svn-id: http://op25.osmocom.org/svn/trunk@320 65a5c917-d112-43f1-993d-58c26a4786be
This commit is contained in:
max 2013-07-06 16:32:06 +00:00
parent 9b7e3709ac
commit fbffa862a8
2 changed files with 10 additions and 2 deletions

View File

@ -0,0 +1 @@
P25 TDMA S-ISCH (6K)

View File

@ -2008,8 +2008,15 @@ class correlation_plot_window (wx.Panel):
self.signatures = []
r = re.compile(r'^[13]+$')
path = "corr"
# another hack, add support for 6000 symbol rate in correlation sigs
sps_6k = int((self.info.sps * 4800) / 6000)
for fn in os.listdir(path):
if not r.match(fn):
sps = self.info.sps
fn_check = fn
if fn.endswith("-6k"):
sps = sps_6k
fn_check = fn_check.replace("-6k", "")
if not r.match(fn_check):
continue
f = open("%s/%s" % (path, fn))
line = f.readline()
@ -2024,7 +2031,7 @@ class correlation_plot_window (wx.Panel):
frame_sync.append(-1)
correlation = []
for symbol in frame_sync:
for i in xrange(self.info.sps):
for i in xrange(sps):
correlation.append(symbol)
correlation.reverse() # reverse order for convolve()
self.signatures.append(correlation)