Commit Graph
4321 Commits
Author SHA1 Message Date
d77389d30b feat(color): LVGLify and enhance Logical Switches page (#3019)
* Update logical switch layout:
- Use LVGL flex / grid layout
- Same height for all buttons
- Display logical switch name inside button so entire row acts as button
- Consistent press handler for buttons (always show popup menu)
- Group buttons for empty switch in lines to utilise space
- Remember selected button and reselect after edit.

* Fix incorrect switch being selected when changing tabs.

* Fix selection of focussed button when using 'Clear', and switching tabs.

* Reorganise logical switch edit code.

* Change button style to match input/mixes/outputs pages.

* Single line overview on landscape LCD layout. Convert to using grid and lgvl objects for overview buttons.

* Remove redundant flag.

* Remove logic that tries to center scroll around selected button (not working).

* Remove empty buttons and add a single '+' button at the bottom to match inputs and mixes.

* Remove unused code.

* Correct string usage.

* Add long press handler for quick access to the '+' button functions.

* Display logical switch operation and parameters as an expression. Add 's' suffix to time values.

* Adjust spacing.

* Set V2 number edit control to automatically resize and fit content to prevent clipping of large values.

* Revert to fixed column layout.

* Adjust grid spacing.

* Convert the logical switch view in the channel monitor to LVGL flex.

* chore: Formatting

Co-authored-by: Phil Mitchell <phil.a.mitchell@gmail.com>
Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
2023-01-27 19:22:48 +10:00
Peter Feerick 7e026e2b49 chore: Remove redundant leftover from #3058 2023-01-27 19:20:11 +10:00
c739842c8d feat: Improve defaults, range and wording of SD Log SF (#3058)
* fixes https://github.com/EdgeTX/edgetx/issues/2965

Changes:
- the log period range is now 0.1s to 25.5s
- upon creation of a new SD Logs SF the period is initialized to 1.0s
- text "Value" is changed to "Period" to indicate parameter represents the log period

ToDo:
- translations for "Period" if desired

rebase due to #2992

* changed Period to Interval

Added translations for DA, DE, EN, IT, PL

* added defaults for TR_INTERVAL to language files

* fixed problem with too many leading zeros for intervals less than 1s.

before: 00.5s
after: 0.5s

* added CZ translations for TR_PERIOD and TR_INTERVAL

changed EN TR_FUNC from "Func" to "Function"

* updated TR_FUNC for CZ, DA, IT, JP, PL

updated TR_PERIOD and TR_INTERVAL for JP

* added TR_PERIOD,  TR_INTERVAL, TR_FUNC for SE

* implemented TR_SF_SWITCH and logic to change between TR_SWITCH and TR_SF_SWITCH

* 212x64 radios: single source for #define TR_LSW_HEADERS in language files

deleted redundant defines

* changed 128x64 and 212x64 SF SD Logs to same logic as colorlcd with

- minimum log interval 0.1s
- maximum log interval 25.5s
- default log interval 1.0s

TX12_Sim and X9D_Sim tested ok

* migrated functional changes due to PR #2992

* missed updating TW language file

* fix: Always `STR_SF_SWITCH` regardless of SF

Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
2023-01-27 18:33:31 +10:00
philmozandGitHub 2e00f6aec8 fix(color): Make "Add New" curve handling work more like SF (#3103)
* Make new curve handling work like special functions & logical switches - show popup of available curve slots.

* chore: Formatting, comment typo
2023-01-27 16:00:47 +10:00
Peter FeerickandGitHub 93865ba7b2 fix: B&W MPM protocol offset, subprotocol lists too long (#3112)
* fix: Off by one error for protocol list
* fix: Incorrect range for some Frsky subprotocols
2023-01-27 15:28:04 +10:00
Raphael CoefficandGitHub 57bf180a9b feat(mpm): remove FrSky special treatment madness (#3032) 2023-01-26 11:44:46 +10:00
Raphael CoefficandPeter Feerick 4c272863d3 fix: Prevent firmware overflow for X9D+2019
- Remove __global_locale
- Use same animation for startup and shutdown
2023-01-25 19:42:05 +10:00
philmozandGitHub d6af2387ac fix(color): Curve preview layout in model input edit view (#3099) 2023-01-25 10:49:03 +10:00
475ad1fb6f feat(ui): Improved Button/touch handling for throttle / switch alert screen (#3061)
* Button and touch handling for throttle / switch alert screen.

* Restore original touch behaviour for confirmation dialog.

* Add buttons for 'actions' at bottom of screen.

* Fix infinite loop that can happen in some instances.

* Remove the option for a long press on the touch screen to close the dialog. On screen buttons must be used to close.

Co-authored-by: Phil Mitchell <phil.a.mitchell@gmail.com>
2023-01-25 10:44:12 +10:00
philmozandGitHub 3d700f42f0 feat(color): Long press SYS on main screen for radio setup (#3092) 2023-01-25 10:19:56 +10:00
philmozandGitHub ee208275f2 fix(color): Center align text in number input boxes for curve editor (#3094) 2023-01-24 18:17:07 +10:00
philmozandGitHub 820a924e4f feat(color): Add long press handler for new model curves page (#3091) 2023-01-24 11:33:40 +10:00
philmozandGitHub c2dff941d9 fix(color): Close menu popup on main view when switching to other views (#3090) 2023-01-24 11:11:11 +10:00
philmozandGitHub 80f3cbe759 fix(color): Prevent multiple instances of the main menu popup (#3067) 2023-01-24 11:05:45 +10:00
philmozandGitHub 2d534a88cb fix(color): Fix infinite loop/crash with some uses of POPUP_WARNING/POPUP_INFORMATION (#3068)
Prevent infinite loop and crash if POPUP_WARNING or POPUP_INFORMATION are used from within code that is called from a 'Menu' line button.
2023-01-24 10:57:28 +10:00
philmozandGitHub 4a23f04844 feat(color): New model curves page layout (#3041)
* New curve page layout.

* Set scroll to selected curve.

* Cleanup.

* Add #define's for sizing. Show both curve number and name in title bar (if name is set).

* Remove unnecessary call to CurveEdit::SetCurrentSource. Use runtime size for layout where possible.

* Add comments

* Fix base layout position.

* Fix issue with button selection not working properly with scroll wheel.
2023-01-23 21:15:53 +10:00
philmozandGitHub 5503048e47 chore(color): LVGLify Special/Global Functions tabs (#2992)
* Convert Special / Global function page to flex layout.
Move function name text into row button so entire row acts as a button.
Display active functions first, then inactive functions as smaller buttons in a grid.

* Merge duplicate cases in switch, fix indentation.

* Keep selected button focussed after editing a function.
Add long press handler to jump between free and used functions.

* Revert to numerical order for functions list.
Use context menu for empty functions all the time.

* Fix parameter type and remove redundant lines.

* Fix incorrect function being selected when changing tabs.

* Fix selection of focussed button when using 'Clear', 'Delete' and switching tabs.

* Change button style to match input/mixes/outputs pages.

* Fix checked state display for buttons.

* Fix scroll position when adding new entries at the bottom. Center selected button after editing or changes to list.

* Remove logic that tries to center scroll around selected button (not working).

* Convert overview button to lvgl grid.
Display function as more readable expression instead of discrete values.
Single line display for overview button on landscape screen.
Fix display when editing GVAR INC/DEC value (was '--' instead of '-=').
Fix incorrect module displayed for 'Set Failsafe' (swapped).
Show all parameter and values for each function type in overview.

* Fix 'Enabled' indicator so it is not selectable with the scroll wheel and looks less like a radio button.

* Remove empty buttons and add a single '+' button at the bottom to match inputs and mixes.

* Add long press handler for quick access to the '+' button functions.

* Ensure addButton is initialised if not needed (list is full).

* Use formatNumberAsString helper function.

* Adjust grid spacing.

* fix: `STR_VALUE` not `STR_VOLUME`
2023-01-23 20:48:27 +10:00
eshifriandGitHub 8e8e78671a feat: Timer Voice & Haptic option, show elapsed speak time value when countdown (#2711)
* fix "odd" elapsed time announcement

* announce elapsed seconds

* Add support for "Beeps and Haptic" and "Voice and Haptic" for timer countdown.
2023-01-23 20:00:12 +10:00
15dca01f42 fix(color): Inactivity alarm suffix proper grammar (singular/plural) (#3064)
* Add translations for "minutes"

* Add missing PLURAL2

* fix grammar

* Next attempt

* include limits.h

* minor cleanup

* Addin some translations for some languages based on inputs

* chore: Remove BREAKSPACE, add ignore flag
And some minor cleanup / formatting

* chore: Revert `TR_USE_VARIABLE_PLURAL`
Use `TR_USE_SINGULAR_IN_PLURAL` properly... thanks @eshifri

Co-authored-by: eshifri <eshifri@hotmail.com>
2023-01-20 12:07:08 +10:00
philmozandGitHub fd04f4a257 chore(color): Cleanup header title display logic (#3059)
Use 'Page' class 'header' property to display title where possible, instead of creating a new object.
2023-01-19 11:18:58 +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
philmozandGitHub fa4e6d795c fix(color): Update of Edge LS v1-part2 when v1-part1 when editing (#3049) 2023-01-17 15:11:01 +10:00
philmozandGitHub 0610449c82 fix(color): Crash on inputs/mixes pages mixes/expos limit reached (#2985) 2023-01-17 13:28:53 +10:00
philmozandGitHub dca52c4ae5 fix(color): Update top bar date & time when in setup pages (#3037) 2023-01-15 12:06:18 +10:00
3djcandGitHub 8ee73a5800 fix(lua): Remove faulty carryTrim, replace with trimSource (#2995)
* Fix carryTrim in LUA

* Remove carryTrim
2023-01-15 11:54:57 +10:00
MichaelandGitHub 34ea422e39 chore: freeRTOS task stack diagnostics (#2976)
* migrated stack diagnostics (available, free) to using built in FreeRTOS builtin function

Note: main stack must be and is treated differently as it is not under FreeRTOS control. main stack is painted by the STM32 startup routine. free main stack is calculated checking the remaining painted stack area.

* corrected my merge error

* missed a blank
2023-01-15 11:48:04 +10:00
philmozandGitHub cb9f411036 fix(color): Invalid custom curves + layout updates (#2973)
* Layout updates and bug fixes for curve editor.
- Fix issue 2972 where an invalid curve could be created
- Use vertical layout or list of points
- Add border to preview to better show end points
- Fix issue where preview was redrawn very frequently
- Better organisation of curve edit classes

* Fix to refresh curve preview on input edit page when parameters changed.
2023-01-15 11:23:40 +10:00
philmozandGitHub dd8ab3037f fix(ui): Adjust model setup button layout to better fit portrait screen (#2956)
* Adjust model setup layout to better fix on portrait LCD screen.

* Set buttons to fixed width and allow to grow vertically to fit text.

* Cleanup layout logic - buttons stretched horizontally, centered vertically.
2023-01-15 10:40:40 +10:00
Malte LangermannandGitHub ea9dfa0a36 chore(ui): Convert GVAR tab to LVGL (#2945) 2023-01-15 10:27:35 +10:00
eshifriandGitHub 346ac3ce51 fix(color): Precision for V2 in TIMER LS (#2969) 2023-01-01 13:58:39 +10:00
Peter FeerickandGitHub 539b407b58 feat(color): Confirm before duplicate or saving model as template (#2931)
* fix(color): Confirm before duplicating model

* fix(color): Confirm before saveAsTemplate
2023-01-01 11:50:18 +10:00
philmozandGitHub 655aa42c6f fix(color): More consistent button colors, GV buttons checked/pressed (#2944)
Make ButtonMatrix button text color behave like TextButton for flight modes and pre-flight checks.
Show 'GV' button as checked if corresponding input value is a global var.
2023-01-01 11:30:12 +10:00
eshifriandGitHub 7e503e823e fix(color): 6POS on main view not always redrawn when changed (#2947) 2023-01-01 11:22:58 +10:00
philmozandGitHub 943b1e7cd0 fix(color): Fix single widget layout size, improve code readability (#2962) 2023-01-01 11:11:59 +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
277c1cae37 fix(color): Clear Lua lcd buffer and display 'Loading...' (#2916)
* Clear LCD buffer before use for standalone Lua scripts.

* Fix rebase merge issues.

* Add translation.

* Add translation.

* Add translations.

* Add translation/

Co-authored-by: Phil Mitchell <phil.a.mitchell@gmail.com>
2022-12-28 10:15:10 +10:00
philmozandGitHub 919b83af42 fix(ui): Ignore hidden file when iterating SD card contents (#2925)
* Ignore hidden file when iterating SD card contents.

* Fix compile error.
2022-12-23 11:18:00 +10:00
philmozandGitHub f8f2258a79 fix(ui): Update flight mode color on startup/theme edited/theme changed (#2928) 2022-12-23 11:08:22 +10:00
philmozandGitHub 3f08af6120 feat(color): Quick Model Select, keep active model in view when changing labels (#2895)
* Fix rebase merge issue.

* Incorporate solution from @ParkerEde in PR #2626

* Fix selection logic for models.

* Select model on first press.

* Fix quick model selection when using scroll wheel & enter button.
Add setting to enable quick model selection.

* German translation.

* Fix behaviour when 'model quick select' is off to work like existing 2.8 logic.

* Add translations.

* Prioritise active model as selected model when the set of visible models changes.

* Fix selection ordering when using scroll wheel.
Minor code cleanup.
2022-12-23 09:58:49 +10:00
MichaelandGitHub c099a74da4 fix(color): Center flight mode text and 6Pos numbers (#2893)
* centers flight mode text, 6Pos indicator and 6Pos numbers in square

replaces ticks with numbers in 6Pos indicator

* stole @philmoz idea to bold the selected switch position to make it stand out more
2022-12-23 09:42:58 +10:00
MichaelandGitHub 21f686ee9b fix(color): Ouputs tab wrong value used for min/max highlighting (#2926) 2022-12-23 09:40:01 +10:00
philmozandGitHub 8eb55452a5 fix(color): Display of model notes when selecting model (#2922)
* Fix display of model notes when selecting model.
Fixes issues 2722 and 2921.

* Move view close code as suggested by @pfeerick.
2022-12-22 19:01:29 +10:00
philmozandGitHub da5d056257 feat(ui): Improvements to color picker (#2909)
* Revised color picker:
- add title to popup window
- add Save and Cancel buttons
- Source value only updated when 'Save'' button pressed
- Add editor to select from system theme colors

* Center 'Cancel' and 'Save' buttons, make them both the same size and fill available space.
Reduce width of dialog box on portrait screens.
2022-12-22 18:47:26 +10:00
eshifriandGitHub 458dc049e5 fix(color): Source selection for curve display (#2894) 2022-12-21 21:50:53 +10:00
philmozandGitHub 866716b708 fix(color): File handle leak in theme manager (#2911) 2022-12-20 21:52:16 +10:00
philmozandGitHub 4841f0673c fix(ui): 'Add trims to subtrims' btn on the Outputs page wasn't updating display 2022-12-20 20:56:12 +10:00
philmozandGitHub 37779a5aaf feat(ui): Change dialog background color to make buttons more visible (#2903)
* Change background colour of the ConfirmDialog box to make the buttons more visible.

* Change background colour of the ColorEditorPopup box to make the buttons more visible.
2022-12-20 08:52:12 +10:00
philmozandGitHub 73e240f365 feat(color): Natural number sort order for SD card file browser (#2870) 2022-12-18 14:59:13 +10:00
philmozandGitHub 0be85bbad1 fix(color): Restrict time/date to valid values, check for changed values before updating screen (#2884)
* Fix RTC date editing to limit day max value to actual number of days in the selected month.
If month or year is updated check that day value is still in range, if not update day to max value for selected year and month.
Only update UI values that have actually changed.

* Use struct assignment instead of memcpy to initialise property.
2022-12-18 14:40:31 +10:00
Malte LangermannandGitHub 2b00583f46 fix(ui): Check object exists access before accessing it (#2886) 2022-12-18 12:21:30 +10:00