Added new decryption block (be careful - untested component). Changed CMakeFiles to reflect more modular design (not finished for the lib directory)
diff --git a/include/plotting/CMakeLists.txt b/include/CMakeLists.txt
similarity index 76%
copy from include/plotting/CMakeLists.txt
copy to include/CMakeLists.txt
index 569c462..a7c18dd 100644
--- a/include/plotting/CMakeLists.txt
+++ b/include/CMakeLists.txt
@@ -17,9 +17,4 @@
# the Free Software Foundation, Inc., 51 Franklin Street,
# Boston, MA 02110-1301, USA.
-########################################################################
-# Install public header files
-########################################################################
-install(FILES
- plotting.hpp DESTINATION include/plotting
-)
+add_subdirectory(grgsm)
diff --git a/include/grgsm/CMakeLists.txt b/include/grgsm/CMakeLists.txt
index 292431f..6df01d7 100644
--- a/include/grgsm/CMakeLists.txt
+++ b/include/grgsm/CMakeLists.txt
@@ -20,12 +20,14 @@
########################################################################
# Install public header files
########################################################################
-add_subdirectory(misc_utils)
add_subdirectory(decoding)
+add_subdirectory(decryption)
add_subdirectory(demapping)
add_subdirectory(receiver)
+add_subdirectory(misc_utils)
install(FILES
+ plotting.hpp
api.h
gsmtap.h DESTINATION include/grgsm
)
diff --git a/include/plotting/CMakeLists.txt b/include/grgsm/decryption/CMakeLists.txt
similarity index 94%
rename from include/plotting/CMakeLists.txt
rename to include/grgsm/decryption/CMakeLists.txt
index 569c462..3a0c6b6 100644
--- a/include/plotting/CMakeLists.txt
+++ b/include/grgsm/decryption/CMakeLists.txt
@@ -21,5 +21,5 @@
# Install public header files
########################################################################
install(FILES
- plotting.hpp DESTINATION include/plotting
+ decryption.h DESTINATION include/grgsm/decoding
)
diff --git a/include/grgsm/decryption/decryption.h b/include/grgsm/decryption/decryption.h
new file mode 100644
index 0000000..96d3eca
--- /dev/null
+++ b/include/grgsm/decryption/decryption.h
@@ -0,0 +1,60 @@
+/* -*- c++ -*- */
+/*
+ * @file
+ * @author Piotr Krysik <ptrkrysik@gmail.com>
+ * @section LICENSE
+ *
+ * Gr-gsm 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 3, or (at your option)
+ * any later version.
+ *
+ * Gr-gsm 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 gr-gsm; see the file COPYING. If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street,
+ * Boston, MA 02110-1301, USA.
+ *
+ */
+
+
+#ifndef INCLUDED_GSM_DECRYPTION_H
+#define INCLUDED_GSM_DECRYPTION_H
+
+#include <grgsm/api.h>
+#include <gnuradio/block.h>
+
+namespace gr {
+ namespace gsm {
+
+ /*!
+ * \brief <+description of block+>
+ * \ingroup gsm
+ *
+ */
+ class GSM_API decryption : virtual public gr::block
+ {
+ public:
+ typedef boost::shared_ptr<decryption> sptr;
+
+ /*!
+ * \brief Return a shared_ptr to a new instance of gsm::decryption.
+ *
+ * To avoid accidental use of raw pointers, gsm::decryption's
+ * constructor is in a private implementation
+ * class. gsm::decryption::make is the public interface for
+ * creating new instances.
+ */
+ static sptr make(const std::vector<uint8_t> & k_c);
+ virtual void set_k_c(const std::vector<uint8_t> & k_c) = 0;
+ };
+
+ } // namespace gsm
+} // namespace gr
+
+#endif /* INCLUDED_GSM_DECRYPTION_H */
+
diff --git a/include/plotting/plotting.hpp b/include/grgsm/plotting.hpp
similarity index 100%
rename from include/plotting/plotting.hpp
rename to include/grgsm/plotting.hpp