Commit Graph

451 Commits

Author SHA1 Message Date
Manolis Surligas 96aaf11a30 Improve doppler correction and decimation
This commit adds a hierarchical block that performs Doppler
compensation and resampling.

Rather than using directly the available Doppler correction blocks,
based on the user parameters of the incoming sampling rate and the
desired target sampling rate, it applies proper decimation on the signal
so the frequency shift to be applied to a smaller sampling rate,
reducing significantly the CPU resources required. At the previous
architecture (gr-satnogs 1.x.x) we used seperate blocks for the doppler
correction and the LO digital shift, operating at the device sampling rate.
These two blocks, performing almost the same operation, contributed to a
30% CPU usage of the overall application. Now the LO is compensated by
the Doppler correction block, taking into account at the same time the
Doppler drift.

After the digital LO shift, the Doppler corrected signal is passed through
an Polyphase Arbitrary Resampler, to match exactly the sampling rate
requested by the user.
2019-12-20 13:00:58 +02:00
Vasilis Tsiligiannis fe3bd06dc1 debian: Fix package building for 'buster'
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 12:24:55 +02:00
Vasilis Tsiligiannis 44f98b11f0 debian: Clean-up compiled Python scripts for any Python 3 version
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:29:57 +02:00
Vasilis Tsiligiannis 181aa6568a debian: Remove Python overrides; only Python 3 is supported
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:28:57 +02:00
Vasilis Tsiligiannis f2a412fcb0 debian: Fix dependency to Python 3
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:23:50 +02:00
Vasilis Tsiligiannis 4f03e74cb2 debian: Require gnuradio version 3.8 or above to build package
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:15:39 +02:00
Vasilis Tsiligiannis d044728964 debian: Bump standards version
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:13:07 +02:00
Vasilis Tsiligiannis f407acf90c debian: Sort build dependencies
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:10:26 +02:00
Vasilis Tsiligiannis 04dd7618f4 debian: Remove extraneous space from build dependencies list
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-12-20 10:09:14 +02:00
Manolis Surligas 8072219a8a Support timestamping in the waterfall intermediate file
The waterfall file has now a constant sized header of 52 bytes,
so that plotting tools can reconstruct properly the spectrum.

The structure of the header is the following:
  - A 32 byte string containing the timestamp in
    ISO-8601 format. This timer has microsecond accuracy.
  - A 4 byte integer containing the sampling rate
  - A 4 byte integer with the FFT size
  - A 4 byte integer containing the number of FFT snapshots for one row
    at the waterfall
  - A 4 byte float with the center frequency of the observation.
  - A 4 byte integer indicating the endianness of the rest of the file. If
    set to 0 the file continues in Big endian. Otherwise, in little endian.
    The change of the endianness is performed to reduce the overhead at the
    station.

 Note that all contents of the header are in Network Byte order! The rest
 of the file is in native byte order, mainly for performance reasons.
 Users can use data of the header to determine if their architecture match
 the architecture of the host generated the waterfall file and act
 accordingly.

 The file continues with information regarding the spectral content of the
 observation.
 Each waterfall line is prepended with a int64_t field indicating the
 absolute time in microseconds with respect to the start of the waterfall
 data (stored in the corresponding header field).
 The spectral content is stored in $FFT$ float values already converted in
 dB scale.
2019-12-17 15:59:43 +02:00
Manolis Surligas 48e421e3f5 Fix wrong parameter at the OGG Encoder 2019-12-17 01:47:33 +02:00
nickoe c3bc8fcc43 Add missing grc input for Doppler Correction (Coarse)
Fixes #157
2019-12-16 23:44:51 +00:00
Manolis Surligas 29081b6207 Update build requirements on the README 2019-12-12 18:17:50 +02:00
takurx 31a6223334 Update README.md that add 'sudo' in Install, Requirement, Debian/Ubuntu Field 2019-12-12 17:55:10 +02:00
Manolis Surligas 3339977b81 Update FindJsonCpp.cmake to solve packaging issue 2019-12-12 01:46:37 +02:00
Manolis Surligas 6f13d72769 Update .gitlab-ci.yml with the new dependencies 2019-12-12 01:46:37 +02:00
Manolis Surligas cbc733c25e Integrate libfec as part of the gr-satnogs 2019-12-12 01:46:37 +02:00
Manolis Surligas 2a03fc66bf Drop boost::chrono in favor of std::chrono
The new GNU Radio linkage system seems that has some
issues. There are linkage dependencies that they should
be private on the GNU Radio target.

In addition, find_package(Boost) is also called on the
gnuradio-runtime target. Calling it again in the OOT
module overwrites the existing list of dependencies,
causing many problems.

We are staring a process of dropping Boost and use
the C++11 variants.
2019-12-11 18:15:49 +02:00
Manolis Surligas 303b26db62 Remove obsolete cmake macros 2019-12-09 19:19:28 +02:00
Manolis Surligas 073df24112 Convert all blocks from XML to YAML 2019-12-04 19:42:01 +02:00
Manolis Surligas cd5dfc69c9 Updated library and Swig files to GNU Radio 3.8 2019-12-02 21:53:26 +02:00
Manolis Surligas 747195f054 Make the non-scrambled AX.25 decoder more conservative
In case of scrambling the self synchronizing scrambler ensures
that enough repetitions of the AX.25 flag have been received.
However, this does not hold for the case of non scrambled
transmissions. In this case, we wait for at least two consecutive
AX.25 flags to reduce the false alarms. Experiments have shown
that due to the poor CRC there were many false positive frames.

It is expected however, to miss some transmissions that use only one
AX.25 flag.
2019-10-03 16:54:37 +03:00
Manolis Surligas 040763af11 Fix issue with the PMT messages and their format 2019-09-30 20:17:08 +03:00
Manolis Surligas 860395a997 Remove obsolete flowgraphs
Update the obsolete flowgraphs and update the existing with
the new decoding architecture blocks. Client should
not have big problems with the new decoders as we utilizing
the multiformat frame sink that takes care of it. This
is just a work around for testing as we move forward for
fully socket-based communication with the client
2019-09-30 19:32:21 +03:00
Manolis Surligas 2cc9184fbc Support both legacy and new PMT messages at the file sink
To allow easier integration to the new architecture the
multi format file sink supports bot legacy and the new
format of the PMT messages. In poth cases, only the PDU
is extracted. Legacy used the PDU as a BLOB, whereas
now the PDU is stored in base64 format inside a
dictionary, which structure is defined through
the gr::satnogs::metadata() class
2019-09-30 19:32:21 +03:00
Manolis Surligas 7a95b44475 Fix FSM at the IEEE 802.15.4 decoder 2019-09-30 19:32:21 +03:00
Manolis Surligas 2019718b3f Support frame tagging on the IEEE 802.15.4 decoder 2019-09-30 19:32:21 +03:00
Manolis Surligas ab442833c2 Instruct Astyle to wrap code at 80 chars 2019-09-30 19:32:21 +03:00
Manolis Surligas 729d97c73c Add support for AX.25 frame tagging on the IQ stream 2019-09-30 19:32:21 +03:00
Manolis Surligas ab45da4ad3 Implement a decoder covering COMMS from GOMSpace 2019-09-30 19:32:21 +03:00
Manolis Surligas c40b83211f Add a IEEE 802.15.4 compatible decoder
Add a IEEE 802.15.4 like decoder, which supports
the IEEE 802.15.4 standard but also a large variety
of ICs based on this framing scheme. Such framings
are quite common in many Cubesat missions.

The decoder has been tested an works well with at least
the Reaktor Hello World satellite
2019-09-30 19:32:21 +03:00
Manolis Surligas 142c995370 Add astyle pre-commit hook and update readme with coding style info 2019-09-30 19:32:21 +03:00
Manolis Surligas 90eb400763 Fix Debian issue with astyle options 2019-09-30 19:32:21 +03:00
Manolis Surligas e09c180f84 Format all C++ files using the astyle beautifier 2019-09-30 19:32:21 +03:00
Manolis Surligas a5caed2ca9 Add astyle configuration for code formating 2019-09-30 19:32:21 +03:00
Manolis Surligas 7b7fb82adc Continue with the transition to the new decoder API
* Removed obsolete blocks
* Created a new CRC class with static methods. This will make easier the
integration of new CRC schemes. The old way was rather too C-styled
2019-09-30 19:32:21 +03:00
Manolis Surligas 17f91dbb27 Add developers information on README 2019-09-30 19:32:21 +03:00
Manolis Surligas 14382ddc4f Remove obsolete blocks
* Blocks removed are now covered from decoders available supporting the
new decoder architecture
* The quadrature demodulation filter block, had as primary goal to
reduce the false alarms and the performance of the DUV decoder. Now the
new DUV decoder, uses a shift register approach, likewise the AX.25
decoder, therefore it is not needed anymore.
2019-09-30 19:32:21 +03:00
Manolis Surligas c9f685d1c1 Use the shift register approach for the DUV decoder 2019-09-30 19:32:21 +03:00
Manolis Surligas c5f376929c Convert AMSAT FOX DUV decoder to the new architecture
TODO:
* Use the shift register likewise the AX.25 to get rid off the
quadrature demodulation filter. This will significantly increase the
number of decoded frames
2019-09-30 19:32:21 +03:00
Manolis Surligas 110ab30d26 Add JSON converter block for the decoders
The decoders produce a PMT message containing several information about
the decoded frame. While this is very convenient for handling data
inside the flowgraph, it is not for third party applications. The JSON
converter block is responsible to serialize all the information
contained in a PMT originating from a decoded frame.

For simple demonstration some metadata were added on the AX.25 decoder.
These metadata are still a WIP and they subjected to changes.
2019-09-30 19:32:21 +03:00
Manolis Surligas 19c68f825d Port AX.25 decoder to the new architecture 2019-09-30 19:32:21 +03:00
Manolis Surligas ad590174e0 Implement the generic decoder API
To simplify the logic and allow an easy and more efficient way to add
new decoders, the new architecture uses only one decoder block.

This block takes as input a void* stream and produces PDUs with their
metadata. To do so, the block accepts a decoder object. Every decoder
should implement the virtual class decoder(). This class provides the
necessary API and an arbitrary number of decoders can be supported. The
decoding status is reported to the frame_decoder block through the
decoder_status_t structure.
2019-09-30 19:32:21 +03:00
Manolis Surligas 9fe6b6f274 Improvements on the overall structure of the project
* Improve performance of the Golay decoder
* Modernize some CMake modules of GNU Radio
* Re-introduce the CPPUnit automated tests
2019-09-30 19:32:21 +03:00
Vasilis Tsiligiannis 8625475fd9 gitlab-ci: Keep image version in variable
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-09-30 18:47:46 +03:00
Vasilis Tsiligiannis 558b59123f debian: Do not include volatile lines in patch
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-09-30 18:47:46 +03:00
Vasilis Tsiligiannis 2edceafaa5 Workaround GitLab CI bug when using 'git describe'
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-09-30 18:47:46 +03:00
Vasilis Tsiligiannis 35c50bce83 debian: Pass Git count and hash to CMake
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-09-30 18:47:46 +03:00
Vasilis Tsiligiannis 3780102025 gitlab-ci: Fix typo in variable use
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-09-30 18:47:46 +03:00
Vasilis Tsiligiannis 704d9a5e6d Deploy only 'master' and tagged releases
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
2019-09-30 18:47:46 +03:00