-
-
Notifications
You must be signed in to change notification settings - Fork 347
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 (Ibus/SumD) #1462
Conversation
SumD not yet implemented because updated SJ receiver can output SBus. |
@wimalopaan considering what has been done in #1089, we should probably revamp this code on top of main once #1089 is merged, and add a parameters to choose the protocol, don't you think? or even better, make some sort of auto-detection if possible. |
Yes! Is it now possible to receive the serial inverted, so that a user simply can feed in the (inverted) Sbus-Signal of some arbitrary RX with Sbus-Out? |
Actually trying to rebase this |
You will have some fun, it has changed a bit ;-) you might be luckier with just cherry-picking your commit on top of current main. |
7adf049
to
77fda50
Compare
So have you noticed yet that if you power on the radio (TX16S) with either SBUS, IBUS or CRSF trainer options selected the radio locks up at the splash screen? 😁 SUMD seems to be immune to this new feature ;) |
Yes, I can reproduce that. Can you try the same with LUA-mode enabled? Does that lock up the radio too? Thanks for testing. |
Requires #1742 |
Do you mean as in the LUA option in the serial port menu? If so, no, that didn't lock up. It was only the SBUS, IBUS and CRSF trainer options that locked up. telemetry mirror was fine, telemetry in was fine, and I've used GPS and CLI before without issue. For what it's worth... SBUS trainer in main (i.e. 2.7.0rc1) doesn't lockup when the SBUS trainer option is ... but I'm sure Raphael will enlighten us more as to what's happening... I'm going to bet on trying to access a timer that's not ready yet... |
I think Lines 49 to 59 in 78dc293
should return But I think the return type should be I think that this is a flaw of serial rewrite and should be fixed there first ... |
The last change fixes the freeze problem at least on my radio. |
... I forgot to change the code for the taranis radios ... |
* 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
DA translation #define TR_AUX_SERIAL_MODES "FRA\0 ""S-Port spejl\0 ""Telemetri\0 ""SBUS træner\0 ""IBUS træner\0 ""CRSF træner\0 ""SUMD træner\0 ""LUA\0 ""CLI\0 ""GPS\0 ""Debug\0 " |
CZ translation: #define TR_AUX_SERIAL_MODES "VYP\0 ""Telemetrie zrcadlení\0 ""Telemetrie vstup\0 ""SBUS Trenér\0 ""IBUS Trenér\0 ""CRSF Trenér\0 ""SUMD Trenér\0 ""LUA\0 ""CLI\0 ""GPS\0 ""Debug\0 " |
closing, because this is replaced by #4102 |
WIP for #1460
still limitations: