summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVadim Yanitskiy <axilirator@gmail.com>2018-01-27 23:14:01 +0700
committerVadim Yanitskiy <axilirator@gmail.com>2018-01-29 04:19:01 +0700
commit041bfc0b0313c2b89d3ff0488d3d5f54d22fa197 (patch)
treeaf65da310d7b6b3c2529e890f272ed5ce0e9395d
parent630cc5a3670ab6957c01c4bd6c8cc739c7aebc48 (diff)
fake_trx/burst_send.py: handle both GSM and EDGE bursts
Previously, it was expected that burst length should be equal to 148. Let's also handle EDGE bursts and use GSM constants. Change-Id: Iab13dd06f175556137c5e25d2cbddb9bea403b09
-rwxr-xr-xsrc/target/fake_trx/burst_send.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/target/fake_trx/burst_send.py b/src/target/fake_trx/burst_send.py
index 73679256..b51ce5d4 100755
--- a/src/target/fake_trx/burst_send.py
+++ b/src/target/fake_trx/burst_send.py
@@ -96,8 +96,8 @@ class Application:
burst = []
# Check length
- if len(burst_str) != 148:
- print("[!] Dropping burst due to length != 148")
+ if len(burst_str) not in (GSM_BURST_LEN, EDGE_BURST_LEN):
+ print("[!] Dropping burst due to incorrect length")
continue
# Randomize the message header