Silvano Seva
54aa794bf8
Changed file extension of all C++ only header files from .h to .hpp
2022-07-09 18:22:36 +02:00
Silvano Seva
34c90c2485
Moved FIR filter class to a dedicated header file
2022-07-09 18:07:42 +02:00
Silvano Seva
5f40ceceb3
Added field to state data structure containing the current operating state of the device. Implemented clean shutdown of all the threads.
2022-07-02 10:47:19 +02:00
Silvano Seva
810daf7599
Reorganised system initialisation sequence, improved reactivity of UI and device threads
2022-07-02 10:47:19 +02:00
Silvano Seva
3a288769ba
Added the 'sleepUntil' API function to delays interface, allowing to put a thread in sleeping state until a certain absolute timepoint is reached
2022-07-02 10:47:19 +02:00
Silvano Seva
23a1a38a3a
Moved mutex for concurrent access to radio state inside state.h/.c, minimized the time spent with state mutex locked when updating the GPS data fields
2022-07-02 10:47:19 +02:00
Silvano Seva
101b33ce6b
Merged keyboard and UI threads, merged GPS and device threads.
2022-07-02 10:47:18 +02:00
Silvano Seva
4528e102a2
Moved the UI event queue inside the UI engine itself, UI FSM update now becomes a periodic task
2022-07-02 10:28:28 +02:00
Silvano Seva
2fc89bf583
Renamed 'HAS_GPS' and 'HAS_RTC' to, respectively, 'GPS_PRESENT' and 'RTC_PRESENT'
2022-07-02 10:28:28 +02:00
Silvano Seva
6d10f52b5b
Clean termination of all the threads on device shutdown
2022-07-02 10:28:28 +02:00
Silvano Seva
52ead401bd
Reorganised GPS task to make it a non-blocking task to be called periodically
2022-07-02 10:28:28 +02:00
Silvano Seva
d16eb04696
Reorganised data structures and functions to manage date and time
2022-07-02 10:28:28 +02:00
Silvano Seva
45d919f50f
Reorganised GPS driver to allow for non-blocking acquisition of NMEA sentences
2022-07-02 10:28:28 +02:00
Silvano Seva
3cc5852ef3
Refactored keyboard thread by moving the keypad scan logic to a dedicated function inside input.h
2022-07-02 10:28:28 +02:00
Silvano Seva
d2e0b7d940
Improved heap memory management in M17 modulator class
2022-06-05 12:27:25 +02:00
Silvano Seva
a1888ae19e
Improved heap memory management in M17 demodulator class
2022-06-05 12:24:43 +02:00
Silvano Seva
8b5b6ed571
Moved OpenRTX startup code from main.c to dedicated openrtx_init() and openrtx_run() functions in a separate source file.
2022-06-02 10:01:34 +02:00
Silvano Seva
316e588bc3
Updated copyright headers
2022-06-02 09:56:05 +02:00
Niccolò Izzo
ae12a2126a
Implement codeplug read and write functions
...
Implemented remaining codeplug functions to read, write and insert
codeplug entries. Fix bugs in ui code. Add unit tests.
TG-428
2022-06-01 16:05:35 +02:00
Niccolò Izzo
dc250a25d6
Implement new codeplug interface
...
The new codeplug interface was implemented for linux and retrofitted to
all the existing OpenRTX platforms. Limited unit testing was also
implemented.
TG-428
2022-06-01 15:59:27 +02:00
Silvano Seva
cbd3922325
Cleanup and reorganisation of state header file, new OpenRTX CPS data structure
2022-06-01 15:04:17 +02:00
Silvano Seva
da22d6ff64
Separated interface for CPS loading from the non volatile memory one
2022-06-01 14:56:33 +02:00
Silvano Seva
c3cfaba4b2
Renamed zones into banks to align to M17 codeplug naming convention.
2022-06-01 14:56:22 +02:00
Silvano Seva
4d4ebae2f3
Added configurable phase inversion to M17 demodulator. Forced enabling of phase inversion for MD3x0 VHF radios.
2022-05-30 19:19:01 +02:00
Silvano Seva
bfa3494777
Fixed bug in M17 demodulator causing the M17Demodulator::getFrame() function to return the frame currently being processed instead of the fully demodulated one.
2022-05-27 21:49:33 +02:00
Silvano Seva
63f4c787c0
Moved helper functions for M17 Golay to a dedicated source file
2022-05-27 21:49:33 +02:00
Silvano Seva
1620889640
Reorganised main FSM inside M17 operating mode handler
2022-05-27 21:49:33 +02:00
Niccolò Izzo
6322cb49a4
Cleanup demodulator, improved quantization log
...
Unified offset and phase variable to reduce the chance of off-by-ones
between buffers. Improved logging on linux and module17 adding
quantization indices.
TG-81
2022-05-27 21:49:33 +02:00
Silvano Seva
ff7a28ff59
RingBuffer class: implemented eraseElement() function, rewritten the pop() function in a cleaner way, fixed a bug in the pop() function causing the not_full condition variable to be never rised.
2022-05-27 21:49:33 +02:00
Niccolò Izzo
29ad0830f0
M17 demodulation improvement
...
Add logging in syncword sweep, fix unsigned underflow bug,
fixed symbol average computation for quantization.
Do syncword sweep whenever available.
TG-81
2022-05-27 21:49:33 +02:00
Silvano Seva
d17d683b2d
M17 code cleanup pass: reorganised data type definitions and constants
2022-05-27 21:49:33 +02:00
Silvano Seva
7aff678069
Improved robustness of frame type detection, now based on minimum hamming distance between syncwords
2022-05-27 21:49:33 +02:00
Niccolò Izzo
c987848382
Add syncword hot re-sync fix DC removal
...
DC removal filter had a bug that created weird positive spikes on
Module17, add a syncword hot re-sync to be able to correct small phase
errors that appear every five seconds more or less.
TG-81
2022-05-27 21:48:47 +02:00
Silvano Seva
1f77c2af6c
Reorganised logging inside M17 demodulator, logging is disabled by default.
...
On non-linux devices log data is printed on the serial port in raw binary format.
2022-05-27 21:48:47 +02:00
Silvano Seva
6be567a781
Implementation of a statically allocated ring buffer with blocking and non-blocking push and pop
2022-05-27 21:48:47 +02:00
Niccolò Izzo
ef61c532a3
Cleaned up quantization average
...
Now average is computed over all the syncword symbols, for each syncword
as a simple average.
TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo
5fe5b0e578
Refactor M17 logging
...
Refactored logging functions to enable in-system logging on Module17 and
MDx radios.
TG-81
2022-05-27 21:48:47 +02:00
Silvano Seva
361308be16
Generator of pseudorandom binary sequence compliant with M17 specification
2022-05-27 21:48:47 +02:00
Silvano Seva
3988540b6c
Changed coefficients for the 41-tap, 24kHz RRC filter to have unitary input-output gain
2022-05-27 21:48:47 +02:00
Niccolò Izzo
c3c984d504
Add syncword fuzzy detection
...
Frame decoder now tolerates bit error in syncword, removed syncword type
detection in demodulator code.
TG-81
2022-05-27 21:48:47 +02:00
Silvano Seva
6b31a73f42
Corrected RRC gain and changed HR_C5000 modulation factor and input gain to have the correct 2.4kHz deviation when transmitting M17 with an MD3x0 radio
2022-05-27 21:48:47 +02:00
Niccolò Izzo
2d59658d60
Switch M17 Rx sample rate to 5SPS
...
Due to the RRC computation sometimes violating the timing constraints,
we switched the M17 demodulator to 5 samples per symbol (24KHz), thus
dividing the processing time by four ar the number of samples halves as
well as the number of taps of the RRC.
Minor adaptation on the code followed.
TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo
63bd864674
Fix M17 Rx LED
...
Now LED turns on when a syncword is successfully detected, not just when
the correlation is sufficiently high.
TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo
c4483edff0
Improve quantization strategy
...
Now quantization is performed by averaging syncword samples and dividing
the resulting threshold by a constant.
TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo
7d1b89550e
Rewrite quantization algorithm
...
Quantization algorithm is now based on separate rolling averages for
positive and negative samples.
Merged csv outputs from syncword search and quantization on Linux.
TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo
aa9fcc26b7
Remove useless DC bias in quantization
...
TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo
d1651a702c
Add proper DC-bias removal, tuned EMAs
2022-05-27 21:48:47 +02:00
Silvano Seva
da5c453852
Implemented unpacking and decoding of M17 audio stream frames
2022-05-27 21:48:47 +02:00
Silvano Seva
beca0d2acc
Reorganised constants inside M17 demodulator class
2022-05-27 21:48:47 +02:00
Silvano Seva
fda0fed5e7
Moved constant specifying sample rate for M17 baseband decoding from hwconfig.h files to M17Demodulator class
2022-05-27 21:48:47 +02:00