Silvano Seva
c2b6bd545f
API interfaces for audio path and audio stream management
2021-08-25 18:30:28 +02:00
Silvano Seva
4d3eacc144
Switched 'v_bat' and 'charge' fields of state struct from float to, respectively, uint16_t and uint8_t and updated UI functions accordingly. Rationale for this change is providing better support for future platforms without hardware floating point unit.
2021-08-14 12:56:45 +02:00
Silvano Seva
46819ba993
Modified 'battery_getCharge': now it takes as input the battery voltage in mV and returns charge percentage as an integer ranging from 0 to 100. Function body is implemented using fixed point math instead of floats for improved platform compatibility when hardware floating point support is not present.
2021-08-14 12:52:55 +02:00
Silvano Seva
a7acc3301b
Modified 'platform_getVbat' API: now it returns an uint16_t value containing the battery voltage in millivolt
2021-08-14 12:47:21 +02:00
Silvano Seva
8e0a5d1c0f
Made 'platform_getVolumeLevel' and 'platform_getMicLevel' API functions return a normalised 8 bit value ranging from 0 to 255 (TG-293 #closed)
2021-08-14 10:18:55 +02:00
Silvano Seva
a1ca509eec
Restore original functionality of getCurrentFreeHeap() memory profiling function, as the cause of its incorrect behaviour has been found
2021-08-10 09:35:00 +02:00
Niccolò Izzo
3bdaae0805
Fix squelch control on md3x0
...
Knob now generates dedicated KNOB_LEFT and KNOB_RIGHT messages,
fixed ui to consider those for enabling the squelch change.
2021-07-10 06:57:09 +02:00
Silvano Seva
eb474d6bee
Driver for STM32F4 USART3, can be used as a debug serial interface on MD3x0 devices without GPS and is enabled by defining the macro MD3x0_ENABLE_DBG
2021-07-09 08:53:12 +02:00
Federico Amedeo Izzo
1fbecb4c22
Increase keyboard thread polling rate to 40Hz to improve knob reactivity
2021-06-07 20:10:02 +02:00
Silvano Seva
6995230d8f
Extended 'mode' field in CPS data structure to 8 bits, to align its size to the one contained in rtxStatus_t. Modified code for channel data loading in NVM drivers to align it to the new opMode enum values.
2021-06-05 21:21:12 +02:00
Federico Amedeo Izzo
57b66652b7
Use channel knob to change frequency and navigate menus (TG-238)
2021-06-05 18:11:30 +02:00
Federico Amedeo Izzo
f5a70b3e43
Fixed Initial GUI rendering with an empty state
2021-06-05 16:32:05 +02:00
Federico Amedeo Izzo
01b4a98f85
Set initial frequency based on supported bands (TG-239)
2021-06-05 11:06:22 +02:00
Federico Amedeo Izzo
f5c9d97e49
Check frequency limits against hwInfo_t, not hardcoded defines
2021-06-05 10:47:52 +02:00
Federico Amedeo Izzo
5b3f2b7e23
Simplify frequency limits check for VFO input
2021-06-05 10:08:15 +02:00
Federico Amedeo Izzo
49cb28c5b8
Fix RTX not updated when switching from MEM to VFO (#30,TG-240,TG-241)
2021-06-05 09:36:00 +02:00
Silvano Seva
66552be403
Added function to radio API allowing to fine tune the radio's VCXO polarisation voltage. Currently, this functionality is effective only on MD-3x0 devices. (TG-195 #ready-for-test)
2021-06-03 14:50:47 +02:00
Silvano Seva
b29b24fdc0
Implemented RX tone squelch on MD-UV3x0 and GDx (TG-43)
2021-06-02 12:44:46 +02:00
Silvano Seva
4d68f02ab4
Updated documetation for radio.h API, removed old baseband C source files.
2021-05-29 08:20:12 +02:00
Silvano Seva
2d517d5bf8
New radio driver for GDx. Renamed some entries in GDx calibration data structure
2021-05-29 08:20:12 +02:00
Silvano Seva
f1a01d7613
New radio driver for MD-UV3x0, testing required
2021-05-29 08:20:12 +02:00
Silvano Seva
f0dfd7036f
Fixed bug in OpMode_FM.cpp which prevented entering in RX mode, removed code for setting input gain in HR_C5000 driver, modified meson.build to make it compile the new sources
2021-05-29 08:20:12 +02:00
Silvano Seva
850e3580ed
New radio driver for MD-3x0 platform, still requiring a bit of debugging
2021-05-29 08:20:12 +02:00
Silvano Seva
5b0bec8c5f
Created OpMode class for modular OOP-based management of operating modes. Created OpMode_FM class for analog FM management. Refactored and moved to C++ the content of openrtx/src/rtx.c. (TG-38, TG-41)
2021-05-29 08:20:12 +02:00
Silvano Seva
d95e36f43b
Moved to C++ and refactored AT1846S driver, grouping common code. A C-callable wrapper is also provided. TG-37
2021-05-29 08:19:47 +02:00
Niccolò Izzo
e3a128f035
Add DSP code with DC removal and FIR PWM filter compensation
...
Add generic FIR implementation, specialized to compensate the PWM filter
applied by STM32 targets when modulating M17 signal.
Add DC bias compensation to normalize audio signal received from STM32
ADC.
TG-85 #ready-for-test
TG-199 #ready-for-test
2021-04-16 09:46:32 +02:00
Silvano Seva
a850f9f1ab
Removed packed attribute from rtx and radio state data structures as they can cause crashes due to unaligned memory accesses.
2021-04-15 21:24:26 +02:00
Silvano Seva
c0ecf2e13f
Basic audio management module, controlling only speaker PA and microphone preamplifier. TG-61
2021-04-12 19:10:13 +02:00
Silvano Seva
90048700ba
Fixed compilation error on linux target after addition of memory profiling functions
2021-04-12 12:13:55 +02:00
Silvano Seva
60defbedc0
Implemented stack and heap memory profiling functions. TG-47
2021-04-12 12:03:15 +02:00
Silvano Seva
4b30a66735
Added 'platform_pwrButtonStatus' API function, which returns the current status of the power button/knob. Implemented power on/off mechanism on MD-9600
2021-04-11 12:38:20 +02:00
Federico Amedeo Izzo
a42354a204
Remove Messages menu as it's not implemented yet
2021-04-11 10:06:12 +02:00
Federico Amedeo Izzo
58f4f5dcaf
Print git commit or tag inside Info menu
2021-04-11 09:56:46 +02:00
Federico Amedeo Izzo
93d2ede113
Add default contrast setting define
2021-04-11 09:10:08 +02:00
Federico Amedeo Izzo
26eb381ca2
Fix date change if timezone brings to different day
2021-04-10 15:57:58 +02:00
Federico Amedeo Izzo
341c46a263
Now state.time is UTC, add functions to convert from UTC to local and reverse
2021-04-10 15:39:59 +02:00
Silvano Seva
d70e0bc60a
Made 'battery_getCharge' return full charge when 'BAT_NONE' is defined
2021-04-10 12:45:07 +02:00
Silvano Seva
cdaf3f38dd
Renamed MDx display, keyboard and spiFlash drivers to MD3x to adapt the changes made to meson.build also to MD-9600. Fixed missing API change in ui_main.
2021-04-10 12:37:45 +02:00
Federico Amedeo Izzo
2d3d932111
Print battery voltage instead of battery icon for platform without battery
2021-04-10 12:16:21 +02:00
Federico Amedeo Izzo
8045a9bcea
Improve gfx_printLine calculation
2021-04-10 11:10:52 +02:00
Federico Amedeo Izzo
3e326a43f0
Add gfx_getFontHeigth() function
2021-04-10 11:10:52 +02:00
Federico Amedeo Izzo
c3a8251ca9
Integrated getLineY() functionality in gfx_printLine()
2021-04-10 11:10:52 +02:00
Federico Amedeo Izzo
765fb3f4c9
Add getLineY Layout helper function
2021-04-10 11:10:52 +02:00
Federico Amedeo Izzo
0e33848d68
gfx_print: use global buffer instead of allocating it to the stack
2021-04-10 11:10:52 +02:00
Federico Amedeo Izzo
341ab84ce9
Converted `gfx_print()` from char * pointer to format string
2021-04-10 11:10:52 +02:00
Niccolò Izzo
d4ad8b12b1
Fix bug on MD380
...
Fixed a bug where pressing the side button would lead to a crash,
probably caused by a misaligned memory access, due to the addition of a
packed attribute.
2021-04-09 13:26:01 +02:00
Federico Amedeo Izzo
9fb7ace303
Fix swapped UP/DOWN keys in Display Settings
2021-04-04 20:36:23 +02:00
Caleb Jamison
e5c5ee90f2
Add support for encoder knob on MD-UV380
...
Added: qdec, a header only quadrature encoder library
Added: EXTI15_10_IRQHandler to handle the encoder knob
Changed: platform_init() for the MD-UV380 now configures the EXTI15_10
interrupt.
Changed: platform_getChSelector now returns signed int8
Changed: size of settings_t.valid went from 6 to 7
Without this change, pressing the macro button crashes the radio, I
haven't investigated and I don't remember how I found that solution.
Changed: meson.build includes the qdec library
2021-04-03 09:21:47 +02:00
Niccolò Izzo
b6eab0fde7
Fix failing boot on MD380
2021-04-02 08:43:31 +02:00
Silvano Seva
1d8596e3c8
Renamed 'MD-UV380' folder and 'PLATFORM_MDUV380' define to, respectively, 'MD-UV3x0' and 'PLATFORM_MDUV3x0' to make them consistent with the meson build target
2021-04-01 08:48:56 +02:00
Silvano Seva
86f6d114e2
Applied __attribute__((packed)) to all data structures to reduce memory footprint
2021-03-26 18:11:22 +01:00
Silvano Seva
9d02ffaea4
Fix for #20 , caused by a memory leak when clearing information about GPS satellites in state data structure
2021-03-26 17:50:06 +01:00
Silvano Seva
90122b0c7a
Fixed bug in gps task which made it setting time and date even whithout GPS fix.
2021-03-24 12:28:57 +01:00
Fred
f4e25a3f8f
Fix compilation for gd77 and dm1801 targets
2021-03-24 09:25:57 +01:00
Niccolò Izzo
d95e0a1513
Print signed GPS longitude as unsigned+direction
2021-03-24 08:54:46 +01:00
Federico Amedeo Izzo
75df9b7bb8
Set default squelch to S3
2021-03-24 08:54:46 +01:00
Federico Amedeo Izzo
75cd4417c7
Restore squelch functionality after mute fix
2021-03-21 17:51:23 +01:00
Federico Amedeo Izzo
e8ae618382
Add ifdef to fix compilation on Linux
2021-03-21 11:59:35 +01:00
Federico Amedeo Izzo
3a92547ef5
UV380: Mute speaker when volume knob is set to minimum
2021-03-21 11:42:47 +01:00
Federico Amedeo Izzo
42153be082
Macro Menu: Change squelch also with UP and DOWN
2021-03-21 09:14:44 +01:00
Silvano Seva
2bde981222
Removed speaker 'POP' on squelch opening and when starting TX with squelch open
2021-03-20 11:51:35 +01:00
Silvano Seva
c1abeefd67
Implemented volume control for audio coming from radio stage on MD-UV3x0 and fixed a compilation warning regarding non-const access to a const variable
2021-03-20 11:51:35 +01:00
Silvano Seva
a5120ffddc
Radio driver for MD-UV3x0 targets
2021-03-20 11:51:35 +01:00
Federico Amedeo Izzo
0d9d77d3ca
Manually trim FreeSans6pt7b font to make it more symmetric
2021-03-14 18:43:33 +01:00
Silvano Seva
01ea1a9b3f
Made the main() thread run the UI task, thus removing the need for a dedicated one
2021-03-14 17:17:24 +01:00
Silvano Seva
952f5afc3c
Fixed squelch issue on GDx which made it briefly opening whenever an RTX parameter changed
2021-03-14 16:54:07 +01:00
Federico Amedeo Izzo
92e0abafa2
Display: Set default contrast at boot. Improve default contrast for GD-77
2021-03-14 11:35:45 +01:00
Federico Amedeo Izzo
3da311ee38
UI: Change contrast steps to 4 to match GD-77 HW contrast range (0-63)
2021-03-14 11:21:39 +01:00
Federico Amedeo Izzo
1637159329
Completely disable persistence until we have a proper flash backup/restore method
2021-03-13 23:03:37 +01:00
Federico Amedeo Izzo
9720032238
Disable reading VFO and settings from flash until persistence is implemented
2021-03-13 22:52:37 +01:00
Federico Amedeo Izzo
9e7b04c1fa
Disable reading VFO channel from flash to fix boot freeze on GD-77
2021-03-13 22:21:23 +01:00
Silvano Seva
a02b693843
Made the RTX thread run with the maximum priority on ARM Cortex targets
2021-03-13 09:16:06 +01:00
Silvano Seva
20ad9b7dcf
Fixed issue with MDx ADC, rolling back to real battery voltage measurement
2021-03-13 09:16:06 +01:00
Silvano Seva
81e8aae103
Re-enabled all the tasks, temporarily bypassing battery voltage reading since it has to be debugged
2021-03-13 09:16:06 +01:00
Silvano Seva
e5316aa8be
Minimal refactoring of queue sources
2021-03-13 09:16:06 +01:00
Silvano Seva
fb3447b0c6
Moving to miosix kernel: swapped old uC/OS-III task management functions with pthread ones
2021-03-13 09:16:06 +01:00
Silvano Seva
2b28ea0525
Moving to miosix kernel: added two functions to 'interfaces/delays.h' to provide substitutes for their uC/OS-III counterparts and removed the old rtos sources
2021-03-13 09:16:06 +01:00
Silvano Seva
093640478c
Moving to miosix kernel: adapted GDx drivers and part of the common code to new configuration
2021-03-13 09:16:06 +01:00
Silvano Seva
7992b4abca
Moving to miosix kernel: adapted MDx drivers to new configuration
2021-03-13 09:16:06 +01:00
Silvano Seva
cbfb78e19e
Fixed bug which made the GPS task re-syncronising the RTC with GPS time once per second.
2021-03-13 09:14:26 +01:00
Federico Amedeo Izzo
fb3c055f85
Disable writing settings until DFU support is ready
2021-03-01 20:52:57 +01:00
Niccolò Izzo
de85ba90cb
Filter out BeiDou NMEA strings
2021-02-25 11:20:31 +01:00
Silvano Seva
056c53b35d
Made UI fsm skip low battery check when TX is enabled to avoid spurious triggers of low battery alert caused by the high current absorption from RF PA
2021-02-24 21:00:30 +01:00
Niccolò Izzo
6b24895ef3
Extended GPS support to UV-380 module
2021-02-24 08:07:58 +01:00
Silvano Seva
3438006ef5
Removed moving average filtering from MDx ADC1 driver, added code for proper filtering of ADC samples in platform-independent code
2021-02-23 15:49:55 +01:00
Silvano Seva
416ae13eb1
Fixed linking error when building for linux
2021-02-23 14:01:09 +01:00
Niccolò Izzo
eb0a5ee9f0
Fix compass orientation, speed formatting
2021-02-21 20:38:54 +01:00
Silvano Seva
d0e8d15389
Added 'packed' attribute to settings data structure. Some refactoring of settings and state code.
2021-02-21 19:25:09 +01:00
Federico Amedeo Izzo
35bde9bccb
Add state_terminate() that saves settings to flash
2021-02-21 16:44:31 +01:00
Federico Amedeo Izzo
d4981ee288
Add Settings persistence to SPI Flash
2021-02-21 15:58:41 +01:00
Federico Amedeo Izzo
0b14e36bdb
Fix About screen on GD-77
2021-02-20 16:25:06 +01:00
Federico Amedeo Izzo
820ac73d08
UI: Add menu_h and menu_font layout parameters
2021-02-20 16:03:37 +01:00
Federico Amedeo Izzo
9c47797ff0
UI: Fixed mismatch between visible and selectable menu elements
2021-02-20 15:47:41 +01:00
Federico Amedeo Izzo
c644e8db1d
UI: Remove position parameter from menu list
2021-02-20 15:35:19 +01:00
Federico Amedeo Izzo
711d8426c9
Add 10pt font. Reduce frequency line on GD-77 to avoid overlap
2021-02-20 15:14:35 +01:00
Federico Amedeo Izzo
5bb200933b
UI: Add missing GPS ifdefs
2021-02-17 20:02:53 +01:00
Niccolò Izzo
f49655c44d
Better GPS time synchronization
2021-02-17 14:58:20 +01:00
Niccolò Izzo
4d66d8b1af
Fix various warnings
2021-02-17 11:21:46 +01:00
Federico Amedeo Izzo
f357f476dc
GPS: Enable GPS on gps_task start only if enabled in settings
2021-02-16 22:47:38 +01:00
Federico Amedeo Izzo
cecd01e03d
GPS: workaround: Move settings above gps_data to avoid settings
...
corruption caused by gps_data overflow
2021-02-16 22:44:21 +01:00