Commit Graph
133 Commits
Author SHA1 Message Date
philmozandGitHub f28c1150ed refactor(color): use LVGL styles and objects for UI, legacy cleanup (#4407) 2024-04-05 17:33:14 +10:00
philmozandGitHub b0e43e09ea chore(color): Cleanup bitmap code (#4319) 2023-11-17 10:36:05 +10:00
Peter FeerickandGitHub bd2d11ef8b feat(color): Show index and name (when set) for GVs in input source (#2219) 2023-11-13 09:02:36 +10:00
b48e07026d feat: More flexible ADC inputs (#3870)
Co-authored-by: 3djc <lesitewebdejc@hotmail.com>
Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
Co-authored-by: philmoz <phil.a.mitchell@gmail.com>
2023-11-02 11:07:53 +10:00
d396b38e8b feat: Add trainer virtual switch (#3937)
Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
2023-10-16 08:41:40 +10:00
philmozandGitHub 837677b3ef feat: Convert PPM_UNIT build option to runtime radio setting (#3993) 2023-10-10 19:47:50 +10:00
MichaelandGitHub 2d8d2fcf01 feat: MIN constant as a source option (#3639)
* feature request #1635

- added MIN (-MAX -> -1024) as source

* fix rebase

* fix rebase

* change to use language strings for MIN/MAX instead of instance

updated CN and TX language file for MINuse -RESX for MIN instead of magi numbercode cleanup

* updated test sources

* updated JP language

* JP language: changed translation text

* updated HE language translations
2023-08-28 20:16:00 +10:00
philmozandGitHub bd92f70056 feat: Support all current timezones for GPS (#3406)
* Support all current timezones.

* Fix function name and calculation for timezone offset.

* Allow setting any time offset value from -12 to +14 in 15 minutes increments.

* Alternate timezone editor in Companion (from elecpower).

* Fix compiler warning.

* chore: Add the T20
2023-07-16 14:02:27 +10:00
Raphael CoefficandMalte Langermann 2b100e0eb5 refact: ADC, switches and keys
Add "hardware_defs" target to dump hardware defines from hal.h per target

Fixed hal.h definitions for switches & ADC inputs

Tools to generate hardware definitions from current hal.h

generator: add support for EXTx and analog switches

WiP

Add generated header to hardware_defs target

Add support for ADC input direction and index per GPIO port

Incredible: it compiles

Removed StdPeriph ADC driver

Works on QX7

Works on TX16S (VBat missing)

Switch driver using generated switches for stm32 targets

Switch driver with generated switches for simu

Use switch names from switch driver

Fixed single conversion handling

Fixed horus VBat reading

Added switch name

Fix warnings about bitfield offsets and GCC 4.4

This is caused by bitfields that cross type boundaries. In this particular case, it happens as the bitfield is not defined the same in `rtc_backup.cpp`.

Switches has already been moved to generic driver

Jitter measurement for each sample, not just for oversampled values

Moved periph clock init to the ADC driver

ADC & GPIOs.

Add switchInit() to init pins

Fix NV14 CMake

Fix taranis target

Fix NV14 (again)

Model audio files: use new interface for switch index

Fix X9-lite

Fix simu headers

Fix getSwitchName()

Add support for ADC switches

Fix switch warning YAML

Test only switches which are defined

Conversions tests for QX7 only on QX7

Fix X12S

Fix function switch names

Enable ADC periph clock before initialising channels

NV14: offset inputs for the sticks & fix switches

WiP: get rid of VSRCRAW and some more

Simu shall use normal ADC driver

fix x7

fix nv14

Fix 9x nav

fix 212x64

fix xlite

fix x9e

fix simu lib

fix unit tests

fix x7 tests

PWM stick values should be written directly into adcValues

... just like FlySky sticks.

fix x12s

fix nv14

Add some support for SPI ADC (only unit tests)

Remove `jq` usage

fix generate_yaml.py for newer libclang

fix pot config

fix stick names

Some YAML generator improvements

Max 16 Pots on COLORLCD

Fix some source names

Use 10 bits for switches to prevent overflow

Removed horus constants for switches & ADC inputs

Fix unit tests

Fix curve edit

Fix libsimulator

Fix function switches (tpro)

Refine ADC & analog API

Moved hardware definitions scripts and templates into own dir

cleanup API refine

Fix unit tests

Mixer: apply calibration only on required inputs

Place ADC switches after all other ADC inputs

Fix X12S

Remove useless TR_POTS_VSRCRAW, TR_SW_VSRCRAW, and TR_VSRCRAW

Cleanup redundant generated YAML parsers

Fixes Boxer rebase

Add boxer to generate-hw-defs.sh

Obsolete LUA exports

Add boxer ADC_DIRECTION

Split generate_hw_defs.py into multiple files

Some cleanup (+ LUA switches)

Fix AXIS definitions

Fixed translation strings declarations

Some rebase fixes

Remove some useless StdPeriph drivers

fix: set pin mode to reset state on usart deinit

fix: use canonical names for calibration data

fix: ADC driver does not care about unconfigured inputs

fix X12S ADC

Add support for ADC conversion chaining

Better X12S ADC implem

Moved X12S ADC driver to HAL/LL

Improve ADC driver separation

Fixed taranis & nv14

Moved PWM gimbals to HAL/LL

Removed useless TR_EXTRA_VSRCRAW

Fixed include guards

Small fixes

Renamed control inputs

Moved internal and external module pulse driver def to boards

Move more things to the generic_stm32 board

Remove STR_VMIXTRIMS

Added analog labels

Generate main control names

Misuse labels / short labels for main controls

Backward compatibility: sliders and legacy names

New keys driver

Let's get rid of StdPeriph headers in simu

Add jinja2 to CI workflows

Use `grep` instead of `sed`

chore: add python jinja2 oto msys setup script

Removed more static definitions and use dynamic ones instead

Fixes X9E

Fix x7 nav too

212 switch display

Fix default sliders

Removed NUM_STICKS

212 switch display working nicely

Surface radio 'stick' replacements

fix: switch, trim & rotary pin init

Remove old key drivers

Removed VKEYS

Removed ETX_FOURCC

Fixed SURFACE_NAME

Removed TR_VSWITCHES & TR_TRIMS_SWITCHES

Fix xpot switches

Store calibrated analogs in physical order

Use getSourceString in drawSource

Implement missing YAML read/write

Fix isSourceAvailableInInputs()

Fix isSourceAvailable()

Some surface fixes

Fix CLI debug

Ported colour UI of analog diagnostics to new ADC API

Small fixes

Better input mapping

Minor tpro fixes

Fix trims available

Remove TX mode choice on surface radio

Rename surface controls

Channel order alignement

Fix throttle warning

Fix checkTrims()

Fix pot config casting issue

Fix IS_SWITCH_FS()

Fixed input mapping

Fix fswitch auto-switch

Fixed storing / reading function switches in YAML

Fix enableVBatBridge() / disableVBatBridge()

Fix interesting mode conversion

Fix sources issues

Fix special funnction list

Proper function switch handling

128 GUI improvements

Fix compilation

Boxer cosmetics

128 hardware screen cosmetic

Fix TX12 switches

More switches fixes

Simplify CPU type handling

Fix flash size

Fixed page-up / page-down in libopenui
2023-06-25 14:32:39 +02:00
MichaelandGitHub b4e13474df fix: hex2char() returning wrong char for 0xa..0xf (#3302) 2023-03-05 12:27:29 +10:00
Raphael CoefficandGitHub 72193eda82 chore: New module/serial API (#3055)
* WiP: new module interface

* WiP: softserial timer DMA

* WiP: setup() and send() in one step

and remove methods specific to internal or external module

* fixes and extra port config

* horus targets

* module ports have moved

* T8 support (only internal module)

* fix nv14

* stupid GCC....

* disable BT

* remove nv14 telem driver

* remove old aux serial driver

* Move module buffers out of pulses.h

* Soft serial fixes and PXX1 support

* Fixed PPM module output

* Fixed CLI

* compilation fixes

* Ported bluetooth and flysky gimbal to new serial driver

* Re-enable soft-serial RX

* fixes and cleanup

* nv14 fixes

* Fix flysky gimbals

* Ghost module

* 16 bytes of RAM

* Remove getByte from module API

* Ghost cleanup

* fix: _half_duplex_input() must be called after usart init

* WiP

* more cleanup

* Remove board specific settings from PXX1 / PXX2 drivers

* A bit of PXX2 header cleanup

* Add support for OVER8 and ONEBIT

* Add some support for inverters (NV14 / EL18)

* Support NV14 power fixes in generic board

* Fix polarity handling

* Fix RX DMA

* Fix mixer not running

* Add soft-serial polarity control

* Quick fix for telemetry polling while module port is changed

* Fix bootloader DEBUG

* Fix MPM telemetry

* Fix pulse start

* DSM2 soft-serial fallback

* DSMP async module restart

* Fix CRSF LUA upstream

* Remove global variable telemetryProtocol

* Use HAL/LL constants

* Fix various issue with AFHDS3 and NV14/EL18 internal module

* Fixed S.PORT unit tests

* fix: update widx after writing at current index

* fix: init error condition

* Fix: possible infinite loop in _find_port()

* Add support for bidir S.PORT init

* Add support for "getLastByte" in HW serial driver

* PXX1: Add support for S.PORT based on IDLE callback

* Fix rebase error

* Fix softserial _rx_fifo_push()

* Add softserial support for waitForTxCompleted()

* Fix MPM flashing (internal / external)

* Fixed external MPM

* Activate RX DMA on internal module

Seems to work with serial passthrough without issues, at least on the L3R PRO.

* Fix softserial DMA on stdlcd F4 targets

* Add softserial support for 32bit timers (mostly TIM2)

* More precise soft-serial

* Fix MPM update using inverters & HW uart

* Raise S.PORT DMA/USART IRQ prio to achieve faster switching to input

* Remove useless delays

* Fix flashing external ELRS module

* Added a retry mechanism for FrSky S.PORT update

* Remove useless enableRx()

* External FrSky modules are all flashed via S.PORT

* Remove power management unit update

This was only used on the first batch of X-lite.
2023-02-09 19:44:32 +10:00
philmozandGitHub 7a1231753a feat(color): Change global variables layout to better match other pages (#3116)
* Change global variables layout to better match other pages.

* Move internal classes for global variable page from .h to .cpp file. Convert header text in edit page to StaticText object and remove 'paint' function.

* Fix build error.

* chore: Formatting
2023-01-28 12:28:18 +10:00
Raphael CoefficandGitHub acd95dfad4 fix(B&W): Avoid having constants in SRAM (#2993)
fix constness to avoid having constants in data segment 
.... and thus free some precious RAM
2023-01-18 20:12:35 +10:00
3djcandGitHub bc8087cbf1 feat: Add Radiomaster Boxer (#2877)
* Radiomaster Boxer

* chore: Add Build system bits

* chore: `EEPROM_VARIANT` no longer used
2022-12-31 16:45:09 +10:00
philmozandGitHub a1c55a5b02 chore: Cleanup some compiler warnings (#2864) 2022-12-16 10:24:28 +10:00
Raphael CoefficandGitHub b74cf8b711 fix(color): channel values in LS (#2659)
Fixes #2613
2022-10-31 20:06:57 +10:00
Raphael CoefficandRaphael Coeffic 731d1834e3 More compact views for inputs, mixers and outputs 2022-08-28 13:07:03 +02:00
XINGandPeter Feerick 299991bc11 Add iFlight Commando8
Add iFlight Commando8 ELRS radio
2022-08-16 18:44:57 +10:00
3djcandPeter Feerick 6010eff024 TX12MK2 initial (external issue with MPM) 2022-07-20 13:01:31 +10:00
Raphael Coeffic 5319648e04 fix(compilation): another attempt... 2022-06-12 11:48:34 +02:00
Raphael Coeffic f35f6de75d fix(compilation): BitmapBuffer is only available with libopenui 2022-06-12 11:37:25 +02:00
Raphael Coeffic 0f60134dd5 fix(logical switches): fixed "ddd" 2022-06-12 11:31:48 +02:00
Raphael CoefficandRaphael Coeffic c418758863 getGVarString: boundary check 2022-06-11 15:38:08 +02:00
Raphael CoefficandRaphael Coeffic 86c72e3a2a Mixers rework 2022-06-11 15:38:08 +02:00
Raphael CoefficandRaphael Coeffic 99ed405b84 fix: switch display 2022-06-11 15:38:08 +02:00
Raphael CoefficandRaphael Coeffic cf06efea87 Taranis 128x64 2022-06-11 15:38:08 +02:00
Raphael CoefficandRaphael Coeffic 56bec5ca3a WiP: String arrays for translations
DE, EN, FI, FR are done, now we need all the other languages
2022-06-11 15:38:08 +02:00
Raphael CoefficandRaphael Coeffic ee0c37157d Remove legacy fonts and make the bootloader compile with LVGL 2022-06-11 15:38:08 +02:00
Raphael CoefficandRaphael Coeffic 30e3ac3399 Basic utf8 support for B&W radios 2022-06-11 15:38:08 +02:00
kevinkoenigandRaphael Coeffic 751d1a0887 cleanup of all number edit display handlers. 2022-06-11 15:38:08 +02:00
Raphael CoefficandGitHub ddf011ff12 fix: Remove offset when copying timer name (#1832)
Resolves #1816
2022-04-15 18:55:29 +10:00
BatambatamandGitHub 9d27a6923c fix: Display FS switch names and symbol (#1804) 2022-04-05 21:17:28 +10:00
WilhelmandGitHub 5e6cf2e79c fix: Custom stick and switch names were being mangled internally (#1770)
* followup to PR1754

* Cleanup

* Formatting

* Long comment
2022-04-01 14:16:01 +10:00
WilhelmandGitHub c14417a325 Try to fix use of unterminated strings in mixer setup (#1317) (#1338)
* fixes the non-terminated fixed-string problem in lua-mixer-script
added some useful info to the script-line
make the popup menu to delete a script

* removed unneccessary comments

* intermediate fix

* tried to obey all comments to the code
and to eliminate further potential buffer-overflows

* fixed typo

* fixed async loading of lua scripts and update of widget
cleanup

* removed GCC pragmas (clang warn about them)
remove constexpr qualification (gcc accepts them because gcc-builtins are already constexpr, clang still warns about them)

* removed merge marker
2022-03-23 12:40:06 +01:00
Raphael CoefficandPeter Feerick 09c49e24ee Remove SKY9X target 2022-01-29 14:40:17 +10:00
d41855a316 [TX12] Fix support for additional switches (SI and SJ) (#1303)
* Fixed support for Radiomaster TX12 additional switches (SI and SJ)

Two connectors are present on TX12 main board (near top of internal TX module) and are mapped as SI and SJ, but were not read out by the firmware.
With this update they might be used for some further hacking of the radio (ex. adding additional 2-pos switches, adding detector of external module insertion etc.).

* Radiomaster TX12 - preventing selection of Si and SJ as 3POS

* Radiomaster TX12 - corrected SI and SJ switch names in Keys Debug screen

Switches were displayed in test screen as SG and SH, due to fact that firmware did not take into account no presence of SG and SH in TX12.
The update provides correct and consistent naming of the additional switches across whole radio.

* Alignment tweak + fix rot_enc info overlap

Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
2021-12-30 15:49:23 +10:00
3djcandRaphael Coeffic d31482c18b Introduce T-pro and function switches handling 2021-12-17 17:07:48 +01:00
3djcandRaphael Coeffic 6735a42b08 Radiomaster Zorro
Port of opentx/opentx#8791
2021-12-17 15:17:48 +01:00
Raphael Coeffic 710677a1f7 Use existing function to generate switch name in YAML switch warning field 2021-12-17 11:02:51 +01:00
Raphael Coeffic 68bdf025c1 Fixed switch position warning display on B&W 2021-11-10 11:07:01 +01:00
eshifriandGitHub 4e571c1325 Improvements to time and timer display #911 (#912)
* Fix time display #911

* move TIMEHOUR definition

* change time format

* Refactoring

* rename

* remove unncessary code

* Change hour/minute format

* pack TimerDisplayOptions structure
2021-10-25 12:36:16 +11:00
520eac3e4f Format times better for timer widget and statistics times (#896)
* Fix widget timer.
Modifie getStrString() for  using hms

* Timer over blink with COLOR_THEME_WARNING
Timer unit in uppercase

* Use lowercase unit with small timer display, use uppercase unit in large
display

* Auto formatting

Co-authored-by: Runsys16 <rene.negre@orange.com>
Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
2021-10-15 21:32:24 +11:00
f970ab1e66 Fix Lua Mixer Scripts source naming (#842)
* getSourceString() return a correct string for lcdcolor when the source
es a LUA script

* getSourceString() return a formated string with instanceName or
scriptName and outputName

Co-authored-by: Runsys16 <rene.negre@orange.com>
2021-10-05 21:30:20 +11:00
rotormanandRisto fc2142ec78 Changed uniformly to EdgeTX boiler plate (also added boiler for files that were missing it). 2021-10-02 14:22:01 +02:00
eshifriandGitHub 88b8ac86fb [Colorlcd] Support model notes with spaces and prevent radio crash due to filename (#645)
* support both versions of model notes file name. Fix for #641

* Adding support for names with spaces

* Fix compilation
2021-09-02 10:45:58 +10:00
Raphael Coeffic 6d11fa8033 [lua] Fix sensor max and min matching
Resolves #442
2021-07-14 08:45:00 +02:00
Raphael Coeffic d10563d08b Fixed more zchar / string copy errors
Resolves #224
2021-06-16 18:00:42 +02:00
Raphael CoefficandRaphael Coeffic 6d490bddf0 Sensors don't use ZCHAR in 2.4
Resolves #97
2021-06-02 11:19:11 +02:00
Raphael CoefficandRaphael Coeffic 3d9b01745e Fix compiling for slider-less radios 2021-05-26 23:23:04 +02:00
Raphael CoefficandRaphael Coeffic d70ac14832 Display analog names properly
Resolves #91
2021-05-26 23:23:04 +02:00