summaryrefslogtreecommitdiff
path: root/gr-pager/src/pageri_flex_modes.cc
diff options
context:
space:
mode:
authorjcorgan2006-10-31 19:15:02 +0000
committerjcorgan2006-10-31 19:15:02 +0000
commit50a6df5e198231188f40c23e609a3fe078ad436a (patch)
treecfadbb794cd86350adff9461fc2fa9735cb7c640 /gr-pager/src/pageri_flex_modes.cc
parent2c1032480d2874f38af9b5b9d18e753e968619e5 (diff)
downloadgnuradio-50a6df5e198231188f40c23e609a3fe078ad436a.tar.gz
gnuradio-50a6df5e198231188f40c23e609a3fe078ad436a.tar.bz2
gnuradio-50a6df5e198231188f40c23e609a3fe078ad436a.zip
Restore gr-pager to trunk.
git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@3909 221aa14e-8319-0410-a670-987f0aec2ac5
Diffstat (limited to 'gr-pager/src/pageri_flex_modes.cc')
-rw-r--r--gr-pager/src/pageri_flex_modes.cc45
1 files changed, 45 insertions, 0 deletions
diff --git a/gr-pager/src/pageri_flex_modes.cc b/gr-pager/src/pageri_flex_modes.cc
new file mode 100644
index 000000000..b2bb4e29c
--- /dev/null
+++ b/gr-pager/src/pageri_flex_modes.cc
@@ -0,0 +1,45 @@
+/*
+ * Copyright 2006 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * GNU Radio is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2, or (at your option)
+ * any later version.
+ *
+ * GNU Radio is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with GNU Radio; see the file COPYING. If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#include "pageri_flex_modes.h"
+
+const flex_mode_t flex_modes[] =
+{
+ { 0x870C78F3, 1600, 2 },
+ { 0xB0684F97, 1600, 4 },
+// { 0xUNKNOWN, 3200, 2 },
+ { 0xDEA0215F, 3200, 4 },
+ { 0x4C7CB383, 3200, 4 }
+};
+
+const int num_flex_modes = sizeof(flex_modes)/sizeof(flex_modes[0]);
+
+unsigned char flex_bcd[17] = "0123456789 U -][";
+
+int find_flex_mode(gr_int32 sync_code)
+{
+ for (int i = 0; i < num_flex_modes; i++)
+ if (flex_modes[i].sync == sync_code)
+ return i;
+
+ // Not found
+ return -1;
+}