summaryrefslogtreecommitdiff
path: root/src/lib/decoder
diff options
context:
space:
mode:
authorpiotr <piotr@piotr-desktop.(none)>2009-06-04 13:12:03 +0200
committerpiotr <piotr@piotr-desktop.(none)>2009-06-04 13:12:03 +0200
commit6497de667a5d1f6f1770066ea64bc624407957ff (patch)
tree7e60dd0255baa017893f33bbe4c95707e73bfbe9 /src/lib/decoder
parent83ca8d75e21d286096c749b7608f847220260b77 (diff)
normal bursts detection now works, but the code is a little dirty
Diffstat (limited to 'src/lib/decoder')
-rw-r--r--src/lib/decoder/sch.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/decoder/sch.c b/src/lib/decoder/sch.c
index 9f570c9..e16d14b 100644
--- a/src/lib/decoder/sch.c
+++ b/src/lib/decoder/sch.c
@@ -3,7 +3,7 @@
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
-#include "burst_types.h"
+#include <gsm_constants.h>
/*
* Synchronization channel.
@@ -251,8 +251,8 @@ int decode_sch(const unsigned char *buf, int * t1_o, int * t2_o, int * t3_o, int
// extract encoded data from synchronization burst
/* buf, 39 bit */
/* buf + 39 + 64 = 103, 39 */
- memcpy(data, buf, SB_EDATA_LEN_1);
- memcpy(data + SB_EDATA_LEN_1, buf + SB_EDATA_LEN_1 + N_SYNC_BITS, SB_EDATA_LEN_2);
+ memcpy(data, buf, SCH_DATA_LEN);
+ memcpy(data + SCH_DATA_LEN, buf + SCH_DATA_LEN + N_SYNC_BITS, SCH_DATA_LEN);
// Viterbi decode
if (errors = conv_decode(data, decoded_data)) {
personal git repositories of Harald Welte. Your mileage may vary