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

Telemetry issue with multiprotocole module and Spektrum receiver #3326

Closed
amaury10 opened this issue Jan 26, 2024 · 54 comments
Closed

Telemetry issue with multiprotocole module and Spektrum receiver #3326

amaury10 opened this issue Jan 26, 2024 · 54 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@amaury10
Copy link

Hello,

I have missing sensors in the telemetry when using a multiprotocole module and a Spektrum receiver.
I see only receiver related telemetry (RxBatt, RSSI, Frame losses, ...) but no external sensors (LiPo voltage, altimeter, ...)
I test it with both an AR6610T with internal altimeter and AR8010T with external altimeter : they behave the same.

Also when binding the multiprotocol it keeps stuck in the binding popup whereas it should exit properly when telemetry is received (as explained in the MPM documentation). In addition, it's not possible ti bind in Auto mode as it relies on telemetry.

I'm running EthOS 1.5.0 RC1 on TANDEM X18 with an iRangeX iRx4 Lite MPM.

I can't find the information about the precise list of supported telemetry message on MPM, but it seems that OpenTx has lua scripts to handle additionnal sensors.

Regards.
20240126_073703

@bsongis-frsky bsongis-frsky added the enhancement New feature or request label Jan 26, 2024
@MikeAg03
Copy link

MikeAg03 commented Feb 1, 2024

I can't seem to get any to show up... what extra did you install for Multimodule/spektrum telemetry to show up at all?
I have 1.5 RC1 installed.

@bsongis-frsky
Copy link
Collaborator

bsongis-frsky commented Feb 1, 2024

The script has been modified for 1.5.0 (there is a branch for that in this repository)
It will be modified again soon to benefit from all the options which are available

@RealTadango
Copy link

The script has been modified for 1.5.0 (there is a branch for that in this repository) It will be modified again soon to benefit from all the options which are available

Do you mean the multi lua? That is not different from the main version. What modified script do you mean? I see crossfire is updated but not the multi one.

@RealTadango
Copy link

@bsongis-frsky Where is this modified multi lua script? The 1.5.0 branch has the same as main for multi. Some other scripts are updated already. Or is there no updated multi script yet and have i misunderstood your post?

@MikeAg03
Copy link

Yeah, I don't see an updated script for multi yet... Any updates on this?

@bsongis-frsky
Copy link
Collaborator

bsongis-frsky commented Feb 28, 2024

I was wrong, the script does not need any modification for 1.5.0

It willl need modifications for 1.5.1 where I bring new options with different types (not only numbers):

For example DSM2:
image

Or another protocol with "Bind on channel":
image

Those features are implemented and ready to test, but I don't have the needed hardware to do the tests, I have only added all the sensors I could test by myself.

I plan to push the PR as soon as 1.5.0 is out, so that the whole feature can be tested with the nightlies.

@bsongis-frsky bsongis-frsky self-assigned this Feb 28, 2024
@bsongis-frsky bsongis-frsky added this to the 1.5.1 milestone Feb 28, 2024
@RealTadango
Copy link

RealTadango commented Feb 28, 2024

So extra sensors won't be available in the 1.5.0 release initially?

@rwijnhov
Copy link

@bsongis-frsky ask Mike Blanford he implemented it for me like 6 months ago in Ersky, he defenetly knows how to. Also see atached the spektrum documentation on the sensors.
SPM_Telemetry_Developers_Specs.pdf

@amaury10
Copy link
Author

I was wrong, the script does not need any modification for 1.5.0

It willl need modifications for 1.5.1 where I bring new options with different types (not only numbers):

For example DSM2: image

Or another protocol with "Bind on channel": image

Those features are implemented and ready to test, but I don't have the needed hardware to do the tests, I have only added all the sensors I could test by myself.

I plan to push the PR as soon as 1.5.0 is out, so that the whole feature can be tested with the nightlies.

Hi @bsongis-frsky,

Very good news.
Let us know as soon as it's ready for testing. We'll do it with pleasure :-)

@bsongis-frsky
Copy link
Collaborator

I have no problem with the implementation. The problem is testing as I don't have the needed hardware

@bsongis-frsky
Copy link
Collaborator

I can add 3 new sensors (RPM / VOLTS / TEMPERATURE), in 1.5.0 provided somebody pings me on Discord to have a test.
I won't add the options as it means more changes and I don't want to take any risk with the release.

@rwijnhov
Copy link

@bsongis-frsky I pinged you on discord I can test.

@bsongis-frsky
Copy link
Collaborator

Thanks, working with Tadango first. Which sensors are you missing?

@rwijnhov
Copy link

rwijnhov commented Feb 29, 2024

@bsongis-frsky
I am missing
telemetry from the ESC:
RPM
Voltage (FASV)
Current (Amps)
BEC temperaure (TEMP2)
BEC current (SBCA)
BEC voltage (SBCV)
AccX, AccY and AccZ

MIke blanford figured out for ERSKY
Type 5 - unknown (reserved in the Spektrum document)
Type 20 - Gforce
Type 26 - Gyro
Type 30 - unknown
Type 32 - ESC
Type 126 - RPM, Volts and temperature
Type 127 - Status A,B,L,R, Fades, Holds and receiver voltage

126 is the Receiver/TM1000 voltage sensor (and other sensors). In Spektrum land if 32 is present duplicate values in 126 are ignored (so you can't monitor the motor pack and another pack with the voltage sensor port).

The Tx should be able to calculate the mAh used by integrating the current value over time, but I see I have this code missing, I'll get it added (Mike said) To use this, go into the Telemetry menu and select "Fas" as the current source. The mAh sensor value will then show consumed capacity.

My tx16s used ecur for mah reading with spektrum

I believe @RealTadango doesn't have an esc with current reading? So I can test that for you. I just hit you up yersterday on discord.

This is all the info i have available. I also atached the raw logfile of ersky that sniffed all my dsm sensors that should help.
Dsm log ersky.zip

@RogerRamjet21
Copy link

I just loaded 1.5.0 on my X18S. I have the IRange IRX4 Lite and a Horizon Hobbies Cub S I fly from time to time. After 1.5.0 installed, still no RSSI (or any other telemetry when doing discovery). Should this be working now?

@RealTadango
Copy link

I just loaded 1.5.0 on my X18S. I have the IRange IRX4 Lite and a Horizon Hobbies Cub S I fly from time to time. After 1.5.0 installed, still no RSSI (or any other telemetry when doing discovery). Should this be working now?

The should showup when discovering sensors. That do you get as sensors?

@RogerRamjet21
Copy link

I get no sensors at all when setting discover to yes.

@RealTadango
Copy link

I get no sensors at all when setting discover to yes.

Try restarting the TX. I noticed sometimes the iRX4 does not fully start and provides no sensors.

@RogerRamjet21
Copy link

Will do in a few minutes when the RX battery is charged enough. In the meantime, looking at the main.lua script for the mult-module, I see telemetry entries for Cabell, Flysky and OMP protocol's, I do not see an entry for spektrum nor do I find a later version of the lua script. Is what I see correct or is there an newer version of the script available?

@RealTadango
Copy link

Will do in a few minutes when the RX battery is charged enough. In the meantime, looking at the main.lua script for the mult-module, I see telemetry entries for Cabell, Flysky and OMP protocol's, I do not see an entry for spektrum nor do I find a later version of the lua script. Is what I see correct or is there an newer version of the script available?

Nothing has changed in the multi lua.

@RogerRamjet21
Copy link

Ok, give me a few minutes of charging time and I'll try what you have suggested and report back.

@rwijnhov
Copy link

rwijnhov commented Mar 3, 2024

Rssi not working is a bug,.rest should work.

@RogerRamjet21
Copy link

Thanks for that. Not sure the Cub S returns anything other than RSSI, so may just have to wait until the RSSI is fixed. Thanks!

@Quimb0
Copy link

Quimb0 commented May 25, 2024

Hello everyone, we have news of new data from sensors such as vario or altimeter, thank you

@bob01
Copy link

bob01 commented Sep 8, 2024

Greetings
Discover sensors does not find the GPS - AR637T Rx.
X20RS/v1.5.15 w/ iRx4 lite.

Same model was prev bound to Tx16s/EdgeTx 2.10.4 which recognized the GPS.

Happy to test / provide any other info

@bsongis
Copy link
Contributor

bsongis commented Oct 9, 2024

@frankiearzu Thanks for your proposal! Would you contact me on Discord? Have you tried the latest Ethos 1.5 nightly?

@robthomson
Copy link
Collaborator

Glad to see this moving forward

@BennyBreman
Copy link

Hello, i haven't try the 1,5 nightly. I wait for the 1.5.16

@frankiearzu
Copy link

frankiearzu commented Oct 12, 2024

Just played with the 1.5.16 pre-released, using an AR637TA Smart RX + Avian ESC to get ESC/Batt telemetry,
as well as an FC6250HX (heli) with Smart ESC and Smart Bat.

Just a bit of background.. most of the Spektrum Telemetry frames carry many sensors, and are grupped based on what is needed in a single telemetry screen.. the frame data match the screen data. For example, the ESC frame has all the different data related to ESC telemetry screen.
In OpenTX/EdgeTX/Ethos the philosophi is to have this individual sensors, and let the use group them as needed with widgets.

This difference creates a challenges in our side: Sometimes, the same sensor data is sent of different frames types, creating duplicates sensors. For example, Batt V can come in the Flight Pack Frame and ESC frame.. What we did in EdgeTX is to detect if we are getting an ESC frame, and ignore the BattV comming from the Flight Pack sensor. Otherwise you end up with two "A3" sensors with the same value. Another example is with the Vario Frame and Altitude Frame.. Vario has "Alt" and "VSpd", and the Frame ALT only have altitude.. but the RX sends both frames, so you end up with two "Alt" sensors. LemonRX G2 receivers do send a lot of the same data on multiple frames when you have their Current or Voltage sensor attached, creating many duplicates.. but the same thing happen with genuine Spektrum when you have the Smart ESC and the Flight Pack monitor sensor connected (Current, Volts, Temperature, Battery Usage mAh).

There are some frames who has unrelated data, just to match the data on a screen.. for example, there is a frame who has RPM, Temp, and Batt Volage.. The Batt Voltage is populated, but the if you don't have the RPM or Temp sensor, it will come with NoData constant.

General comment:

  • Should the ID of the Sensor be the same for all the sensors comming in the same Frame?? In OpenTX/EdgeTX is the FrameId concatenated with the ByteOffset to make them unique.
  • Spektrum sends NoData (like 0xFFFF or 0x7FFF) when the sensor is not connected, should we populate the screen during "Discover sensors" with non-existing sensors? OpenTX/EdgeTX ignore them, so they will not show up on the screen.

Summary of my Test:

_TX RSSI (0-31).. populating the Radio/Power strenght graph with very low RSSI and warnings... the internal RSSI in OpenTX/EdgeTX is this RAW value * 3 to get it 93 that is close to 100.. Ideally should be multiplied by 3.22.
OpenTX/EdgeTX TRSS is this sensor, and RSSI is populated with TRSS * 3 _

Frame 0x7E (126) RPM/V/Temp

  • RPM is showing 65535 that is NoData (0xFFFF).. probably should be ignored.
  • A3 showing as ---, coming with NoData. probably should be ignored.
  • Temp2 showing as ---, coming with NoData probably should be ignored.

Frame 0x7F (127) QOS
I think the range for Fades is not correct 0-100 and 0-200.. Antena fades/losses can be in the 1000s in a bad connection.

  • RxA fades is OK
  • RxB,
  • RxL. this was showing 100... but the RAW value is 6250 (0x186A) on the Heli FC model# (with Heli RX).. Probably due to the Range 0-100
  • RxR fades shows with "---" (NoData), this RX don't have the extra antennas, proably should be ignored when NoData.
  • RxBatt is OK

Frame losses and Holds is OK. NOTE: is a UINT16, so NoData is 0xFFFF, but some receivers also send 0x7FFF (no-data for signed).. so in EdgeTX, ignoring both.

Frame 0x20 (32) ESC

  • ESC RPMs is showing values who are too small.. It needs the x 10 in the documentation ("RPM, 10RPM (0-655340 RPM)")
  • ESC Volage OK
  • ESC Temp OK
  • ESC Current OK
  • BEC temp, current, volatage has NoData.. Probably should be ignored.
  • Throttle % and Power Out is OK

Frame 0x14 (20) GForce
All seems OK

0x1A (26) Gyro
Seems OK, but i think we have the same problem as in OpenTX/EdgeTX.. the value is in Deg/sec, not degress.. but we dont have that Unit.

Frame 0x42 Smart Battery (Not documented)

Battery Capacity: WRONG Name (Is not Capacity, but instant current) in mAh, PREC0. Should be very close to the ESC Current (that is in A, PREC2)
Battery Used 0
Min Cell ---
Max Cell 0.0V
Batt temp 0
Cel1-Cel6 ---looks good, was testing with a 3-cell, cell4-6 show "---", should we hide unused ones??

The Smart battery frame is trickie, since the same frame can be populated with different data.
The first byte on the data tells you what type of data is encoded in the next bytes.

0x00. Status of the Battery (that seems to be populated OK)
0x10. Cells 1-6 -- Seems to be working fine
0x20. Cells 7-12
0x30. Cells 13-18
0x80. Manufacturer Info
0x90. Battery Limits

In EdgeTX we did a trick to add this value/16 and add it to the 0x42 base address, so in the sensor definition, Cells 1-6 is treated as Frame 0x43, etc. Seems that the frame ID range is not used in spektrum, so seems ok this hack. This is to continue using the table definition to help decode the message.

Frame 0x05 AS3X Flight Controller info (Not documented)
This has current flight mode information and the configurable gains/angle limits for each axis (Roll,Pitch,Yaw).
But the valuable data here is the flight mode info.. it tells you the Flight Mode #, if AS3X/Gyro is On/Off, and if SAFE is on Auto-Level, Bank Envelope, or Heading Mode.
Have the code for the decoding of the info in EdgeTX, what we are doing is populating the text "FM" sensor with the FM# + As3x + Safe Mode, so it looks like (FM = 1 As3x Auto-Level)

Also have the GPS and SkyId/Remote ID (undocumented) reversed enginered if you want to add the processing for those frames. On previous version of the RX firmware, the SkyID populated the documented GPS frames, but on the latest version (AS3X+), they stop sending it on those frames, and the same GPS data was added to the SkyID Frame.

@BennyBreman
Copy link

Oke, i am waiting for the update to 1.5.16. Then we see

@frankiearzu
Copy link

Same status for 1.5.17 pre-release

@bsongis-frsky bsongis-frsky reopened this Oct 18, 2024
@bsongis-frsky bsongis-frsky modified the milestones: 1.5.16, 1.6.0 Oct 18, 2024
@BennyBreman
Copy link

Hello, i have install 1.5.18 but NO telemetrie from the Spektrum receiver

@robthomson
Copy link
Collaborator

Have you installed the latest lua scripts?

@BennyBreman
Copy link

BennyBreman commented Oct 24, 2024 via email

@BennyBreman
Copy link

i have found de main.lua en insert de radio, There are a few buttons, in the menu of RF system in the radio. But NO telemetrie is coming

@frankiearzu
Copy link

1.5.18 is working for me... Bind, Telemetry seems fine. Did not need to update the lua script.
Make sure you bind with Auto or DSMX-2F, other sub-protocols don't have telemetry.

@BennyBreman
Copy link

YESSSS, i had the binding on DSM1-2F. but now DSMX-2F and it's working

@bsongis
Copy link
Contributor

bsongis commented Oct 24, 2024

Yes there is Spektrum / MLink / FlySky telemetry with the Multimodule
Hott and Hitec are coming these days, in Ethos 1.6.0

@amaury10
Copy link
Author

Hello,

I tested yesterday, I now have variometer and altitude from an AR8820T.
Thanks a lot for this new feature!

There is still a small issue while paring : it doesn't automatically detect that the Rx has been paired. But the work you did is already incredible.

Regards,

@BennyBreman
Copy link

Hello

I have also tested my planes with the spektrum receiver and everything is working, i am happy. Also de Altitude sensor in the glider is working.
Only a little point is de critcal warming on de RSSI, value is 0-100 and warning at 40. normal value is 22 a 23 max, critcal must set to bv 10.

Thanks for all

@bsongis
Copy link
Contributor

bsongis commented Oct 25, 2024

@BennyBreman Ethos has 2 thresholds, one for Warning (here 40), one for Critical (here 30).

image

What should be the right thresholds for Spektrum?

@bsongis
Copy link
Contributor

bsongis commented Oct 25, 2024

Also what is the unit for RSSI? % or dB or nothing. Today it is nothing.

@BennyBreman
Copy link

It's the --> Tx RSSI
Normal value is on transmitter near the receiver 22 a 23
I think set 10 to the warming

@bsongis-frsky
Copy link
Collaborator

And which value for Critical?

@BennyBreman
Copy link

I don't know which value for critical.

But i have fly this afternoon and everything is working but the telemetry is very poor, it means at 20 meters the telemetry is gone. At all the planes. I have a FrSky X18Se with Spektrum receivers

@robthomson
Copy link
Collaborator

Hmmm

So telemetry not making it back is not really a function of integration on the radio.

The radio can only report on what it receives. It's it that you are getting a warning of losing a sensor? Or is it that all sensors stop working?

@BennyBreman
Copy link

Loosing all sensors, the call is : Telemetry is gone. and near de transmitter : Telemetry is back

@bsongis
Copy link
Contributor

bsongis commented Oct 25, 2024

I am afraid it is not Ethos, if the module reports no telemetry!

@BennyBreman
Copy link

Oke, but the telemetry is working on a Spektrum transmitter, also in the distance

@robthomsonb4b
Copy link

Might be worth making sure the multiprotocol module is on the latest firmware.

The multi module is what handles the comms with the receiver - and then simply passes it on to the radio. Ethos then processes the data from the module and reports the status.

Net result.. no data from module - ethos says.. telemetry lost.

@frankiearzu
Copy link

frankiearzu commented Nov 17, 2024

Enhacements/fixes on ticket #4702

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests