feat: add support for a new "Master/Lua" trainer mode#7160
Open
Amigache wants to merge 6 commits into
Open
Conversation
Author
|
Companion integration done. |
Collaborator
|
Sounds like a painfully slow way of proceeding: you need 8 calls to perform a simple 8ch trainer channel data fill |
Author
Good observation. I've tried it on my TX16S and it works very well, but I think perhaps a method that maps all the channels at once, in a bulk operation, would be better, don't you think? |
…k channel updates
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new "Master/Lua" trainer mode to both the companion and radio firmware, enabling trainer input channels to be set via Lua scripts. The changes include updates to enums, translation files, YAML serialization, availability checks, and new Lua API functionality. The implementation ensures the new mode is only available when Lua support is present and provides proper initialization and stopping behavior.
Addition of "Master/Lua" trainer mode:
TRAINER_MODE_LUAto theTrainerModeenum in bothmodeldata.handdataconstants.h, updated related macros, and integrated it into YAML serialization tables for both companion and radio firmware. [1] [2] [3] [4]Trainer mode availability and translation updates:
Lua API enhancements:
setTrainerChannelsLua function, allowing scripts to set trainer input channels when in "Master/Lua" mode, and registered it in the Lua API. [1] [2]Trainer mode handling:
stopTrainerandcheckTrainerSettingsto properly handle the new "Master/Lua" mode, including resetting inputs and skipping hardware initialization. [1] [2]User interface and string updates:
Can work with this related proyect:
https://github.com/Amigache/BTWifiSerial/tree/develop