Skip to content
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

Added crsf-shot #1018

Merged
merged 1 commit into from
Jan 8, 2022
Merged

Added crsf-shot #1018

merged 1 commit into from
Jan 8, 2022

Conversation

phobos-
Copy link
Contributor

@phobos- phobos- commented Nov 13, 2021

Implementation is based on opentx, tested with ExpressLRS hardware.
Before - packet rate is stuck at 250 packets per second.
After - packet rate depends on the settings and varies from 25 to 500 per second.

Tested with T8SG V2 plus, builds for T8SG V2 and T8SG V2 plus attached below.
deviation-t8sg_v2_plus-v5.0.0-f04bc27.zip
deviation-t8sg_v2-v5.0.0-f04bc27.zip

@howels howels mentioned this pull request Nov 26, 2021
@dat-alex
Copy link

dat-alex commented Nov 27, 2021

Thanks howels for the link ;)
@phobos I tried this with my HM elrs 2.4 trying to fly my modified mobula 6HD with new elrs 2.4 aio FC with no success!!
The fw on TX is elrs1.1 and I get blank line in CRSF menu on my T8SG plus. I have tried everything ,any help ?

Thank you
Alex

@howels
Copy link

howels commented Nov 29, 2021

Thanks howels for the link ;) @phobos I tried this with my HM elrs 2.4 trying to fly my modified mobula 6HD with new elrs 2.4 aio FC with no success!! The fw on TX is elrs1.1 and I get blank line in CRSF menu on my T8SG plus. I have tried everything ,any help ?

Thank you Alex

Have you tried the 2.0 TX firmware? This changes how the CRSF menu works. 2.0 RC3 is the latest current eLRS version.

@dat-alex
Copy link

dat-alex commented Nov 30, 2021

Thanks howels for the link ;) @phobos I tried this with my HM elrs 2.4 trying to fly my modified mobula 6HD with new elrs 2.4 aio FC with no success!! The fw on TX is elrs1.1 and I get blank line in CRSF menu on my T8SG plus. I have tried everything ,any help ?
Thank you Alex

Have you tried the 2.0 TX firmware? This changes how the CRSF menu works. 2.0 RC3 is the latest current eLRS version.

I suppose I have to try2.0 RC3 with original deviation nightly builds or phobos deviation-t8sg_v2_plus-v5.0.0-f04bc27.zip above ?

@harlock00999
Copy link

Hi guys,

I just upgraded my T8SG V2 Plus with this FW ver and my HGLRC TX + HM EP2400rx with ELRS 2.0 and everything is working on the bench, menu is on place, options are selectable and drone is arming! ^__^

I'm very happy! Hope to do some flying tests asap, in the meantime thank you all and happy flying !!!

@harlock00999
Copy link

Almost forgot : thanks to @StonedDawg for the link!!!

@dat-alex
Copy link

Hi! after I tried every single combination on my Jumper T8SG V3 plus the combination that did the trick was new ELRC 2.0 RC3 on Tx and original deviation fw (nightly build) deviation-t8sg_v2_plus-v5.0.0-c84450e on Jumper.
This involved in installing new 2,0 fw on my Happymodel Aio 24ELRS FC ,too but everything is working smooth now.
Now I have ELRS on my HM 65HD whoop!

Thank you all for your help.

@phobos-
Copy link
Contributor Author

phobos- commented Jan 4, 2022

@goebish @vladislavy @TheRealMoeder @hexfet this PR has been tested by me (and others) for over two months now, no issues found and the code is pretty simple. It will benefit Crossfire as well as ExpressLRS users. Any chance you could take a look and review this PR so that we can hopefully merge it? 😇

@harlock00999
Copy link

I'm not sure if this can help but I noticed a strange behavior trying the model match function.
Did anyone test this particular option on T8SG v2 Plus?!

Copy link
Contributor

@hexfet hexfet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! Looks good to me. I'll test a bit this weekend.

src/crsf.h Outdated Show resolved Hide resolved
@phobos-
Copy link
Contributor Author

phobos- commented Jan 5, 2022

@harlock00999 unfortunately model match is not something that deviationTX supports, nor is it a part of this pull request. From my experience if you enable model match feature in ExpressLRS you'll get an ID of 0. If you disable it it will go back to 255 which is OFF.

@harlock00999
Copy link

@phobos- Didn't mean to go off topic, sorry. Thank you for your answer.

src/protocol/crsf_uart.c Outdated Show resolved Hide resolved
@hexfet
Copy link
Contributor

hexfet commented Jan 6, 2022

I'm curious if there's a reason the telemetry "offset" value is not being used to align the packet sends with the TX module? In opentx this happens in ModuleSyncStatus::getAdjustedRefreshRate().

@phobos-
Copy link
Contributor Author

phobos- commented Jan 6, 2022

@hexfet DeviationTX has it's own mechanism for sync - mixer_runtime. If I combine the two, or use offset from the module instead of DeviationTX mixer_runtime it doesn't work that well - offsets are optimized for opentx processing times, deviation is much faster. Example in ELRS codebase: https://github.com/ExpressLRS/ExpressLRS/blob/cc1273f28598164a50f4173a7353e878e2ca3b2f/src/lib/CRSF/CRSF.cpp#L343

@hexfet
Copy link
Contributor

hexfet commented Jan 6, 2022

@phobos- The mixer_runtime adjustment ensures the most recent possible stick data is used to create the next control packet (see #532). For protocols using internal radios where Deviation is synchronized with the receiver that's all that's needed.

When an external module is used it's the external module that's synced with the receiver, and for lowest latency the serial data sent from Deviation should arrive at the external module at the last possible moment before the module needs it for sending the next over-the-air packet to the receiver. I believe that synchronization is the purpose of driving offset to zero. Wish I had time to dig into ELRS to see how it's implemented there.

At the highest packet rate getting the offset to zero would shave an average of 1ms off the stick to receiver latency, so maybe not even noticeable. Anyway it's not a reason to delay merging this PR, which is definitely a step forward.

@howels
Copy link

howels commented Jan 7, 2022

Please do a merge when possible. Lots of us are flying this and it's great to see action in the deviationTX codebase.

@hexfet hexfet merged commit 26305f6 into DeviationTX:master Jan 8, 2022
@howels
Copy link

howels commented Jan 9, 2022

@hexfet can you trigger a new build on Travis-ci? The last one was 7 months ago.

@hexfet
Copy link
Contributor

hexfet commented Jan 14, 2022

Travis isn't free anymore. I've been fiddling with github actions but don't have a full solution yet.

@hexfet hexfet mentioned this pull request Feb 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants