diff options
author | Tom Rondeau <tom@trondeau.com> | 2016-06-14 10:48:00 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2016-06-14 10:58:05 -0700 |
commit | 817f61bbdd180a2854116c85ccf1020e561c523f (patch) | |
tree | 883649968739a66c537e932c65c79e9387544a07 /gr-digital/lib/CMakeLists.txt | |
parent | c475f14e4604b9bca25c08f1d30a2e8ff9bbcf26 (diff) |
digital: Complete overhaul of protocol handling
See documentation for details. In brief:
- digital_protocol_* classes added (replace packet header blocks)
- header_buffer class added
- Lots of QA
- default packet formatter: contains access code and payload length
fields.
- counter packet formatter: also contains the bits/sym in the payload
modulation and a packet number counter.
- Also adds QA code and the infrastructure for C++ QA code in
gr-digital.
- New block to use the packet formatter objects.
- The header and payload are transmitted as PDU messages out of different ports.
- header_buffer class for header formatting.
- Used by packet_formatter_x classes to more easily add and format
header data for transmission.
- New blocks that parse headers.
- Handles either hard or soft bits. Produces an info message to
instruct payload demod.
- 'receive mode' to header_buffer class.
- Designed to make extracting fields from the received header bits
easier for packet formatter classes. Use extract_field[N] to get
the different fields out of a collected set of header bits. *
Docs describing both functions with small examples for how to use
them.
- Don't force access code to be a multiple of 8
- need to verify everything else handles this correctly.
- Throw an exception in the ctor if setting the code failed and emit a
log message.
Committed-By: Martin Braun <martin.braun@ettus.com>
Diffstat (limited to 'gr-digital/lib/CMakeLists.txt')
-rw-r--r-- | gr-digital/lib/CMakeLists.txt | 46 |
1 files changed, 45 insertions, 1 deletions
diff --git a/gr-digital/lib/CMakeLists.txt b/gr-digital/lib/CMakeLists.txt index daa577f56f..84f53ec4f3 100644 --- a/gr-digital/lib/CMakeLists.txt +++ b/gr-digital/lib/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright 2011-2014 Free Software Foundation, Inc. +# Copyright 2011-2016 Free Software Foundation, Inc. # # This file is part of GNU Radio # @@ -83,6 +83,7 @@ list(APPEND digital_sources glfsr_source_f_impl.cc hdlc_deframer_bp_impl.cc hdlc_framer_pb_impl.cc + header_buffer.cc header_payload_demux_impl.cc kurtotic_equalizer_cc_impl.cc lms_dd_equalizer_cc_impl.cc @@ -106,6 +107,14 @@ list(APPEND digital_sources ofdm_sampler_impl.cc ofdm_serializer_vcc_impl.cc ofdm_sync_sc_cfb_impl.cc + header_format_base.cc + header_format_default.cc + header_format_counter.cc + header_format_crc.cc + header_format_ofdm.cc + protocol_formatter_async_impl.cc + protocol_formatter_bb_impl.cc + protocol_parser_b_impl.cc packet_header_default.cc packet_header_ofdm.cc packet_headergenerator_bb_impl.cc @@ -189,3 +198,38 @@ if(ENABLE_STATIC_LIBS) ARCHIVE DESTINATION lib${LIB_SUFFIX} COMPONENT "digital_devel" # .lib file ) endif(ENABLE_STATIC_LIBS) + + +######################################################################## +# QA C++ Code for gr-blocks +######################################################################## +if(ENABLE_TESTING) + include(GrTest) + + include_directories( + ${GR_DIGITAL_INCLUDE_DIRS} + ${CPPUNIT_INCLUDE_DIRS}) + link_directories(${CPPUNIT_LIBRARY_DIRS}) + + list(APPEND test_gr_digital_sources + ${CMAKE_CURRENT_SOURCE_DIR}/test_gr_digital.cc + ${CMAKE_CURRENT_SOURCE_DIR}/qa_digital.cc + ${CMAKE_CURRENT_SOURCE_DIR}/qa_header_format.cc + ${CMAKE_CURRENT_SOURCE_DIR}/qa_header_buffer.cc + ) + + add_executable(test-gr-digital ${test_gr_digital_sources}) + + list(APPEND GR_TEST_TARGET_DEPS test-gr-digital gnuradio-digital) + + target_link_libraries( + test-gr-digital + gnuradio-runtime + gnuradio-digital + ${Boost_LIBRARIES} + ${CPPUNIT_LIBRARIES} + ${LOG4CPP_LIBRARIES} + ) + + GR_ADD_TEST(test_gr_digital test-gr-digital) +endif(ENABLE_TESTING) |