-
-
Notifications
You must be signed in to change notification settings - Fork 344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable serial trainer for foreign protocols (SBUS improvements / CRSF / Ibus / SumD) #4102
base: main
Are you sure you want to change the base?
Conversation
For whatever reason, this just works, with some minor tweks. The open issue is, that the trainer data is processed in the 1ms timer interrupt handler, which needs to be changed. |
Probably a good idea to skim through the unresolved review points from #1462 also to see if they still apply or not ;) From my point of view, the only other outstanding issues were the lack of any documentation on how to actually use it or any limitations (i.e. hardware requirements), or what testing had been done - since it was adding support for four more serial trainer protocols. |
…lid sources (#3999) * fix: mixer lines with empty source Fixes #3367 * Fix color mixes display. --------- Co-authored-by: Phil Mitchell <[email protected]>
missing translation strings for all but german
(still missing other translations: strings/enum correspondance)
- fixed taranis radios
* let only one of the SBUS/IBUS chooseable (only one can fill the trainer inputs)
SUMD is still only stub
* moved the interfaces to header files * introduced option EXTENDED_TRAINER (32 trainer channels, switches for sumd) * introduced cli interface to get statistics for trainer input
* added code to disable BT-Module (put !EN-pin to high) when AUX2 is powered on * added some debug output (statistics of incoming packets) * added sumd V3 decoding of mode-command/sub-command * added lua functions to query the sumd V3 commands
* fixed wrong return value conversion
…ift / size problem
switch(mState) { // enum-switch -> no default (intentional) | ||
case State::Undefined: | ||
csum.reset(); | ||
if (b == Crsf::FcAddress) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please note that although ExpressLRS receivers currently output this as their first byte, it is incorrect CRSF and will be changed at some point. Correct CRSF starts with 0xC8 always (UART_SYNC
in the Crossfire units). Betaflight, iNav, ExpressLRS, EdgeTX and many other systems don't check the first byte or check it against a variety of values to validate the frame.
Also note there's a perfectly good CRSF frame parser already in pulses/Crossfire.cpp so it would be nice to not duplicate the code, and with different behavior between them.
I think ideally ExpressLRS would love to be able to send CHANNELSPACKED/SUBSETPACKED on its telemetry connection as well for use as a trainer or to forward headtracking data directly from the TX module's backpack into EdgeTX.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That last part sounds interesting
Fixes #1460
Resolves #1607
This is a copy of #1462, living in the EdgeTX repo, to not accidentally break stuff for @wimalopaan when we finalise this PR