Wykres commitów

586 Commity (da22d6ff64d640d5ba2e627b749a66f521709683)

Autor SHA1 Wiadomość Data
Silvano Seva 54a89abcd0 Removed a printf left behind after debugging from M17 demodulator class and slightly cleaned up the code 2022-05-27 21:48:47 +02:00
Silvano Seva c9a4bfb199 Cleanup and refactoring of M17 modulator class, now using output streams for baseband signal output 2022-05-27 21:48:47 +02:00
Silvano Seva 0df1dc4f7e Extended output stream API to support also circular double-buffered mode, implemented output stream driver for MDx 2022-05-27 21:48:47 +02:00
Silvano Seva 5c90c19bea Data conversion utilities 2022-05-27 21:48:47 +02:00
Silvano Seva 7891288030 Fixed compilation warnings generated by graphics.cpp 2022-05-27 21:48:47 +02:00
Silvano Seva 427c5f50b3 Made M17Demodulator::update() return a boolean indicating when a new decoded frame is ready 2022-05-27 21:48:47 +02:00
Niccolò Izzo 77aead675a Improve runtime performance of M17 Demodulator
Tweaked the exponential moving average alpha factors to improve the
reactivity of the M17 demodulator.

TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo 5ef145cd39 Add fuzzy syncword validation
Now syncword match is not exact but can tolerate up to two erroneous
bits.

TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo ca49b306b9 Update constants for M17 demodulation
Constants were updated to increase performance based on baseband sample
collected with Module17.

TG-81
2022-05-27 21:48:47 +02:00
Niccolò Izzo 2d8c696a09 Complete M17 demodulator implementation
Make quantization work also on DC offset signal
Add samples plot code
Fix bug in buffer wrap around
Fix oob memory access in M17 modulator
Update tests with DC offset signal
Switch to 48KHz sample rate for Module17 and MD380
Add DC biasing script

TG-81
2022-05-27 21:48:46 +02:00
Niccolò Izzo f9c23452bc Add plotting function to graphics library
Added plotting function to graphics library which is native C++, so
refactored the graphics source file to allow that, consequently adapted
the hwconfig header files to be included also in C++ sources.
Propagated compile flags also to C++ sources, including asan what was
previously disabled for C++ compilation units.

TG-81
2022-05-27 21:48:46 +02:00
Niccolò Izzo ae26cca46f Remove SPS
Now M17_SAPLES_PER_SYMBOL is computed dinamically from sample rate.

TG-81
2022-05-27 21:48:46 +02:00
Niccolò Izzo a091bca35f M17 Demodulator bugfixes
Fixed several bugs in the M17 Demodulator code.

TG-81
2022-05-27 21:48:46 +02:00
Silvano Seva d2c7be9cc8 Fixed bug affecting LSF reassembling from LICH segments inside M17 frame decoder class 2022-05-27 21:48:46 +02:00
Silvano Seva 35c1f062c6 Implementation of M17 frame encoder 2022-05-27 21:48:46 +02:00
Silvano Seva 82dd0a63f1 Clarification of naming: renamed DATA_SYNC_WORD to STREAM_SYNC_WORD and Audio_puncture to DATA_PUNCTURE 2022-05-27 21:48:46 +02:00
Silvano Seva 25087b0e02 Removed BUF_CIRC from the possible buffer management modes for an input audio stream 2022-05-27 21:48:46 +02:00
Silvano Seva 5fbd39959c Implementation of M17 frame decoder 2022-05-27 21:48:46 +02:00
Silvano Seva 49bd8ee2f4 Reorganised internal structure of M17LinkSetupFrame class, renamed M17Frame to M17StreamFrame and reorganised its structure 2022-05-27 21:48:46 +02:00
Silvano Seva c73aa92305 Reorganised M17LinkSetupframe and M17Frame classes, encapsulating structs defining their internal data structure 2022-05-27 21:48:46 +02:00
Silvano Seva 8f63d349a2 Temporarily deactivating M17 demodulator until fully debugged as it makes the radio crash 2022-05-27 21:48:46 +02:00
Niccolò Izzo 7a9bbfcaf2 Demodulator bugfix
Fix several bugs in the demodulator code, tipycally sign errors.
2022-05-27 21:48:46 +02:00
Niccolò Izzo 1a9b3c4168 Implement M17 demodulator logic
Implemented frame wrapping logic and demodulator loop.
2022-05-27 21:48:46 +02:00
Silvano Seva 963fbdc141 M17 mode handler: calling demodulator update function when in RX mode 2022-05-27 21:48:46 +02:00
Niccolò Izzo d22948a096 Fix naming error
Replaced FM with OPMODE_FM and DMR with OPMODE_DMR.
2022-05-27 21:48:46 +02:00
Niccolò Izzo 5bf4df75ba Fine tune demodulator to OpenRTX M17 baseband
Fine tuned M17 demodulator with code generated from OpenRTX itself.

TG-81
2022-05-27 21:48:46 +02:00
Niccolò Izzo 4b498689f5 Replace RRC filter taps, update M17 testsuite
RRC filter taps have been replaced with the ones generated by Wojciech,
a new baseband for the M17 demodulation testsuite has been generated,
using OpenRTX itself and some further minor changes.

TG-81
2022-05-27 21:48:46 +02:00
Niccolò Izzo 3163dd49d7 Add M17 demodulator code and tests
Added implementation of the M17 4FSK demodulator, including clock
recovery, phase detection, and quantization algorithms.
A testsuite is also included to do regression testing against a
reference baseband pre-generated and the corresponding reference
bitstream.

A 1% BER is still present due to a fault likely in the RRC filtering,
since the eye diagram of the filtered stream is bad.

TG-81
2022-05-27 21:48:46 +02:00
Silvano Seva 396f66a1f3 Implementation of M17 Viterbi decoder and associated unit test 2022-05-27 21:48:46 +02:00
Niccolò Izzo 3aeade6c1f Clarify M17 modulator constant naming
Further clarify modulator constant naming for sample rate and frame
lengths, to distinguish between demodulator values.
2022-05-27 21:48:46 +02:00
Niccolò Izzo 6588a6718e Add M17 namespace in M17 related source files
Now M17 source files reside in the M17 namespace, the OPMODE_ prefix
was added to all opmode enums to avoid a name clash.
2022-05-27 21:48:46 +02:00
Niccolò Izzo 876cb87d57 Move rrc filter into separate compilation unit
By moving the rrc filter into a separate compilation unit with its own
header file, we can use it both in the modulator and in the demodulator.
2022-05-27 21:48:46 +02:00
Niccolò Izzo c648ffe377 Add draft of M17Demodulator class 2022-05-27 21:48:46 +02:00
Silvano Seva 8a3643ad3a Implementation of Golay(24,12) decoder, reimplemented Golay(24,12) encoder using generator matrix, unit test for Golay(24,12) encoding and decoding routines 2022-05-27 21:48:46 +02:00
Silvano Seva a3b7b490d4 Fixed jitter in M17 baseband signal generation 2022-05-27 21:48:46 +02:00
Silvano Seva 5ffd6e5c43 Fixed compilation errors with MD-9600 and Module 17 targets 2022-03-24 19:09:00 +01:00
Silvano Seva ab3d148449 Implemented activation of external flash backup and restore via menu entries 2022-03-22 15:10:52 +01:00
Silvano Seva a1c26b2898 Simple utility functions for backup and restore of external flash memory content 2022-03-22 13:39:08 +01:00
Silvano Seva f513454acf Implementation of xmodem data reception 2022-03-21 17:36:27 +01:00
Niccolò Izzo 48824accb9 Add flash backup and restore menu
Add flash backup and flash restore entries to menu system, to access
these functionalities from the radio itself.

TG-428
2022-03-13 00:21:52 +01:00
Silvano Seva 7e3131d9d1 Implemented xmodem data sending 2022-03-12 23:32:31 +01:00
Silvano Seva e56cf52f28 Partial implementation of xmodem protocol: function for transmission of xmodem packets and small testsuite for dumping the content of external flash memory via xmodem 2022-03-11 19:28:45 +01:00
Silvano Seva 052580df3a Implementation of CCITT CRC16 2022-03-05 11:08:31 +01:00
Silvano Seva 3588f351a1 Created 'core' subfolders inside openrtx/include and openrtx/src containing main OpenRTX source files 2022-03-05 10:39:35 +01:00
Silvano Seva 3f2df608c9 Moved code for radio state update to a dedicated function 2022-02-27 09:00:49 +01:00
Silvano Seva a5209d6f52 Modified range for display backlight level from 0 - 255 to 0 - 100, set minimum allowed level to 5. 2022-02-26 15:45:41 +01:00
tarxvf 9297c08b05
Add a menu for clearing settings and vfo to sane defaults (#67) 2022-02-26 12:42:28 +01:00
Silvano Seva f54a0d18a7 Implemented mechanism to allow backwards-compatibility when loading settings from memory, as backlight timer introduced a new data field 2022-01-03 15:42:16 +01:00
Alessio Caiazza d04180c0df Rename brightness_timer into display_timenr 2022-01-03 14:51:22 +01:00
Alessio Caiazza 351cab1f44 Don't waste extra memory for the brightness timer 2022-01-03 14:51:22 +01:00
Alessio Caiazza d742d027b7 Display timer UI 2022-01-03 14:51:22 +01:00
Alessio Caiazza 269420c2be Load standby timer from settings 2022-01-03 14:51:22 +01:00
Alessio Caiazza fefe2f6de0 Exit standby when the squelch is open 2022-01-03 14:51:22 +01:00
Alessio Caiazza ade9c47f71 Implement platform_setBacklightLevel for linux 2022-01-03 14:51:22 +01:00
Alessio Caiazza 6e3fda2a70 PTT terminates standby
Also the keypress getting out of standby is ignored unless is the MONI
key to activate the MACRO menu
2022-01-03 14:51:22 +01:00
Alessio Caiazza f9751c9867 Send the screen in standby after 30s idle 2022-01-03 14:51:22 +01:00
Alessio Caiazza 78a2b02c91 Show TX frequency during transmission 2021-12-23 14:52:25 +01:00
Alessio Caiazza 91486291b6 MD380: adjust squelch with left and right keys 2021-12-23 14:52:25 +01:00
Silvano Seva 3c6ad9802c Added API function allowing to query the current status of the RX audio squelch 2021-12-23 14:52:25 +01:00
Alessio Caiazza 18fb916834 Remove all tabs 2021-12-23 14:52:25 +01:00
Alessio Caiazza e2baf5a833 Document functions with Doxygen format 2021-12-23 14:52:25 +01:00
Alessio Caiazza 8a0f0564b9 Ensure proper finalization is done in emulator mode 2021-12-23 14:52:25 +01:00
Alessio Caiazza 82699f3d07 Implement an SDL main loop inside the Main Thread 2021-12-23 14:52:25 +01:00
Alessio Caiazza 51acccaec2 Don't pump SDL events outside from the main thread 2021-12-23 14:52:25 +01:00
tarxvf e7c98aa71f fixes #60 (make sure volume setting is restored after tx) 2021-12-23 14:52:25 +01:00
Alessio Caiazza 5605797816 Never store a brightness level of 0
Enforce a minimum brightness level to prevent booting with a black screen

Related to https://github.com/OpenRTX/OpenRTX/issues/50
2021-12-23 14:52:25 +01:00
Niccolò Izzo 2fdbf0f236 Initial support for I2C soft pots on Module17
Initial support for I2C soft pots on Module17, ADC1 driver for input voltage
reading. Cherry-picked from Mathis DB9MAT repo.

TG-398
2021-12-23 14:52:25 +01:00
Silvano Seva 691b388228 Implemented load/save of settings and VFO configuration for MDx devices 2021-11-09 19:28:23 +01:00
Silvano Seva 756812ca31 Created function for writing settings and VFO status to NVM, starting of temporary implementation writing data to the MCU's internal flash 2021-11-08 22:22:26 +01:00
Silvano Seva c91e306026 Reorganised settings data structure 2021-11-08 21:44:33 +01:00
Silvano Seva 83fdfc4367 Setting default squelch level at boot to S3 for all platforms. Solves #44 2021-10-18 21:05:32 +02:00
mark 17cdf3c67b https://github.com/OpenRTX/OpenRTX/issues/43 Force Squelch re-detection when coming out of TX. 2021-10-18 20:58:24 +02:00
Federico Amedeo Izzo 1e19574fd6 Add destination callsign input for M17, Add -/ to keypad input 2021-10-09 18:53:28 +02:00
Niccolò Izzo 65a632054a Disable CTCSS tones in M17 mode
Removed CTCSS modulation for M17 mode, removed FM analog specific
settings in macro menu such as tone selection, tone enable and tx
bandwidth.
2021-10-08 16:02:03 +02:00
Silvano Seva 42e7521205 Fixed compilation error with GDx targets
Added codec2 as a dependency also for GD77, DM1801 and MD9600 targets to allow compilation of OpMode_17.cpp file
Stub input audio stream driver for GDx targets
2021-10-06 21:43:07 +02:00
Silvano Seva 7db53b8bdc Fixed some compiler warnings 2021-10-06 21:30:45 +02:00
Silvano Seva a9e1e68709 Implemented function for inverse code puncturing in M17 protocol 2021-10-03 12:09:00 +02:00
Federico Amedeo Izzo 990f5e8ce6 UI: Fix level meter and set it to platform mic level 2021-09-26 18:38:29 +02:00
Silvano Seva d018dbb4a0 Implementation of M17 polynomial deinterleaver 2021-09-20 21:34:59 +02:00
Silvano Seva f2f013f5a5 Switched to pthread API for CODEC2 thread management inside M17 OpMode handler 2021-09-19 15:29:43 +02:00
Silvano Seva 0b276b2b64 Experimental implementation of voice transmission in M17 protocol handler 2021-09-07 12:22:35 +02:00
Niccolò Izzo 120fd92d73 Fix M17 callsign management
Now a default callsign "OPNRTX" is used in M17 mode, and when the user
sets its own callsign in the settings menu, that one is correctly used
instead. Add initialization to RTX data structure.
2021-09-06 22:55:46 +02:00
Niccolò Izzo e60d79241d Set CAN to 0 2021-09-05 22:05:13 +02:00
Silvano Seva b1a91603c8 Fixed wrong function signature in dsp.cpp causing linking errors 2021-09-05 19:03:29 +02:00
Silvano Seva e954f3fda2 Moved sleep regulating update rate of rtx task from rtx thread to OpMode implementations, as each operating mode may require a custom update rate 2021-09-03 16:44:57 +02:00
Silvano Seva bad5a50d7d Updated code puncturing pattern for M17 link setup frame to follow new specifications 2021-09-03 16:44:57 +02:00
Silvano Seva 2f3db118fc Changed streamType_t from bitfield struct to union of anonymous bitfield struct and uint16_t to facilitate endianness conversion. Change also fixed a bug in endianness conversion inside M17LinkSetupFrame class due to unaligned memory access. 2021-09-03 16:44:57 +02:00
Silvano Seva 065c15fb72 Force deactivation of TX and RX tone squelch for operating modes different from FM 2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo c04ceb9a8d Add M17 radio mode to UI 2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo c23eaf8e98 Add M17 src/dst addresses to rtxStatus_t 2021-09-03 16:44:57 +02:00
Niccolò Izzo eea9be3349 Add M17 codeplug data structures 2021-09-03 16:44:57 +02:00
Niccolò Izzo f43f54117c Fix M17 callsign setting
Fix M17 callsign disappearing in M17 settings.

The generic callsign (currently not used) was being shown instead of M17 callsign.
2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo dc28f90a1d Fix keypad text input, add caps-only input, add terminator to callsign 2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo f104955686 Text Input: Delete character by using any arrow button 2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo acc1c2a779 M17: Print source and destination IDs in mode screen 2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo 229a81b2ad Add text input draft
Fix text input position not being reset when entering edit mode
2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo 87703a76e6 Add M17 Settings 2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo 882a657359 * Combine S-meter and Level meter
* Make squelch bar always yellow
* Include font height in s-meter total height

Correct bottom bar printing position

Increase bottom bar size on GD-77
2021-09-03 16:44:57 +02:00
Federico Amedeo Izzo 118c514081 UI: Add digital mode screen
Use main screen bottom bar in mode screen

mode screen: Move frequency and channel name to center

Show S-meter without squelch bar for digital modes

Change S-meter for digital modes, add audio level meter

Print FM information in mode screen

Add mode screen fonts
2021-09-03 16:44:57 +02:00
Silvano Seva 92ea1535ff Moved definition of 'PLATFORM_LINUX' macro from hwconfig to meson.build, added '-std=c++14' compilation flag to compile arguments for linux platform, added missing includes to M17Utils.h 2021-09-03 16:44:57 +02:00